[GreenKeys] Support for serial ports

tony j. podrasky tony.podrasky at gmail.com
Tue Jun 14 20:07:52 EDT 2011


Actually, with Linux you can customize the baud for any baud you wish:

First, you calculate the <divisor> by dividing the UART's fastest rate
(115200) by the BAUD you wish. When I wanted 45.45 I did
115200/45.45 = 2534

Then, set the desired TTY port's UART with that information:

/bin/setserial /dev/ttyS0 spd_cust divisor 2534


Next, You tell the UART to use a custom speed divider (spd_cust)
by setting the UART to the magic speed of 38400.

/bin/stty -F /dev/ttyS0 38400 cs5 raw -cstopb -echo


So: 66 WPM would have a spd_cust of 2304 and 100 WPM 1536.


For more info, do a <man setserial>.

UE,
W6ESE - tony
NNNN
ZCZC

> There are patches to UNIX to change the baud rate, but they're
> something of a pain.
> 

-- 
Tony J. Podrasky | Oh, great: This new "Day Planner" I bought has
                  | nothing but blank pages.  Now I have no idea
                  | what I'm supposed to be doing tomorrow.
                  |                              -Blaine Hofmockel


More information about the GreenKeys mailing list