Introduction:

RS232 is also called serial communication, commonly used in electromagnetic compatibility test equipment communication interface, when we encounter the use of RS232 serial communication equipment, the following to understand how to correctly configure the DB9 connector pins and how to communicate with the test instrument.

DB9 connector definition:

RS232 protocol using the DB9 connector plus serial cable composition, so you should first understand the DB9 standard pin definition, as the name suggests, DB9 connector has 9 pins, from 1-9 pin definition, symbols shown in the table below.

<<<<提醒:左右滑动表格>>>>
DB9 Pindefinenotation
1carrier detectionDCD
2receive dataRXD
3Send dataTXD
4Data terminals ready.DTR
5signal groundSG
6Data ready.DSR
7Request sentRTS
8Clear SendCTS
9ringer alertRI
<<<<提醒:左右滑动表格>>>>

Serial cable color:

DB9 connectors need to be connected using a serial cable before the RS232 protocol can be used. Serial cables generally use 9 different colors to differentiate between the cables, but each brand of serial cable may use a different color standard, so the table below only represents the color standard of a particular brand.

<<<<提醒:左右滑动表格>>>>
Serial Cable HarnessCable Color
1ferrous
2yellow-brown
3red (color)
4orange (color)
5yellow (color)
6greener
7blue (color)
8violet (color)
9fig. reactionary
<<<<提醒:左右滑动表格>>>>

Cross wired or straight wires for RS232 serial communication:

RS232 serial port communication can use the cross or straight connection line method, the schematic diagram of the two connection methods is shown below:

RS232 communication using the straight wire method

RS232 communication using the straight wire method

RS232 communication using the cross-wiring method

RS232 communication using the cross-wiring method

As you can see from the two diagrams above, the difference between the two connections is whether port 2 (receiving data) and port 3 (sending data) use a direct 2-2, 3-3 connection; or a 2-3, 3-2 connection. The industry is also called TX-TX or TX-RX connection. Of course there is also the need to connect the signal ground port #5.

How to choose between cross wiring or straight wiring methods:

How to control the device using a computer requires the use of direct communication RS232 protocol;

If the device is controlling another device, the cross-communication RS232 protocol is required.