PDA

View Full Version : Setting TTY Speed on *nix



NeXT
October 25th, 2015, 09:22 AM
I'm running Irix 6.5 on a machine here and I have a modem hanging off serial port 1. I can get Irix to generate a login when someone dials in but I'm having trouble getting a teletype machine to work.
Contrary to the documentation and the UART itself, Irix seemingly will only let you set the speed as low as 300 bps but a model 33 teletype needs 110 bps. I've gone over the manuals several times and poked at stuff like getty but I simply can't seem to figure out how to force the port speed. I quickly tried the same with an old Ubuntu distro and the same issue: Miimum speed it would let you choose was 300bps. I have seen people go lower but I don't know how they did it. Any clues?

Caluser2000
October 25th, 2015, 11:22 PM
Is this any help for ubuntu? https://help.ubuntu.com/community/SerialConsoleHowto

Just set the baud rate to 110 instead of the default 9600. Use the entry specific to your ubuntu distro as there's three different setups listed depending how old the one you are trying is

As for Irix 6.5 is there a 110 entry in the gettydefs file? I'd imagine not looking at the page below:

http://techpubs.sgi.com/library/tpl/cgi-bin/getdoc.cgi/0650/bks/SGI_Admin/books/IA_Periphrls/sgi_html/ch01.html

ldkraemer
October 28th, 2015, 03:49 PM
To locate the possible COMM PORTS in *nix, cut and paste the following commands with the USB to RS-232C Adapter plugged in:


ls -l /dev/ttyS*
ls -l /dev/ttyU*


Notice that ttyS0 through ttyS3 are detected as shown. You may have
/dev/ttyUSB0, or /dev/ttyACM0 if they were properly detected.

crw-rw---- 1 root dialout 4, 64 2009-11-27 15:26 /dev/ttyS0
crw-rw---- 1 root dialout 4, 65 2009-11-27 15:26 /dev/ttyS1
crw-rw---- 1 root dialout 4, 66 2009-11-27 15:26 /dev/ttyS2
crw-rw---- 1 root dialout 4, 67 2009-11-27 15:26 /dev/ttyS3

Notice that root & dialout must have the correct privileges to be able to use the Serial port. You must be in the group dialout.



groups loggedinusername


To add yourself to a gtoup:


usermod -a -G <groupname> loggedinusername



You can determine the Baud rate of the Port:



stty -F /dev/ttyS3 -a


and to change it to 110:



stty --help
stty -F /dev/ttyS3 110
stty -F /dev/ttyS3 -a


If you connect to a modem for testing you can transmit out an "ATZ"
causing the Modem to flash the lights and reset with:



echo ATZ > /dev/ttyS3


Which proves the characters routed to /dev/ttyS3 and to the Modem.


Larry

NeXT
November 5th, 2015, 09:50 AM
As for Irix 6.5 is there a 110 entry in the gettydefs file? I'd imagine not looking at the page below:
There wasn't but I added one by basically copying co_300 and making it co_110


To locate the possible COMM PORTS in *nix, cut and paste the following commands with the USB to RS-232C Adapter plugged in:
Key thing here. I'm not using a USB adapter but the physical port on the machine. We're plugged into /dev/ttyf1 and yes I can echo commands and all that jazz to the modem.


Notice that root & dialout must have the correct privileges to be able to use the Serial port. You must be in the group dialout.

Irix has a fancy little step-by-step way to setup a serial port with a modem using UUCP and let you choose if it's for dialing in, out or both so all of the permissions and the likes are already set.

Basically all I gotta nail down is forcing the port speed. Everything else is ready to go.