diff --git a/examples/platforms/cc1352/radio.c b/examples/platforms/cc1352/radio.c index b8beabb39..a190cabfd 100644 --- a/examples/platforms/cc1352/radio.c +++ b/examples/platforms/cc1352/radio.c @@ -1948,10 +1948,15 @@ static void cc1352RadioProcessReceiveQueue(otInstance *aInstance) if ((receiveFrame.mPsdu[0] & IEEE802154_FRAME_TYPE_MASK) == IEEE802154_FRAME_TYPE_ACK) { - if (receiveFrame.mPsdu[IEEE802154_DSN_OFFSET] == sTransmitFrame.mPsdu[IEEE802154_DSN_OFFSET]) + if (sState == cc1352_stateTransmit && sTxCmdChainDone && + receiveFrame.mPsdu[IEEE802154_DSN_OFFSET] == sTransmitFrame.mPsdu[IEEE802154_DSN_OFFSET]) { + /* we found the ACK packet */ sState = cc1352_stateReceive; cc1352RadioProcessTransmitDone(aInstance, &sTransmitFrame, &receiveFrame, receiveError); + + sTransmitError = OT_ERROR_NONE; + sTxCmdChainDone = false; } } else diff --git a/examples/platforms/cc2652/radio.c b/examples/platforms/cc2652/radio.c index 345c234f0..970f13066 100644 --- a/examples/platforms/cc2652/radio.c +++ b/examples/platforms/cc2652/radio.c @@ -1929,10 +1929,15 @@ static void cc2652RadioProcessReceiveQueue(otInstance *aInstance) if ((receiveFrame.mPsdu[0] & IEEE802154_FRAME_TYPE_MASK) == IEEE802154_FRAME_TYPE_ACK) { - if (receiveFrame.mPsdu[IEEE802154_DSN_OFFSET] == sTransmitFrame.mPsdu[IEEE802154_DSN_OFFSET]) + if (sState == cc2652_stateTransmit && sTxCmdChainDone && + receiveFrame.mPsdu[IEEE802154_DSN_OFFSET] == sTransmitFrame.mPsdu[IEEE802154_DSN_OFFSET]) { + /* we found the ACK packet */ sState = cc2652_stateReceive; cc2652RadioProcessTransmitDone(aInstance, &sTransmitFrame, &receiveFrame, receiveError); + + sTransmitError = OT_ERROR_NONE; + sTxCmdChainDone = false; } } else