[riot-notifications] [RIOT-OS/RIOT] nrf5x: Add UART modecfg feature implementation (#11713)

Koen Zandberg notifications at github.com
Thu Jun 20 11:19:56 CEST 2019


bergzand commented on this pull request.



> +        return UART_NOMODE;
+    }
+
+    if (parity != UART_PARITY_NONE && parity != UART_PARITY_EVEN) {
+        return UART_NOMODE;
+    }
+
+    if (stop_bits == UART_STOP_BITS_2) {
+        dev(uart)->CONFIG |= UARTE_CONFIG_STOP_Msk;
+    }
+    else {
+        dev(uart)->CONFIG &= ~UARTE_CONFIG_STOP_Msk;
+    }
+
+    if (parity == UART_PARITY_EVEN) {
+        dev(uart)->CONFIG |= UART_CONFIG_PARITY_Msk;

Fixed!

-- 
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/11713#discussion_r295719461
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190620/6e1c6d6f/attachment-0001.html>


More information about the notifications mailing list