get terminal speed from shell script
BURNS,JIM
gt0178a at prism.gatech.EDU
Fri Aug 17 19:22:45 AEST 1990
in article <1990Aug17.034401.12720 at jts.com>, gerry at jts.com (Gerry Roderick Singleton ) says:
> Hmm, that's true when you're in a window. I did not interpret the
> original question as being window specific but the more general
> case of working with ttys and pttys. The script DOES work for real
I was on a 'screen' window on one host, doing an rlogin to the SUN. I was
not in a window as far as the Sun was concerned, although rlogin was
probably using a socket. This saved me the trouble of being physically at
the Sun. Are you saying this is stll justified behavior for the Sun? Rlogin-
ing to a Mac A/UX, or even back to my host, does not cause problems w/stty.
> ttys and ti even works on pttys over RPC links. Here's the output
> under these circumstances as executed with /bin/sh -vx foo, where foo
> is the four lines above:
> #! /bin/sh
> speed=`stty speed </dev/tty 2>&1`
> + stty speed
> speed=9600
> echo $speed
> + echo 9600
> 9600
> I have no window system solution, so I hope one of the window system
> gurus can help.
The previously posted solutions of
speed=`stty speed 3>&1 1>&2 2>&3`
or
speed=`/usr/5bin/stty speed`
work.
--
BURNS,JIM
Georgia Institute of Technology, Box 30178, Atlanta Georgia, 30332
uucp: ...!{decvax,hplabs,ncar,purdue,rutgers}!gatech!prism!gt0178a
Internet: gt0178a at prism.gatech.edu
More information about the Comp.unix.questions
mailing list