Skip to content

Conversation

@spiriou
Copy link
Contributor

@spiriou spiriou commented Nov 19, 2025

802.15.4 specifies that a device may send a DATA_REQUEST command to the coordinator after waiting for "macResponseWaitTime", starting after the acknowledgment to the association request command.

This change adds support to generate DATA_REQUEST frames and sends one for the association usecase only. The two other usecases, for MLME-POLL or for beacon-enabled PAN, are not yet supported.

net_pkt_unref(pkt);
pkt = ieee802154_create_mac_cmd_frame(
iface, IEEE802154_CFI_DATA_REQUEST, &params);
if (!pkt) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please change this to if (pkt == NULL) { as dictated by MISRA so that we do not introduce new code that is using boolean checks for non boolean variables.

@spiriou spiriou force-pushed the ieee802154_cfi_data_request branch from 11dfd54 to 8f7ffb6 Compare November 20, 2025 09:28
802.15.4 specifies that a device may send a DATA_REQUEST command to the
coordinator after waiting for "macResponseWaitTime", starting after the
acknowledgment to the association request command.

This change adds support to generate DATA_REQUEST frames and sends one
for the association usecase only. The two other usecases, for MLME-POLL
or for beacon-enabled PAN, are not yet supported.

Signed-off-by: Simon Piriou <[email protected]>
@spiriou spiriou force-pushed the ieee802154_cfi_data_request branch from 8f7ffb6 to 21a8603 Compare November 20, 2025 11:50
@sonarqubecloud
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants