fix uart ore-flag clear bug
This commit is contained in:
parent
3de51fe256
commit
63a13906cc
|
@ -184,7 +184,7 @@ void USART1_IRQHandler(void)
|
|||
}
|
||||
if (USART_GetFlagStatus(uart->uart_device, USART_FLAG_ORE) == SET)
|
||||
{
|
||||
stm32_getc(&serial1);
|
||||
USART_ReceiveData(uart->uart_device);
|
||||
}
|
||||
/* leave interrupt */
|
||||
rt_interrupt_leave();
|
||||
|
@ -221,7 +221,7 @@ void USART2_IRQHandler(void)
|
|||
}
|
||||
if (USART_GetFlagStatus(uart->uart_device, USART_FLAG_ORE) == SET)
|
||||
{
|
||||
stm32_getc(&serial2);
|
||||
USART_ReceiveData(uart->uart_device);
|
||||
}
|
||||
|
||||
/* leave interrupt */
|
||||
|
|
|
@ -310,7 +310,7 @@ static void uart_isr(struct rt_serial_device *serial)
|
|||
}
|
||||
if (USART_GetFlagStatus(uart->uart_device, USART_FLAG_ORE) == SET)
|
||||
{
|
||||
stm32_getc(serial);
|
||||
USART_ReceiveData(uart->uart_device);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue