VEDIT Keyboard Malfunction

Currently I am working on a project involving computers that run QNX 4.25. The project is several years old, beginning with 486 Ziatec computers, but has more recently been updated for standard PC hardware. Currently the system runs on some variant of a Celeron processor on a motherboard that has a southbridge that is listed as being supported on the QNX 4 Hardware Compatibility List.

My issue is that I have recently found that I am unable to properly use the keyboard when in vi or vedit. Essentially, any key that is not a standard ASCII character fails to be recognized. Letters A-Z, numbers 0-9, most symbols, and a few basic editing keys (backspace & tab) and command keys (Ctrl, Enter, & Shift) work perfectly. The keys causing the problem are F1-F12, Arrow Keys, Keypad Keys (when NumLock is off), and other navigation keys (Insert, Delete, Home, etc.). Windows-specific keys fail to cause any response at all (as expected).

The problem caused by the keys listed above is that, rather than create their intended function, those keys cause vedit to enter the Escape Menu. Essentially, trying to navigate downwards using the down arrow key will open the escape menu. Pressing any of the problem keys a second time results in the escape menu exiting and the display of two characters. Up displays [A, down displays [B, right displays [C, and left displays [D.

All of the keyboards I have been trying to use are standard PS2 keyboards, each of which contains the three windows navigation keys at the bottom. Additionally, the arrow keys work normally on the QNX command line (ie, left and right move the cursor, up and down scroll through previous commands).

Thus far in the troubleshooting I have: used 4 different keyboards of different manufacture, viewed and verified the keyboard mapping for vedit, and generally experimented with every relevant-looking setting from within vedit. If anyone knows why this may be occurring or has ideas for further troubleshooting, I’m open for suggestion!

~SrA Miller, E.
Lackland AFB, TX

Are you on the console or via telnet session? What is TERM set to?

echo $TERM

You might also want to try qed as an experiment to see if you get similar bad behavior.

@noc:

I login using the console, as I have direct physical access to the computers. My detachment is a maintenence depot, so we actually build the computers here and test them prior to use elsewhere.

The result of the query “echo $TERM” is “qnx”.

@maschoen

I assume qed is another text editor, so I can tell you that I get similar bad behavior when using vi/elvis. In that case, the program simply stops responding if I use an arrow key. If you could share a little more information about what you’re suggesting I try, I’ll see about trying it.

Given that VEDIT and elvis don’t work, QED probably won’t either, however the results might be more enlightening. Another good piece of information that might help is if you run the command:

stty

from the console, and report the results.

Results of “stty” as follows:

Name: //1/dev/con1
Type: console
Opens: 2 (RW)
Sigint Grp: 1010, Sighup pid: 1010
+edit
+osflow
intr=^C quit=^\ erase=^? kill=^U eof=^D start=^Q stop=^S min=01
time=00 pr1=^] pr2=5B left=44 right=43 up=41 down=42 ins=40
del=50 home=48 end=59
-numlock -capslock -scrlock font=0 protocol=1

Is the file /etc/termcap present. Is it the orignal one? Mine is 6724 bytes.

With low expectations, try:

stty protocol=0

and repeat experiments

You probably need a
stty load
after that. or combine them together:
stty load protocol=0