Modbus services

Principle of the Modbus protocol

The Modbus protocol is a master-slave protocol.

Only one device can transmit on the line at any one time.

The master manages the exchanges and only it can take the initiative.

It interrogates each of the slaves in succession.

No slave can send a message unless it is invited to do so.

Master

In the event of an error during data exchange, the master repeats the question and declares the interrogated slave absent if no response is received within a given time period.

If a slave does not understand a message, it sends an error response to the master. The master may or may not repeat the request.

Slave i

Slave j

Slave k

 

Two types of dialog are possible between master and slaves:

The master sends a request to a slave and waits for it to respond. The request contains the slave address (1 ... 247).

Broadcast: the master sends a request to all slaves. Slaves do not answer. The value of the slave address is 0.

Direct slave-to-slave communications are not possible.

For slave-to-slave communication, the master’s application software must therefore be designed to interrogate one slave and send back data received to the other slave.

RTU mode

ATV212 supports RTU mode.

The Modbus RTU frame contains no message header byte, nor end of message bytes.

It is defined as follows:

Slave address

Function code

Data

CRC16

The data is transmitted in binary code. CRC16: Cyclic redundancy check parameter.

The end of the frame is detected on a silence greater than or equal to 3 characters.

The master must not introduce a space of more than 3.5 characters in a frame; otherwise the drive may recognize it as a start of new frame.

32

S1A53844 01/2011

Page 32
Image 32
Schneider Electric Altivar 212 manual Principle of the Modbus protocol, RTU mode, Slave Slave j Slave k