synonymSerial port(Computer term) generally refers to the serial port
Serial interface is also called serial port for shortserial communicationInterface orSerial communication interface(Usually refers toCOM interface), using serial communicationExpansion interface。serial Interface(Serial Interface) refers to the sequential transmission of data bit by bit.Its characteristics areCommunication lineSimple. Only one pair of transmission lines can realize two-way communication (telephone lines can be directly used as transmission lines), which greatly reduces the cost. It is especially suitable for long-distance communication, but the transmission speed is slow.
Each piece of data of a message is transmitted bit by bit in orderSerial communication。The characteristics of serial communication are:Data bitsThe transmission of is carried out in bit order, and only one transmission line is needed at least;Low cost but slow transmission speed.The distance of serial communication can be from several meters to several thousand meters;According to the transmission direction of information, serial communication can be further divided into simplex, half duplex and full duplex.
origin
Announce
edit
Serial portAround 1980,Data transmission rate115kbps~230kbps.In the early days, serial ports were used to connect computer peripherals. In the early days, serial ports were generally used to connect mouse and external devicesModemAs well as old cameras and tablet equipment.The serial port can also be used for the interconnection and data transmission between two computers (or devices).Because serial port (COM) is not supportedHot plugAnd low transmission rate. Some new mainboards and most portable computers have started to cancel thisInterface。Serial ports are mostly used in industrial control and measurement equipment and some communication equipment.
Interface division standard
Announce
edit
Synchronous serial interface (English:Synchronous Serial Interface, SSI) is a common industrialcommunication interface。
Asynchronous serial refers to UART (Universal Asynchronous Receiver/Transmitter).UART is a chip with parallel input and serial output, which is usually integrated on the motherboard.UART contains TTL levelSerial portandRS232Level serial port.TTL levelIt is 3.3V, while RS232 is a negative logic level. It defines+5~+12V as low level, and - 12~- 5V as high level,MDS2710、MDS SD4、EL805Wait for RS232Interface, EL806 hasTTL interface。
Serial interface includes RS-232-CRS-422, RS485, etc.RS-232-C, RS-422 andRS-485The standard only specifies the electrical characteristics of the interface, and does not involve connectors, cables or protocols.
RS-232
Also called standardSerial port, the most commonly usedSerial communication interface。It was created in 1970 byElectronic Industry Association of America(EIA) Jointbell system 、ModemIt is jointly formulated by the manufacturer and the computer terminal manufacturer forSerial communicationStandards.Its full name is“[1]Data terminal equipmentTechnical standard for serial binary data exchange interface between (DTE) and data communication equipment (DCE) ".conventionalRS-232-CInterfaceThere are 22 wires in the standard, and the standard 25 core D-type socket (DB25) is used. Later, it was simplified to 9-core D-type socket (DB9), and the 25 core socket has been rarely used in applications.
RS-232 adopts unbalanced transmission mode, which is called single end communication.Since the difference between the transmission level and the reception level is only about 2V to 3V, its common mode rejection capability is poor. In addition to the distributed capacitance on the twisted pair, the maximum transmission distance is about 15m and the maximum speed is 20kb/s.RS-232 is forPoint to point(i.e. only one pair of receiving and transmitting equipment)DriverThe load is 3~7k Ω.So RS-232 is suitable for communication between local devices.[2]
RS-422
The full name of the standard is "Balanced Voltage Digital"InterfaceElectrical characteristics of the circuit ", which defines the characteristics of the interface circuit.A typical RS-422 is a four wire interface.In fact, there is also a signal ground wire, a total of 5 wires.Its DB9 connector pin definition.Because the receiver uses high input impedance and transmissionDriverStronger than RS232Driving power, so it is allowed to connect multiple receivers on the same transmission linenode, up to 10 nodes can be connected.That is, a master device, and the rest are slave devices. Slaves cannot communicate with each other, so RS-422 supports point to many two-way communication.The input impedance of the receiver is 4k, so the maximum load capacity of the transmitter is 10 × 4k+100 Ω (terminal resistance).Since the RS-422 four wire interface uses separate transmission and reception channels, it is unnecessary to control the data direction. Any necessary signal exchange between devices can be realized in software mode (XON/XOFF handshake) or hardware mode (a pair of separate twisted pairs).
The maximum transmission distance of RS-422 is 1219 meters, and the maximum transmission rate is 10 Mb/s.The length of the balanced twisted pair is inversely proportional to the transmission rate. The maximum transmission distance can be reached only when the speed is below 100kb/s.The highest rate transmission can only be achieved in a very short distance.Generally, the maximum transmission rate that can be obtained on a 100 meter long twisted pair is only 1 Mb/s.
RS-485
It is developed from RS-422, so many electrical regulations of RS-485 are similar to RS-422.If the balanced transmission mode is adopted, the terminating resistor shall be connected on the transmission line.RS-485 can adopt two wire and four wire modes. Two wire system can realize true multi-point two-way communication. When using four wire connection, just like RS-422, it can only realize point to many communication, that is, there can only be one master device, and the rest are slave devices. However, it is improved than RS-422. No matter four wire or two wire connection, 32 more devices can be connected to the bus.
The difference between RS-485 and RS-422 is that their common mode output voltage is different. RS-485 is between - 7V and+12V, while RS-422 is between - 7V and+7V. The minimum input impedance of RS-485 receiver is 12k Ω, and that of RS-422 is 4k Ω;Since RS-485 meets all RS-422 specificationsDriverIt can be applied in RS-422 network.
Like RS-422, RS-485 has a maximum transmission distance of 1219 meters and a maximum transmission rate of 10 Mb/s.The length of the balanced twisted pair is inversely proportional to the transmission rate. The specified longest cable length can be used only when the rate is below 100kb/s.The highest rate transmission can only be achieved in a very short distance.Generally, the maximum transmission rate of 100m twisted pair is only 1Mb/s.[2]
Different from parallel port
Announce
edit
Serial portIt can be described as a lane, andParallel portIt means that 8 lanes can transmit 8-bit (one byte) data at the same time.However, it does not mean that the parallel port is fast. Due to the mutual interference (crosstalk) between 8-bit channels, the transmission speed is limited and transmission is prone to errors.Serial ports do not interfere with each other.The parallel port sends a large amount of data at the same time, but it is slower than the serial port.[3]Serial hard diskThis is how people attach importance to it.
application
Announce
edit
Serial port of the switch
Switch'sSerial portIts English is trunk;It is used forNext JumprouteUsed for conversion.Each VLAN can be connected to the Internet only after being routed to TRUNK.
Commonly usedSerial portThere are 9-pin serial port (DB9) and 25 pin serial port (DB25). When the communication distance is relatively short (<12m), cable can be used to directly connect to the standard RS232 port (RS422, RS485 are relatively far). If the distance is relatively long, additionalModem(MODEM) or other relevant equipment.The simplest and most commonly used isThree wire systemThe grounding, receiving data and sending data are connected by three pins. The following involves the most basic connection, which is directly connected by RS232.
(1) Description of common signal pins of DB9 and DB25
DB9 | DB25
pin function name pin function name
1 Data carrier detection DCD 8 Data carrier detection DCD
2 Receive data RXD 3 Receive data RXD
3 Send data TXD 2 Send data TXD
4 Data terminal preparation DTR 20 Data terminal preparation DTR
first,Serial portThe transmission of data can be realized as long as there are receiving data pins and sending pins: the receiving pin and sending pin of the same serial port are directly connected by wire, and two serial ports are connected or one serial port is connected with multiple serial ports.
The receiving pin and the sending pin of the same serial port are directly connected by wire to the 9-pin serial port and the 25 pin serial port, both of which are 2 and 3.
Two different serial ports (either two serial ports of the same computer or serial ports of different computers)
The above is the standard for microcomputerSerial portIn terms of, there are many non-standard equipment, such as receiving GPS data or electronic compass data. Just remember one principle: the receiving data pin (or line) is connected with the sending data pin (or line), they cross each other, and the signal ground is connected correspondingly.
3. Several points for attention in serial port debugging:
Different coding mechanisms cannot be mixed, for example, RS232C cannot be directly connected with RS422InterfaceConnected, various special products on the marketconverterSold, can only be connected through a converter.
It is strongly recommended not to plug and dial with powerSerial portOtherwise, the serial port is easily damaged.
For large industrial control and measuring equipment, it is recommended to usePhotocouplerThe specific withstand voltage value shall be determined according to the actual demand.
PC motherboard serial port
Serial transmissionInterface, it can only transmit 1 Bit at a time.Serial portCan be used to connect external devicesModem, plotter, or serial printer.It can also connect network devices in the way of console connection, such asRouterandSwitch, which is mainly used to configure them.