Open GooTal opened 1 year ago
I think the issue is not about synchronously waiting, there is an update/refresh state never happening, to me it is hiding a blind spot.
but u16550_txready read LSR directly, 16550 hardware should finish the transmit in the finite time.
I`m not sure what is happening on real hardware. It can`t print out anything without the changes above Maybe i`ve configured something wrong. Maybe it`s the hardware`s feature or defect.
Is it TX holding register or TX shift register that is being checked? Is HW Flow control active? If CTS is active (at UASRT a HIGH) Some HW will not TX.
Yes it might be in a busy state.
Hi, i was running nuttx flat build on LoongArch 3A5000 CPU(not qemu). I`ve ported this version earlier. It`s strange that
NuttShell (NSH) NuttX-12.0.0
could not be printed from uart. So i checked the code and found out that line 65 will judge whether the uart_txready is true. https://github.com/apache/nuttx/blob/a720984eb7b1cabd259014df0d4e9ac0ef0e94dd/drivers/serial/serial_io.c#L65If it`s false, uart just won`t print anything.
Shall we change the code to synchronously wait for uart_txready? Like this:
In u16550_send change it like this:
I`ve also added this in u16550_setup() so that showprogress could print out ABC successfully.