Some may still be unaware of what Modbus is; in fact, Modbus is widely used in real life, and it is present in almost all industrial electronic device systems.
Below, we will describe some common questions about Modbus for beginners.
What is Modbus?
Modbus is a communication protocol developed by Modicon (now Schneider Electric) in 1979 for PLCs, primarily used for networking communication between industrial electronic devices.
Modbus is an application layer communication protocol, located at the 7th layer of the OSI (Open Systems Interconnection) model. It provides client/server communication between devices connected over different types of buses or networks.
Modbus consists of a Master (host) and up to 247 Slaves (devices).
What is Modbus used for?
Modbus is an open communication protocol that you can apply to your devices without paying royalties.
Modbus is a widely used standard communication protocol; if your devices and those from other manufacturers all adhere to the Modbus standard protocol, they can communicate and transmit data.
How does Modbus work?
Modbus typically communicates over a UART serial port 485. The simplest communication between one master device and one slave device is done through the serial port Tx and Rx for data transmission.
The underlying serial communication is the familiar “0” and “1” communication; on this basis, the Modbus communication protocol is added to facilitate protocol parsing and multi-device networking.
What is Modbus ASCII?
Modbus ASCII is one of the transmission methods in the Modbus protocol; besides this, there is also the Modbus RTU transmission method.
After Schneider Electric acquired Modicon, they introduced the Modbus TCP protocol.
Protocol format:
What is a slave address?
A slave address (or slave station ID) is a unique address assigned to each slave device, facilitating identification during communication establishment by the master. The slave address is set during manufacturing.
What is a function code?
The function code is an item in the Modbus communication protocol; the second byte sent by the master is the function code. This is what you see as reading and writing coil registers.
Here are some common function codes:
What is CRC?
Standard communication protocols generally have a checksum to ensure that the transmitted data is error-free; checksums and CRC checks are common in embedded devices communication protocols.
Modbus uses CRC cyclic redundancy check, and its checksum information is located in the last two bytes of the message.
What is byte/word order?
Byte order refers to whether to store (transmit) the high byte first or the low byte first. For example: 0x1234 consists of two bytes, and during transmission, it is usually split into 0x12 and 0x34.
In communication, byte order issues are involved, but the Modbus specification does not precisely define how data is stored in registers.
The Modbus standard protocol does not specifically stipulate this; developers just need to arbitrarily agree on whether to transmit the high byte or the low byte first during development.
Finally
Modbus is a widely used standard communication protocol. Students in industrial automation, electronics, and embedded systems are advised to take some time to learn it.
Due to time constraints, this article only introduces some basic content. For more detailed information about the protocol, please visit the official website for in-depth understanding.

Due to recent changes in the WeChat public platform push rules, many readers have reported not seeing updated articles in time. According to the latest rules, it is recommended to click on “Recommended Read, Share, Collect,” etc., to become a regular reader.
Recommended Reading:
-
Regrettably! Another old PCB company in Guangdong has gone bankrupt
-
A programmer was asked to return all year-end bonuses due to a bug!
-
The unfinished era’s 12-inch wafer factory has finally found a buyer!!
Please click 【View】 to give the editor a thumbs up
