fix: 修正 USART2 波特率为 192000 (与 Loop MCU 实际通信速率一致)
This commit is contained in:
@@ -36,7 +36,7 @@ void uart_init(void){
|
|||||||
GPIO_InitStructure.GPIO_Mode = GPIO_Mode_IN_FLOATING; // Rx
|
GPIO_InitStructure.GPIO_Mode = GPIO_Mode_IN_FLOATING; // Rx
|
||||||
GPIO_Init(GPIOA, &GPIO_InitStructure);
|
GPIO_Init(GPIOA, &GPIO_InitStructure);
|
||||||
|
|
||||||
USART_InitStructure.USART_BaudRate = 115200; // 115200 (协议规定)
|
USART_InitStructure.USART_BaudRate = 192000; // Loop MCU 实际波特率
|
||||||
USART_InitStructure.USART_WordLength = USART_WordLength_8b;
|
USART_InitStructure.USART_WordLength = USART_WordLength_8b;
|
||||||
USART_InitStructure.USART_StopBits = USART_StopBits_1;
|
USART_InitStructure.USART_StopBits = USART_StopBits_1;
|
||||||
USART_InitStructure.USART_Parity = USART_Parity_No;
|
USART_InitStructure.USART_Parity = USART_Parity_No;
|
||||||
|
|||||||
Reference in New Issue
Block a user