Interview questions on Modbus

Below is the list of the most important interview questions on Modbus:

1. What is Modbus and how does it work?

Modbus is an application layer-level communication protocol that defines rules for organizing and interpreting data and is essentially a messaging structure that is independent of the underlying physical layer. It is an open-source protocol and is widely supported by many manufacturers. It was designed by Modicon. Data can be transmitted over serial lines (Modbus RTU) or via Ethernet (TCP/IP). These devices communicate using a master-slave technique. Only the master can initiate transactions and the slaves respond by supplying the requested data to the master, or by taking the action requested in the query.

The official Modbus specification can be found at http://www.modbus.org/ 

The data is sent as a series of bits. Each bit is sent as a voltage such that positive voltages stand for zero bits and negative voltages stand for one bit.

2. What are the different versions of the Modbus protocol?

  • Modbus RTU
  • Modbus ASCII
  • Modbus TCP/IP
  • Modbus Plus

3. What are the mediums used for Modbus communication?

  • RS 232
  • RS 485
  • RS 422
  • Ethernet

4. What are master and slave in Modbus?

The Master is the device from which a request is sent for the execution of a function whereas the slave is the device that responds to the request made by the master. The slave processes the master’s requests and responds with the result.

5. What are the basic settings required at the slave to enable Modbus RTU communication?

The following are the necessary settings at the slave end to enable communication:

  • Slave ID.
  • Baud rate.
  • Parity bit.

6. What is a slave ID?

Each slave device in the network is assigned a unique address. This address is referred to as the slave ID.

7. What is a baud rate?

Baud rate is the rate at which the signal is sent across the transmission medium per second. It is basically the transmission speed. Following are the possible baud rates in Modbus: 300, 600, 1200, 2400, 4800, 9600, 14400, 19200, 28800, 38400, 57600, 115200bps.

8. What is parity bit?

The parity bit is an additional bit added to the transmitted message block, depending on the setting, either even or odd, it indicates the number of 1s in the transmitted message block.

  • The parity is set to even, 1 is added to the end of the message block if there are an even number of 1-bits in the transmitted message block. 0 is added if there are an odd number of 1-bits.
  • The parity is set to odd, and 1 is added to the end of the message block if there are an odd number of 1-bits in the transmitted message block. 0 is added if there are even number of 1-bits.

Learn more about parity bits: https://erg.abdn.ac.uk/users/gorry/eg3576/parity.html

9. How many slaves can be connected to a Modbus master?

The number of slaves that can be connected to a master varies for each communication medium. Below is the list:

MediumNumber of slavesMax devices (including master)
RS 23212
RS 232 + Bridge connection247248
RS 4221011
RS 4853131
Modbus TCP/IP254255
Read more: https://forums.ni.com/t5/Counter-Timer/how-many-different-kinds-of-devices-can-be-connected-to-modbus/td-p/1678008

10. What does a typical Modbus data packet look like?

A Modbus data pocket or ADU (Application Data Unit) structure is shown below:

Modbus data packet

This Post Has One Comment

  1. kishor gaikwad

    Understanding Very Easily… thank you team

Leave a Reply