Subject: Re: PC Console devices, PC3 TERMCAP and ncurses
To: Paulo Alexandre Pinto Pires <pappires@crux>
From: Rick Byers <rickb@iaw.on.ca>
List: netbsd-help
Date: 11/12/1996 23:12:18
On Tue, 12 Nov 1996, Paulo Alexandre Pinto Pires wrote:

Hi Paulo, thanks for the info, I'm going to use pcvt properly, but I'm
still having a few problems.

> > I recently installed ncurses 1.9.9e under NetBSD 1.2.  It works great in
> > vt100 or xterm mode, but doesn't work properly in pc3 mode (Default pc
> > terminal).  It doesn't detect the arrow key properly, and the new ncftp
> > (which is why I installed ncurses), can't even tell I'm hitting enter (it
> > scrolls through previous commands or something).  I did noticed some
> > differences between the pc3 termcap entry supplied with netbsd, and the
> > terminfo entry supplied with ncurses.
> 
> It's not your version of ncurses, it's the very own PCCONS driver/
> pc3 settings.  When I used it, arrows didn't work even in vi.

Hm.. I've found some strange problems.  I expected the ncftp not to work
at the office too (same setup - pc3 - I did the exact same thing), but it
worked FINE!  I Just tried pcvt and the arrows still don't work...  I'm
guessing it's something specific to my keyboard (sort of old).  In
the ncurses keyboard test, I get "0033 0117 0102" for the down key.  Up
and right are fine, down and left are wrong.  Even ENTER (either) shows up
as 0402-key-down!  I'm going to try a newer keyboard, but the arrows and
enter work fine in older curses programs (pine/pico/vi)

> I think that PCCONS is not to be used frequently.  It's more a
> solution to when you need a smaller kernel, such as installation
> kernels or kernels suited to machines with little RAM.
> 
> > Both files say that the bsdos info should be updated.  I decided to try the
> > pcvt console drivers instead of pccons, but I had more problems with them.
> > First of all, I got some failure messages on bootup (and the background text
> > colour changed to red).
> 
> With PCVT, messages coming from the kernel will be shown in a red
> background.  I think that this is good, because it makes easier
> to monitor how your kernel's going.
> 
> You can change colors for kernel messages in one of the header files
> for PCVT, or even by setting the apropriate option line in your
> kernel config file.

Ah - Cool.  I notice that the 3rd bit is used for an alternate character
set now instead of intensity.  I miss having intensity (man pages look
stupid) - is there any easy way go get intensity, or am I really going to
have to hack the code?

> I don't know why you got failures on bootup.  However, among all
> console drivers I've already used, I think that PCVT is the best
> (and this is not only for NetBSD, but for FreeBSD and Linux as
> well).  Did you remember to change your /etc/ttys to reflect your
> new terminal type?  You should have your ttyv* to be of type
> vt220, and not pc3 anymore.

The error message isn't in the syslog for some reason, but it was
something to the effect of "pcvt - result != OK and result < 0".  

Should I be using type vt220 over pcvt25?  

> > My Question is this - are there any more up to date - pc console driver
> > available for NetBSD, or atleast how can I modify the ncurses info to work
> > properly with pccons?  I'd like to have something that supports colour as
> > well...
>
> I think PCVT is good enough, so good that I abandoned FreeBSD's syscons
> in favour of PCVT at work (fortunately, PCVT works under FreeBSD too).
> PCVT does color, but the applications will have to deal with properly
> using colors, since termcap has no information about them (but only
> escape sequences for highlight, underline and normal attributes).

I took another look at PCVT, and I think thats what I'll stick too once I
can get all the bugs worked out.  Every time I finish a more numlock
turns on (not sure exactly what causes it yet) - maybe the same
incompatability with my keyboard.

Thanks a lot,
	Rick



=========================================================================
Rick Byers                                      Internet Access Worldwide
rickb@iaw.on.ca                                System Admin, Tech Support
Welland, Ontario, Canada                                    (905)714-1400
http://www.iaw.on.ca/rickb/                         http://www.iaw.on.ca/