-
Notifications
You must be signed in to change notification settings - Fork 2
Description
Problem:
When using SerialTerm to run vi on a serially connected Linux host, the ESC key does not behave properly. Instead of leaving edit mode, it exits SerialTerm and dumps back to the PowerShell prompt. The host is then left with vi running, which causes problems reconnecting.
Expected behavior:
Pressing ESC in vi should exit edit mode in vi, not exit SerialTerm.
Steps to reproduce:
- Attach to serial console on a Raspberry Pi or other Linux host with TTL serial.
- Run
vi /tmp/test.txt - Press ESC to exit edit mode.
- Notice how SerialTerm closes the connection and drops back to the PowerShell prompt with a
^[sequence displayed. Further attempts to attach to the console with SerialTerm result in error.
Also, I don't get vi's status footer like expected and somehow end up in replace mode when vi starts. Guessing the escape sequence for request cursor position (to display the coordinates in the footer) is maybe not implemented? (ESC[6n, request cursor position, would reply back with ESC[#;#R and the R might trigger vi's replace mode. ???)
No biggie, I can still use nano for edits, but if it's not a difficult fix, it would be nice to have vi working. Still a fabulous tool, though.