Problem with formatted UART simulation (by Oguz)
I have attached an example ( including a screenshot ) that seems to have problems with simulation of formatted UART instruction.
1) The first character 'H' of "Hello" is dropped
2) Newline is ignored
3) If I press Space to single step, "Hello..." string is printed to simulation terminal one character at a time. If Space causes the execution of a single rung ( or instruction ? ) at a time, I would expect the formatted string to be sent to UART all at once.
This behavior seems independent of processor.
Thanks
Oz
(no subject) (by Jonathan Westhues)
(1) I really should fix that at some point. It starts with the second character, not the first, but is correct thereafter.
(2) Newline is not ignored; you just don't see anything, since you don't print anything after the newline.
(3) The UART on these processors has only a one- (or two-) character buffer. So the program would have to either write the string to a FIFO, and feed the UART from an interrupt handler--which is complex, and would burn RAM and introduce timing variations--or just enqueue one character per cycle. It does the latter.
See the attachment, which shows that newlines do work, and that the issue in (1) corrects itself.