mirror of
https://github.com/espressif/openthread.git
synced 2026-08-24 19:29:52 +00:00
[mac] support frames without sequence number (#10544)
This commit adds the capability to support frames without sequence number.
This commit is contained in:
@@ -139,9 +139,21 @@ exit:
|
||||
return error;
|
||||
}
|
||||
|
||||
uint8_t otMacFrameGetSequence(const otRadioFrame *aFrame)
|
||||
otError otMacFrameGetSequence(const otRadioFrame *aFrame, uint8_t *aSequence)
|
||||
{
|
||||
return static_cast<const Mac::Frame *>(aFrame)->GetSequence();
|
||||
otError error;
|
||||
|
||||
if (static_cast<const Mac::Frame *>(aFrame)->IsSequencePresent())
|
||||
{
|
||||
*aSequence = static_cast<const Mac::Frame *>(aFrame)->GetSequence();
|
||||
error = kErrorNone;
|
||||
}
|
||||
else
|
||||
{
|
||||
error = kErrorParse;
|
||||
}
|
||||
|
||||
return error;
|
||||
}
|
||||
|
||||
void otMacFrameProcessTransmitAesCcm(otRadioFrame *aFrame, const otExtAddress *aExtAddress)
|
||||
|
||||
Reference in New Issue
Block a user