[riot-notifications] [RIOT-OS/RIOT] drivers/mrf24j40 : support of NETOPT_LAST_ED_LEVEL (#10771)

Sebastian Meiling notifications at github.com
Thu May 23 08:29:52 CEST 2019


smlng requested changes on this pull request.

some style issues left 

> +                            MRF24J40_TRISGPIO_TRISGP2 |
+                            MRF24J40_TRISGPIO_TRISGP1);
+    uint8_t gpio = mrf24j40_reg_read_short(dev, MRF24J40_REG_GPIO);
+    mrf24j40_reg_write_short(dev, MRF24J40_REG_GPIO,
+                            gpio |
+                            MRF24J40_TRISGPIO_GPIO2 |
+                            MRF24J40_TRISGPIO_GPIO1);
+#endif
+
+    /* MRF24J40 section 3.6.1 */
+    uint8_t bbreg6 = mrf24j40_reg_read_short(dev, MRF24J40_REG_BBREG6);
+    mrf24j40_reg_write_short(dev, MRF24J40_REG_BBREG6, bbreg6 | MRF24J40_BBREG6_RSSIMODE1);
+
+    uint8_t rssi_rdy = 0;
+    while (rssi_rdy != MRF24J40_BBREG2_RSSIRDY)
+    {

coding style, should be `while (...) {` with opening brace on same line

> @@ -312,6 +312,30 @@ extern "C" {
 #define MRF24J40_INTSTAT_TXNIF          (0x01)
 /** @} */
 
+/**
+ * @name    Bitfiled definitions for the GPIO register (0x33)

please move these two below the INTCON which is `0x32` and before SLPACK which is `0x35`.
Also shouldn't the following defines be `MRF24J40_GPIO_*` to keep the naming consistent?

-- 
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/10771#pullrequestreview-241007715
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190522/0ce20e72/attachment-0001.html>


More information about the notifications mailing list