Why is Parallel better than Serial?

table of Contents

What is serial communication

Classification of serial communication

Features of serial communication

What is parallel communication

Features of parallel communication

 Serial and parallel analysis

Reference


What is serial communication

  Serial communication refers to the use of a data line to transmit data bit by bit, and each bit of data occupies a fixed length of time. It only needs a few lines to exchange information between systems, which is especially suitable for long-distance communication between computers and computers , and between computers and peripherals.

Classification of serial communication

  Serial communication can be divided into two types: synchronous communication and asynchronous communication. Synchronous communication is to realize the sending and receiving of data by recognizing synchronous characters in software. Asynchronous communication is a communication method that uses character resynchronization technology .

  1. Synchronous communication

  Synchronous communication is a communication method that continuously transmits data serially, and only one frame of information is transmitted at a time. The information frame here is different from the character frame in asynchronous communication, and usually contains several data characters.

  They are composed of synchronization characters, data characters and check characters (CRC). The synchronization character is located at the beginning of the frame and is used to confirm the beginning of the data character. After the synchronization character, the number of data characters is not limited and is determined by the length of the data block to be transmitted; there are 1 to 2 check characters, which are used by the receiving end to verify the correctness of the received character sequence. The disadvantage of synchronous communication is that it requires strict synchronization between the sending clock and the receiving clock.

  2. Asynchronous communication

  In asynchronous communication, there are two more important indicators in asynchronous communication: character frame format and baud rate . Data is usually transmitted in a character frame in units of characters or bytes. The character frame is sent frame by frame by the sender, and received by the receiving device frame by frame through the transmission line. The sending end and the receiving end can control the sending and receiving of data by their respective clocks. These two clock sources are independent of each other and are not synchronized with each other.

  When the receiving end detects the low-level logic "0" (that is, the start bit of the character frame) sent over the transmission line, it determines that the sender has started to send data. Whenever the receiving end receives the stop bit in the character frame, it knows One frame of characters has been sent.

Features of serial communication

  Data is transmitted in sequence on a single bit-wide transmission line, one bit after another, called serial communication. In parallel communication , one byte (8 bits) of data is simultaneously transmitted from the source to the destination on 8 parallel transmission lines; while in serial communication, data is transmitted one by one on a single 1-bit wide transmission line. Sequentially transfer. Such a byte of data must be transmitted one by one sequentially from low to high in 8 times. It can be seen that the characteristics of serial communication are as follows:

  1. It is obvious to save transmission lines. Especially in remote communication, this feature is particularly important. This is also the main advantage of serial communication.

  2. The data transmission efficiency is low. Compared with parallel communication, this is also obvious. This is also the main disadvantage of serial communication.

  For example: to transmit one byte, parallel communication only needs 1T time, while serial communication needs at least 8T time. It can be seen that serial communication is suitable for long-distance transmission, ranging from a few meters to thousands of kilometers. For long-distance, low-speed communication, serial communication is often the only option. Parallel communication is suitable for short-distance, high-speed data transmission , and the transmission distance is usually less than 30 meters. It is particularly worth mentioning that the existing public telephone network is a universal long-distance communication medium. Although it is designed for the transmission of sound signals, the use of modulation and demodulation technology can make the existing public telephone network system serial data communication. Provide convenient and practical communication lines.

What is parallel communication

  The computer between the terminal and the data transmission typically rely on a cable current or voltage change channels or implemented. If each data bit of a group of data is transmitted on multiple lines at the same time, this transmission method is called parallel communication .

  In parallel communication, each bit of data is transmitted at the same time, which can be carried out in parallel in units of words or bytes. Parallel communication is fast, but it uses many communication lines and high cost, so it is not suitable for long-distance communication. Various internal buses of a computer or PLC transfer data in parallel.

Features of parallel communication

  1. All data bits are transmitted at the same time, with fast transmission speed and high efficiency. It is mostly used in real-time and fast occasions.

  2. The most basic information exchange method in a microcomputer system .

  3. The information transmitted in parallel does not require a fixed format.

  4. The data transmission rate of the parallel interface is 8 times faster than that of the serial interface, and the theoretical value of the data transmission rate of the standard parallel interface is 1Mbps (megabits per second).

  5. The data width of parallel transmission can be 1 to 128 bits, or even wider, but as many data lines are required as there are data bits, the transmission cost is higher.

  6. The anti-interference ability of parallel communication is poor.

  7. The data transmission within the integrated circuit chip, between the components on the same plug-in board, and between the plug-in boards in the same chassis are all parallel.

  8. With the word length of the computer, usually 8-bit, 16-bit or 32-bit as the transmission unit, one word-length data is transmitted at a time.

  9. It is suitable for close, large and fast information exchange between external equipment and microcomputer.

  10. Parallel data transmission is only suitable for short-distance communication , usually the transmission distance is less than 30 meters.

  Parallel interface :

  Generally, the parallel interface has 3 functions:

  ⑴Realize the connection with the system bus: provide data input and output functions.

  ⑵Realize connection with peripherals: to ensure effective data reception and transmission with peripherals.

  (3) With interrupt request processing function: peripheral input and output are realized by interrupt method.

  Interface connection :

  Typical bidirectional parallel interface and peripheral connection

  ⒈The connection of parallel interface and CPU

  ⑴Data bus: It is the channel for data exchange between CPU and parallel interface .

  ⑵Read and write signal line: control the flow of data, determine whether the operation is read or write.

  ⑶ Reset line, ready status line: Parallel interface data is ready.

  ⑷Interrupt request line: The parallel interface makes an interrupt request to the CPU.

  ⑸Address decoding circuit: choose different interface circuits, and choose different registers inside the interface circuit.

  ⒉The connection of parallel interface and peripherals

  ⑴ Input equipment: data input line, equipment data ready status line and interface receiving data answer line.

  ⑵ Output device: data output line, interface data ready status line and peripheral receiving data answer line.

  ⒊Parallel interface

  ⑴Control register: Receive control commands from CPU.

  ⑵Data input buffer, data output buffer: for data input and output.

  ⑶ Status register: Provide the working status of the interface circuit for the CPU to query.

  Transmission principle :

  ⒈ Parallel interface input data process

  The peripheral sends the data to the "data input line", through the "input data ready" status line to notify the parallel interface to take it away, the interface latches the data to the "input buffer", and informs the peripheral through the "data input answer" line, The interface data buffer is full. Do not send any more data. The interface has the corresponding position of the "status register" in it, which is convenient for the CPU to query and the interface to send interrupt requests to the CPU.

  After the CPU  removes the data from the interface, the interface clears the "data input ready" and "data input answer" signals so that the peripheral can input the next data.

  ⒉ Parallel interface output data process

  The interface "data output buffer" is empty, and the "data output ready" status line is sent to 1, and the data sent by the CPU is reset and cleared to 0. The data is sent to the peripheral through the "data output" line, and the "data output is ready" ”Line informs the peripheral to fetch data.

  Examples :

  The most basic information exchange method in a microcomputer system :

  For example: microcomputer and parallel interface printer , disk drive.

  For example: between the various components on the system board, an interface board between the member.

 

 Serial and parallel analysis

Why is Parallel better than Serial? The feature of parallelism is that you can do other things at the same time. A common point in the process of system optimization is that interface requests are merged. The merge requests must also be processed in parallel, otherwise the time advantage is not big. The biggest advantage of parallelism is that different business processing can be done at the same time, which greatly shortens the waiting time of users and improves user experience. Take the following picture as an example:

Code and thought are equally important, code without thought is dead code, code with soul and thought is the improvement of the code level!

Reference

Kushiyuki communication: https://wiki.mbalib.com/wiki/%E4%B8%B2%E8%A1%8C%E9%80%9A%E4%BF%A1

Parallel communication: https://wiki.mbalib.com/wiki/%E5%B9%B6%E8%A1%8C%E9%80%9A%E4%BF%A1

Guess you like

Origin blog.csdn.net/boonya/article/details/108992548