[riot-notifications] [RIOT-OS/RIOT] RFC: UART enhanced settings (#10743)

Kaspar Schleiser notifications at github.com
Fri Jan 25 15:27:55 CET 2019


kaspar030 commented on this pull request.



> +            res = UART_STOP_BITS_2;
+            break;
+        default:
+            printf("msg: Invalid number of stop bits (%i).\n", stop_bits);
+            res = -1;
+    }
+
+    return res;
+}
+
+static uart_parity_t parse_parity(char *arg)
+{
+    uart_parity_t res;
+
+    switch (arg[0]) {
+        case 'n':

For letters that can be done dropping a bit:
```arg[0]  &= ~0x20;```

-- 
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/10743#discussion_r251002683
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190125/2c2eb4ce/attachment.html>


More information about the notifications mailing list