Difference between revisions of "RS-232"

From Noah.org
Jump to navigationJump to search
Line 176: Line 176:
 
| 22<br>  
 
| 22<br>  
 
| 9<br>  
 
| 9<br>  
| <br>  
+
| RI<br>  
 
| Rind Indicator<br>  
 
| Rind Indicator<br>  
 
| &nbsp;IN: DTE &lt;- DCE<br>
 
| &nbsp;IN: DTE &lt;- DCE<br>

Revision as of 02:03, 17 November 2009

RS-232

RS-232 is also known as RS232, RS-232-C, RS-232-D, EIA-232, TIA-232E, TIA-232-F -- and even V.28/V.24 by the weirdos. There's a whole family of them. These standards are not identical, but RS-232 will get you close to what you want. In theory, the RS-232C standard only specifies the signaling, not how you actually wire it up. The pinouts given in this article are common.

The RS-232C standard requires the transmitter to use +12V (0, logic low) and -12V (1, logic high). The receiver needs only see over +3V and under -3V. Most transmitting ports use only +5V and -5V. Those levels are compatible with most devices and host computers. Maxim is one of the more popular suppliers of RS-232 level shifters or level converters.

D-sub 9 pinout (TIA-574, DE-9, and DB-9)

diagram of a DE-9 connector

Technically this connector is called a D-sub 9 or a DE-9, but it is often incorrectly referred to as a DB-9. The D refers to the shape of the connector. The E specifies the size of the connector shell. I'm not sure why you couldn't just get that from the number of pins, but whatever...

 1 2 3 4 5
  6 7 8 9

DB-25 pinout

diagram of a DB-25 connector

The D refers to the shape of the connector. The B specifies the size of the connector shell. Note that DB-25 may carry two RS-232 lines, but this is rare.

 1   2   3   4   5   6   7  8   9  10  11  12  13

  14  15  16  17  18  19  20  21  22  23  24  25

3-wire RS-232

A minimal "3-wire" RS-232 connection consists only of TxD, RxD, and SGND (pins 3,2,5 on DB-9 and pins 2,3,7 on DB-25).

5-wire RS-232

A minimal RS-232 connection with hardware flow control: TxD, RxD, SGND, RTS, and CTS (pins 3,2,5,7,8 on DB-9 and pins 2,3,7,4,5 on DB-25).

RS-232 DB-25 to DB-9 Pinout table

DB-25
DB-9
line
description
direction
DTE is the computer
DCE is the device
1

shield
ground shield

2
3
TxD
Transmit Data
OUT: DTE -> DCE
3
2
RxD
Receive Data
  IN: DTE <- DCE
4
7
RTS
Request To Send
OUT: DTE -> DCE
5
8
CTS
Clear To Send
 IN: DTE <- DCE
6
6
DSR
Data Set Ready
 IN: DTE <- DCE
7
5
SGND
signal ground
< - >
8
1
DCD
Data Carrier Detect
 IN: DTE <- DCE
9




10




11




12




13




14




15




16




17




18




19




20
4
DTR
Data Terminal Ready
OUT: DTE -> DCE
21




22
9
RI
Rind Indicator
 IN: DTE <- DCE
23




24




25