[riot-notifications] [RIOT-OS/RIOT] gnrc_lorawan : Add ADR support (#15995)

Akshai M (Augustus Diode) notifications at github.com
Mon Jul 12 16:43:25 CEST 2021


@akshaim commented on this pull request.



> +           p[1] >> 4, p[1] & 0x0f);
+    DEBUG("gnrc_lorawan_mlme: LinkADRReq ChMask : %u\n", (p[3] << 8 ) | p[2]);
+    DEBUG("gnrc_lorawan_mlme: LinkADRReq Redundancy : %u\n", p[4]);
+
+    mac->last_dr = p[1] >> 4;
+    mac->channel_mask = (p[3] << 8 ) | p[2];
+    // mac->mcps.redundancy = p[4];
+
+    /* Set `LinkADRAns` for next uplink */
+    mac->mlme.pending_mlme_opts |=  GNRC_LORAWAN_MLME_OPTS_LINK_ADR_ANS;
+
+    DEBUG("gnrc_lorawan_mlme: Lastdr : %u\n",mac->last_dr); // to be removed
+    DEBUG("gnrc_lorawan_mlme: Channel Mask : %u\n",mac->channel_mask); // to be removed
+
+    /* Reset `ADR_ACK_CNT` counter */
+    mac->mlme.adr_ack_cnt = 0;

Done.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/15995#discussion_r667994331
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20210712/ee72b5d9/attachment-0001.htm>


More information about the notifications mailing list