1 parent af79e18 commit 44ca2eeCopy full SHA for 44ca2ee
cores/esp32/esp32-hal-uart.c
@@ -333,7 +333,7 @@ void uartFlush(uart_t* uart)
333
}
334
335
UART_MUTEX_LOCK();
336
-while(uart->dev->status.txfifo_cnt);
+while(uart->dev->status.txfifo_cnt||uart->dev->status.st_utx_out);
337
338
//Due to hardware issue, we can not use fifo_rst to reset uart fifo.
339
//See description about UART_TXFIFO_RST and UART_RXFIFO_RST in <<esp32_technical_reference_manual>> v2.6 or later.
0 commit comments