feat: 实验性上行数据接收
This commit is contained in:
@@ -92,15 +92,11 @@ void USART1_IRQHandler(void)
|
||||
void USART2_IRQHandler(void)
|
||||
{
|
||||
if (USART_GetITStatus(USART2, USART_IT_RXNE) != RESET) {
|
||||
// uint8_t data = (uint8_t)USART_ReceiveData(USART2);
|
||||
// by_frame_parse_uart_handle(data);
|
||||
USART_ReceiveData(USART2);
|
||||
NVIC_SystemReset();
|
||||
by_frame_parse_uart_handle((uint8_t)USART_ReceiveData(USART2));
|
||||
USART_ClearITPendingBit(USART2, USART_IT_RXNE);
|
||||
}
|
||||
|
||||
if (USART_GetFlagStatus(USART2, USART_FLAG_ORE) != RESET) {
|
||||
|
||||
USART_ClearFlag(USART2, USART_FLAG_ORE); // <20><><EFBFBD><EFBFBD> ORE <20><>־λ
|
||||
USART_ReceiveData(USART2);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user