Merge pull request #2144 from geky/stdio-baud-config

Add config option for stdio baud rate
pull/2151/head
Bogdan Marinescu 2016-07-12 13:06:29 +03:00 committed by GitHub
commit 089b67cc79
2 changed files with 8 additions and 0 deletions

View File

@ -98,6 +98,9 @@ static void init_serial() {
#if DEVICE_SERIAL
if (stdio_uart_inited) return;
serial_init(&stdio_uart, STDIO_UART_TX, STDIO_UART_RX);
#if MBED_CONF_CORE_STDIO_BAUD_RATE
serial_baud(&stdio_uart, MBED_CONF_CORE_STDIO_BAUD_RATE);
#endif
#endif
}

View File

@ -4,6 +4,11 @@
"stdio-convert-newlines": {
"help": "Enable conversion to standard newlines on stdin/stdout",
"value": false
},
"stdio-baud-rate": {
"help": "Baud rate for stdio",
"value": 9600
}
}
}