stm32: serial use 115200 baud rate
115200 is a much more sane "default" than 38400. Instead of a mix of 38400 and 115200, just use 115200 in all places. There's no reason for modern 32bit cpus to be using such old slow baudrates. Tested on f1, f4, l1. Replaced some old f1 code that predated some library support code for this.
This commit is contained in:
@@ -43,7 +43,7 @@ static void usart_setup(void)
|
||||
GPIO_CNF_OUTPUT_ALTFN_PUSHPULL, GPIO_USART1_TX);
|
||||
|
||||
/* Setup UART parameters. */
|
||||
usart_set_baudrate(USART1, 38400);
|
||||
usart_set_baudrate(USART1, 115200);
|
||||
usart_set_databits(USART1, 8);
|
||||
usart_set_stopbits(USART1, USART_STOPBITS_1);
|
||||
usart_set_mode(USART1, USART_MODE_TX);
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
This example program sends some characters on USART3 on the ST STM32-based
|
||||
[Olimex STM32-H103 eval board](http://olimex.com/dev/stm32-h103.html).
|
||||
|
||||
The terminal settings for the receiving device/PC are 38400 8n1.
|
||||
The terminal settings for the receiving device/PC are 115200 8n1.
|
||||
|
||||
The sending is done in a blocking way in the code, see the usart\_irq example
|
||||
for a more elaborate USART example.
|
||||
|
||||
@@ -43,7 +43,7 @@ static void usart_setup(void)
|
||||
GPIO_CNF_OUTPUT_ALTFN_PUSHPULL, GPIO_USART1_TX);
|
||||
|
||||
/* Setup UART parameters. */
|
||||
usart_set_baudrate(USART1, 38400);
|
||||
usart_set_baudrate(USART1, 115200);
|
||||
usart_set_databits(USART1, 8);
|
||||
usart_set_stopbits(USART1, USART_STOPBITS_1);
|
||||
usart_set_mode(USART1, USART_MODE_TX);
|
||||
@@ -58,7 +58,7 @@ static void usart_setup(void)
|
||||
GPIO_CNF_OUTPUT_ALTFN_PUSHPULL, GPIO_USART2_TX);
|
||||
|
||||
/* Setup UART parameters. */
|
||||
usart_set_baudrate(USART2, 38400);
|
||||
usart_set_baudrate(USART2, 115200);
|
||||
usart_set_databits(USART2, 8);
|
||||
usart_set_stopbits(USART2, USART_STOPBITS_1);
|
||||
usart_set_mode(USART2, USART_MODE_TX);
|
||||
@@ -73,7 +73,7 @@ static void usart_setup(void)
|
||||
GPIO_CNF_OUTPUT_ALTFN_PUSHPULL, GPIO_USART3_TX);
|
||||
|
||||
/* Setup UART parameters. */
|
||||
usart_set_baudrate(USART3, 38400);
|
||||
usart_set_baudrate(USART3, 115200);
|
||||
usart_set_databits(USART3, 8);
|
||||
usart_set_stopbits(USART3, USART_STOPBITS_1);
|
||||
usart_set_mode(USART3, USART_MODE_TX);
|
||||
|
||||
Reference in New Issue
Block a user