I am writing a Framebuffer console app that takes stdout and stderr and
renders the text to a framebuffer device. Based on existing NXGL code
and example apps.
It spawns NSH, and I get the NSH prompt on my LCD - and it basically
works. I have also added functions to decode the handful of VT100 codes
that the nsh app sends, such as cursor on/off, clear to eol etc.
But I am stumped by an apparent lack of a newline being sent to stdout
when, for example, you simply hit ENTER on the keyboard; or do a
directory listing (ls - l) followed by ENTER. With no newline being sent
at the start of the output, the first line of text sits at the end of
the current line until there's a '/n' within the stream.
I must be missing something, perhaps relating to how the VT100 escape
codes should be interpreted or some other console "rule" I haven’t
managed to find anywhere.
Has anyone got any suggestions - it's driving me crazy!!