Serial port (com1) baud rate oddity

Richard P. Williamson richard.williamson at u4eatech.com
Tue Mar 23 01:33:43 PST 2004


At 08:31 23/03/2004, Richard P. Williamson wrote:
>At 17:41 22/03/2004, Nathan Kinkade wrote:
>>tip gets it configurations from /etc/remote.  Make sure that "com1" in
>>/etc/remote is set with appropriate values.  The default is:
>>
>>sio0|com1:dv=/dev/cuaa0:br#9600:pa=none:

According to stty, ba is 1355.
blah# stty -a -f /dev/ttyd0
speed 1355 baud; 0 rows; 0 columns;
lflags: -icanon -isig -iexten -echo -echoe -echok -echoke -echonl
        -echoctl -echoprt -altwerase -noflsh -tostop -flusho -pendin
        -nokerninfo -extproc
iflags: -istrip -icrnl -inlcr -igncr -ixon -ixoff -ixany -imaxbel -ignbrk
        -brkint -inpck -ignpar -parmrk
oflags: -opost onlcr -ocrnl oxtabs onocr onlret
cflags: cread cs8 -parenb -parodd hupcl clocal -cstopb -crtscts -dsrflow
        -dtrflow -mdmbuf
cchars: discard = ^O; dsusp = ^Y; eof = ^D; eol = <undef>;
        eol2 = <undef>; erase = ^?; erase2 = ^H; intr = ^C; kill = ^U;
        lnext = ^V; min = 1; quit = ^\; reprint = ^R; start = ^Q;
        status = ^T; stop = ^S; susp = ^Z; time = 0; werase = ^W;

On the sink machine, I did 'tip -1355 com1' and got text instead
of @@ @@@@@@ @ @ @@@ etc.  But why did the source machine decide
to use 1355 in the first place?

blah# grep com1 /etc/remote
com1:dv=/dev/cuaa0:br#9600:pa=none:
blah# grep 1355 /etc/*
services:intuitive-edge 1355/tcp   #Intuitive Edge
services:intuitive-edge 1355/udp   #Intuitive Edge
blah#

This is what happens if I try to force it to 9600:

blah# stty -f /dev/ttyd0 speed 9600
1355
blah# stty -f /dev/ttyd0 9600
blah# stty -a -f /dev/ttyd0
speed 1355 baud; 0 rows; 0 columns;
...

Possibly it won't let me adjust the baud rate, as the device is busy:
blah# tip com1
tip: /dev/cuaa0: Device busy
link down
blah#

So how can I idle the device long enough to try resetting the
speed?

blah# sleep 60 vs. Seiko is a dead heat, so at least the system
clock appears to be ticking at the correct rate.

rip 



More information about the freebsd-questions mailing list