[CentOS] Need to test serial port connection

Thu Feb 26 21:08:21 UTC 2009
Robert <kerplop at sbcglobal.net>


William L. Maltby wrote:
> On Thu, 2009-02-26 at 14:29 -0600, Robert wrote:
>   
>> <snip>
>>     
>
>   
>> breakout box.  Lacking one of those, you might find the statserial 
>> program to be of some use in figuring out what the control lines are doing.
>> #  yum --enablerepo=dag install statserial
>> will install it.  It has a short man page.   Run with no options except 
>> device ( # statserial /dev/ttyS0 )  will cause it to loop, indicating 
>> status of all control signals.   You can manually tweak any of the pins 
>> with direction of "in" with a 9-volt battery or by using a paper-clip 
>>     
>
> IIRC (very iffy) +/- 12 volts is needed.
>
>   
>> jumper from one of the "out" lines.  It won't be long before you can 
>> identify the port, moving an "unknown" to "found". 
>>     
>
> There are pins designated to _provide_ the correct voltage full time (on
> 25 pin units - unsure about 9 pin). The google will get a specification
> of which they are - I can't remember.
>
>   
The RS-232C (un) standard specifies +5vdc to +25vdc as a "space" on data 
lines and a "true" on control lines; -5vdc to -25vdc as "mark" and 
"false". -5 to +5 is undefined ---BUT--- how many times have I seen the 
damn things operated using ttl levels. DTR (pin 4 of 9 or pin 20 of 25) 
should be a logical 1 if the port has been initialized.