From: cwilson@Xenon.Stanford.EDU (Christopher S. Wilson) Subject: Re: vt100 emulation, garbaged screen Date: Sun, 14 Feb 1993 20:16:53 GMT
In article <12FEB199317433229@ariel.lerc.nasa.gov> secsu@ariel.lerc.nasa.gov (Ralph O. Clark) writes:
>Greetings.
>
>I was logged in to a remote system and inadvertently sent a binary file
>to my screen (under Kermit, SLS 0.99pl4). The most immediate result
>was that, from that point on, that virtual console mapped characters
>very oddly. My screen was full of box-drawing characters and other
>nonsense. Some non-alphabetic characters (such as the kermit prompt '>'
>and the shell prompt '#') were preserved, as well as upper-case letters,
>but the rest was nonsense. I couldn't find an option to setterm to
>restore normal operation.
I have exactly the same thing happen many times, so I've been looking
forward to an answer to this. I haven't seen one or found anything in
the docs, so I started experimenting and found that an ASCII 14 (^N)
sent to the terminal switches the lower case characters to garbage.
An ASCII 15 (^O) switches it back. I have an ASCII chart that calls
^N a ``Shift Out'' and ^O a ``Shift In'', but I don't know how VT100
is supposed to handle these (I never had this happen with any other
VT100 emulator).
I tried all the stty and setterm options and none of them seem to fix
it. But all you need to do is get a ^O sent to your screen. So, for
anyone else who has this trouble, I suggest the following. Go into
emacs on a new file, hit control-Q followed by control-O to insert a
literal control-O in the file, then save the file. Then whenever your
display is messed up, just cat that file.
Anyone know of a better way to fix this (or better yet, prevent it
from happening)? Could some sort of explaination about this be put in
the FAQ?
>
>The other result was that, when I used ps to find the pid of that session
>so I could kill it, ps printed out the expected stuff and then dumped
>core. Actually, I don't know if this was a result of the garbaged screen
>or not. My system has been running for about 10 days without rebooting.
>I guess I could use gdb on the core file, but what I really want is
>some explanation/solution to the screen garbage problem.
>
I doubt this has anything to do with the garbage characters on the
screen.
--Chris