[riot-notifications] [RIOT-OS/RIOT] pkg/semtech-loramac: rework interaction with the MAC (#11541)

Francisco notifications at github.com
Tue May 28 18:12:50 CEST 2019


fjmolinas commented on this pull request.

I tested that your changes regarding link_check and ack are working. A minor comment on a border case.

>   * }
  * ```
+ * - Finally, this thread can be started after the join procedure

Is this a requirement?

> +
+                    /* Check Multicast
+                       Check Port
+                       Check Datarate
+                       Check FramePending */
+                    if (indication->FramePending) {
+                        /* The server signals that it has pending data to be sent.
+                           We schedule an uplink as soon as possible to flush the server. */
+                        DEBUG("[semtech-loramac] MCPS indication: pending data, schedule an "
+                              "uplink\n");
+                        uint8_t prev_port = mac->port;
+                        mac->port = 0;
+                        _semtech_loramac_send(mac, NULL, 0);
+                        mac->port = prev_port;
+                    }
+                    else if (indication->RxData) {

There is a border case where if a downlink is received when a cnf messaged is sent the `indication-AckReceived` doesn't go up to the application. Although this doesn't matter in class A, in class B or C this could be mixed. If using `if` instead of `elseif` this would work

-- 
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/11541#pullrequestreview-242737407
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190528/e47eac86/attachment.html>


More information about the notifications mailing list