[riot-notifications] [RIOT-OS/RIOT] drivers/mrf24j40: add external PA/LNA control on MC/MD/ME devices (#11410)

benpicco notifications at github.com
Tue May 21 11:18:29 CEST 2019


benpicco commented on this pull request.



> +#else
+    (void) dev;
+#endif
+}
+
+void mrf24j40_disable_pa_lna(mrf24j40_t *dev)
+{
+#if MRF24J40_USE_EXT_PA_LNA
+    /* Disable automatic switch on PA/LNA */
+    mrf24j40_reg_write_long(dev, MRF24J40_REG_TESTMODE, MRF24J40_TESTMODE_RSSIWAIT0);
+
+    /* Configure all GPIOs as Output */
+    mrf24j40_reg_write_short(dev, MRF24J40_REG_TRISGPIO, 0xF);
+
+    /* Disable all GPIO outputs */
+    mrf24j40_reg_write_short(dev, MRF24J40_REG_GPIO, 0);

The other GPIOs are unused and not available through pads on the C/D/E modules, so unless you are building a custom module based on the bare mrf24j40 chip and add your own PA/LNA circuitry, this should be safe.

-- 
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/11410#discussion_r285929241
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190521/831bb32b/attachment.html>


More information about the notifications mailing list