Protocols are rules that devices follow to communicate with each other. They ensure that data is sent and received correctly. Without protocols, devices would not understand each other, and data communication would fail. Protocols also help in error detection and correction, making communication reliable.
Serial Transmission Protocols List
The following is the list of protocols used in serial transmission:

1. UART (Universal Asynchronous Receiver/Transmitter)
UART is a simple and widely used protocol. It is asynchronous, meaning there is no shared clock signal. Data is sent in packets with a start bit, data bits, and a stop bit. The start bit tells the receiver that data is coming, and the stop bit signals the end of the data packet.
UART is commonly used in communication between a computer and a microcontroller, such as an Arduino. For example, when you upload code to an Arduino, the data is sent using UART.
2. SPI (Serial Peripheral Interface)
SPI is a synchronous protocol, meaning it uses a shared clock signal to synchronize data transmission. It is faster than UART and supports full-duplex communication. It allows data to be sent and received at the same time.
SPI uses four wires: MOSI (Master Out Slave In), MISO (Master In Slave Out), SCLK (Clock), and SS (Slave Select).
The master device controls the communication, and the slave device responds. SPI is often used in communication between a microcontroller and sensors or displays. For example, an SPI display shows data sent from a microcontroller.
3. I2C (Inter-Integrated Circuit)
I2C is a synchronous protocol that uses only two wires: SDA (Data Line) and SCL (Clock Line). It supports communication between multiple devices on the same bus. Each device has a unique address, and the master device controls the communication.
I2C is commonly used in communication between a microcontroller and multiple sensors or memory chips. For example, a temperature sensor and a memory chip can both be connected to a microcontroller using I2C.
4. USB (Universal Serial Bus)
USB is a popular protocol used in many devices like flash drives, keyboards, and smartphones. It supports high-speed data transfer and power delivery. USB uses a master-slave architecture, where the computer (master) controls the communication with the devices (slaves).
USB is widely used in modern devices because it is fast, reliable, and easy to use. For example, when you plug a USB flash drive into your computer, data is transferred using the USB protocol.
5. RS-232
RS-232 is an older protocol used for serial communication. It is asynchronous and uses voltage levels to represent data. RS-232 is commonly used in industrial equipment and older computers.
For example, it was used in communication between a computer and a modem. Although it is not as common today, RS-232 is still used in some industrial applications.
How Protocols Work in Real Life
Let’s take an example of UART to understand how protocols work. The sender (transmitter) prepares the data packet by adding a start bit at the beginning and a stop bit at the end. The data is sent one bit at a time over the communication line. The receiver listens for the start bit and then collects the data bits.
Once the stop bit is received, the receiver knows the data packet is complete. This process ensures that data is transmitted correctly and efficiently.
Comparison of Serial Protocols
Here is a simple comparison of the most common serial protocols:
Protocol | Type | Speed | Wires Used | Example Use |
---|---|---|---|---|
UART | Asynchronous | Low to Medium | 2 (TX, RX) | Communication between Arduino and PC |
SPI | Synchronous | High | 4 (MOSI, MISO, SCLK, SS) | Communication with sensors/displays |
I2C | Synchronous | Medium | 2 (SDA, SCL) | Communication with multiple sensors |
USB | Synchronous | Very High | 4 (Power, Data+, Data-, Ground) | Flash drives, smartphones |
RS-232 | Asynchronous | Low | 2 (TX, RX) | Industrial equipment, older modems |