Subject: pcvt/tset incompat
To: None <port-i386@NetBSD.ORG>
From: VaX#n8 <vax@linkdead.paranoia.com>
List: port-i386
Date: 03/21/1996 00:06:05
I've a fairly serious problem that is more than likely due to my
lack of knowledge about termcap and console drivers, etc.

If I execute 'tset -s pcvt25h', or simply 'tset -s' when TERM is
pcvt25h, it seriously mangles my screen, to the state where it's near
impossible to do anything but shutdown and reboot.  Among other things,
the "n" key must be doubled to work, ':' doesn't work, etc...
I was in a state of panic, and was ready to restore from tape when
I gave some thought as to why single-user was working....

My /etc/ttys is correct I think:
console "/usr/libexec/getty Pc"   pc3     off             # su-console
ttyv0   "/usr/libexec/getty pcvt" pcvt25h on secure       # multi-console
...etc...

My TERM envariable has always been set to pcvt25h when on ttyv0, for example.
But when I execute tset, the whole state gets seriously garbled.  If I do
it under an xterm, it has the same effect, even if I'm not evaling the
output:

vax@linkdead bash$ tset -s pcvt25h

(clear screen)

Kill set to :.
              Interrupt set to #.
                                 TERM=pcvt25h;
                                              TERMCAP='pcvt25h:li#25...(etc)

(I didn't want to include the whole tcap entry but if you need it, I can.)

at this point (edited for readability):
vax@linkdead bash$ stty -a
  speed 9600 baud; 24 rows; 80 columns;
  lflags: icanon -isig iexten echo echoe echok echoke echonl echoctl
  echoprt -altwerase -noflsh tostop -flusho pendin -nokerninfo -extproc
  iflags: istrip icrnl -inlcr -igncr -ixon ixoff -ixany imaxbel -ignbrk
         brkint -inpck -ignpar -parmrk
  oflags: -opost onlcr -oxtabs
  cflags: cread cs6 -parenb -parodd -hupcl -clocal -cstopb -crtscts mdmbuf
  cchars: discard = :; dsusp = ^I; eof = [; eol = 4; eol2 = m; erase = ^?;
        intr = #; kill = :; lnext = n; min = 0; quit = 3; reprint = v;
         start = :; status = <undef>; stop = x; susp = :; time = 0;
         werase = ^I;

Huh?  cs6?  I don't think so.

This is using _very_ recently supped stuff, all recompiled.

Please, tell me I'm an idiot in such a way I can learn.

Furthermore, pcvt doesn't install pcvt_ioctl.h, and when I installed it
into /usr/include/machine, ispcvt and other utils failed to compile.
Some error about updateslow and updatefast.  Am I telling you stuff
you already knew?  Thought so.  I'm a bit behind on -current and -i386
email.  Sorry.

One of these days I'll read that O'Reilly book on termcap & terminfo :)
and dig into the driver source too... "if I only had the time..."