Operating System - HP-UX
1820648 Members
2799 Online
109626 Solutions
New Discussion юеВ

Re: VT320 Terminal troubles

 
SOLVED
Go to solution
Phillip Anderson_1
Occasional Advisor

VT320 Terminal troubles

I can't seem to get my VT320 to work. It's connected with the 6 pin cable to the 9 pin serial post on this HP 712/80i, (through two adapters) and ther computer won't send it a prompt. I'm pretty sure that I used the right entry in /etc/inittab:

a0:4:respawn:/usr/sbin/getty tty1p0 9600

but it still won't recognize it. can anyone help?Thanks,

-phil
Why? Because. 42. Happy Birthday.
11 REPLIES 11
MANOJ SRIVASTAVA
Honored Contributor

Re: VT320 Terminal troubles

Please check the following ;

1. At the System End unplug the cable and short 2and3 of the interface , then see whether what you type appears on the screen , this test that the connection till that is fine including the cable in FD mode .

2. ps -ef | grep getty should show you the list of tty's on which it is enabled.So in case getty is not enabled then enable it or just kill the process for that tty this will restart the getty.

3. Instead of 3 please change to 2345 so taht it gives getty in these states of Unix.

Manoj Srivastava
Wieslaw Krajewski
Honored Contributor

Re: VT320 Terminal troubles

Hi,

Try to change your /etc/inittab entry into

a0:4:respawn:/usr/sbin/getty tty1p0 H

Often for hard-wired terminals the label H should be used instead of 9600. Records of /etc/gettydefs labeled by H and 9600 are not equivalent (compare for example CS8 and CS7).

And sth more, are you sure, that you are at the run level 4, what assumes your entry in the inittab file.

Rgds.

Permanent training makes master
Phillip Anderson_1
Occasional Advisor

Re: VT320 Terminal troubles

Well, thanks for your replies. I connected the pins and it does recieve the signals, so the terminal is OK, But the 712 still won't see it. Is there anything special that one must do? turn it on at a special time or something? I'm still boggled.

I changed it to 2345, but ps-ef grep getty shows only one getty running, that for the system console, andnot the VT. SO,,,

-do I need to change tty1p0? It's a 712 and so only has 1 external RS-232, but I got this line from oue 735 mail server which uses the VT as the main console.
-does the name, surrently set as a0, matter? if so what should it be set to?

thanks for your time and help,
-phil
Why? Because. 42. Happy Birthday.
Phillip Anderson_1
Occasional Advisor

Re: VT320 Terminal troubles

OK. I dug around and found a VT420, which is much happier. Iit works with the inittab, (thanks guys!) but there are still some problems. It doesn't seem to understand cursor position instructions: it won't do a clear screen because when the host sends it the position data it spits it our as raw characters on the screen. for a clear these look like

101 smaug: / $clear
0y0C102 smaug: $

Does anyone know how to remedy this? I'd appreciate it.

-phil, the man who just killed the server by adding an extra "-1"
Why? Because. 42. Happy Birthday.
A. Clay Stephenson
Acclaimed Contributor
Solution

Re: VT320 Terminal troubles

Hi Phillip:

You solved the hardware problem now we need to solve the software side of things:

I don't have a VT420 (or documentation) but
we need to set your TERM environment variable. Unfortunately, a vt420 terminfo does not typically come with HP but I suspect that a vt320,vt220,vt100, etc. entry will work just fine.

Try this from the shell:
TERM=vt320
export TERM
tput clear
If that works try editing a textfile with vi.
If that works great otherwise try another TERM setting and export it.

You may also be able to put the VT420 in a VT320 emulation mode or an ANSI mode.

If you examine /usr/lib/terminfo/*
you will find a ton of terminfo entries; all of the vtxxx entries are under the 'v' directory. Likewise the 'ansi' entry would be under the 'a' directory. I'm betting that one of the vt's will do the trick.

When you've found a suitable entry then edit your .profile and add an entry like
export TERM=vt320 and your all set.

Hope this helps, Clay

If it ain't broke, I can fix that.
Phillip Anderson_1
Occasional Advisor

Re: VT320 Terminal troubles

that worked. You're the man! But just one thing:
it's in a public lab so the non usix inclined will be using it. So, it there any way to set it up for all users? so they don't have to export TERM every time?

thanks for the help
-phil

ps. I set TERM to vt220 and went into the terminal setup and switched it to vt220 mode.

Why? Because. 42. Happy Birthday.
Phillip Anderson_1
Occasional Advisor

Re: VT320 Terminal troubles

no sooner had I posted that then did I log out of the terminal. Now it's worse: it's complete gibberish. Random characters come up everytime I press something. erk...
Why? Because. 42. Happy Birthday.
A. Clay Stephenson
Acclaimed Contributor

Re: VT320 Terminal troubles

Hi Phil,

You have three options.
1) As I mentioned earlier
simply place the export TERM=vt220 statement in each user's .profile; it will then be set at login
or
2) Man tset to get some ideas. tset can query a terminal and attempt to determine what kind of terminal is attached and build a TERM=xxx command for you. It consult's a file called /etc/ttytype. Again man tset and man ttytype for details. (I like this one - it makes you learn; notice I intentionally didn't fill in all the blanks)
or
3)
You could modify /etc/skel/.profile so that when new users are added the export TERM is already in their profile. (This won't fix existing users however).

This should point you in the right direction,
Clay

If it ain't broke, I can fix that.
A. Clay Stephenson
Acclaimed Contributor

Re: VT320 Terminal troubles

Hi Phil, that gibberish is probably the terminfo's 'reset' string. Power cycle the terminal to restore normal operation. You probably need to try another TERM setting and/or set and save the terminals emulation mode. If you can emulate a vt320 and TERM is set to vt320 everything should be fine; Also pay attention to 7-bit and 8-bit modes, on the vt's the differences in some sequences was profound.
Your other option is to pick up an HP terminal.
(you can get them on the used market for well under $200).
If it ain't broke, I can fix that.
A. Clay Stephenson
Acclaimed Contributor

Re: VT320 Terminal troubles

Ok Phil, One other thing to check. Which entry in /etc/gettydefs are you using? Determine that by looking at the last field of /etc/inittab which corresponds to your serial port. I'm guessing that you are using a gettydef that wrapsaround to another entry. The last field in a gettydef entry points to the next gettydef to try. With a hard-wired terminal you want to have one thatwraparound to itself so that the baudrate, parity, & wordsize remains constant. You can always edit the existing gettydefs and copy an existing entry and give it a new name like 19200H and let it point back to itself. I think that is what is happening. Obviously the baudrate, etc. of the terminal must match that of the port and associated gettydef.

You can do a stty -a < /dev/ttyxx to see the current port settings.

Clay
If it ain't broke, I can fix that.
Phillip Anderson_1
Occasional Advisor

Re: VT320 Terminal troubles

That gibberish resulted form me trying to up the speed. I did it on both the terminal and in the gettydefs file, but it just didn't sync right or something. So, now it' working, but each time a user logs in they must export TERM to be vt220, else the control codes start coming up.

I played with tset for a while, so now I know that

tset - -m vt220:vt220 xterm

will test the term type, and if it's vt220, say so, elxe default to xterm which is what everything else on our network uses.

Clay, thanks for your help, and thanks to others who replied.

Now it's just a matter of putting this in the .profile. I can't figure out where in the file to put it, or how to get just the first output line (the terminal name) (I tried to pipe it to head -n 1 but for some reason it wouldn't work.) So, my problem has been solved.
Why? Because. 42. Happy Birthday.