On Fri, 6 Jan 2023 at 17:29, Evgeny Iakovlev <eiakov...@linux.microsoft.com> wrote: > > UART should be enabled in general and have RX enabled specifically to be > able to receive data from peripheral device. Same goes for transmitting > data to peripheral device and a TXE flag. > > Check if UART CR register has EN and RXE or TXE bits enabled before > trying to receive or transmit data.
I wonder if the real hardware lets you fill the TX fifo when TXE or EN are clear (and then transmits it when you enable tx later)? That seems kind of an odd corner case to implement, though, and the TRM doesn't specifically say one way or the other, so it doesn't seem worth the bother. Reviewed-by: Peter Maydell <peter.mayd...@linaro.org> I notice this device doesn't have a reset method, incidentally, which is probably something we should fix. thanks -- PMM