Modbus Rtu Protocol; Transmission Modes; Message Structure For Rtu Mode; Address - WEG CFW100 User Manual

Modbus rtu
Hide thumbs Also See for CFW100:
Table of Contents

Advertisement

4 MODBUS RTU PROTOCOL

The Modbus RTU protocol was initially developed in 1979. Nowadays, it is a widely spread open protocol, used
by several manufactures in many equipments.
4.1

TRANSMISSION MODES

Two transmission modes are defined in the protocol specification: ASCII and RTU. The modes define the way
the message bytes are transmitted. It is not possible to use the two transmission modes in the same network.
The CFW100 frequency inverter uses only the RTU mode for the telegram transmission. The bytes are
transmitted in hexadecimal format and its configuration depends on the programming done by means of P0311.
4.2

MESSAGE STRUCTURE FOR RTU MODE

The Modbus RTU structure uses a master-slave system for message exchange. It allows up to 247 slaves, but
only one master. Every communication begins with the master making a request to a slave, which answers to
the master what has been asked. In both telegrams (request and answer), the used structure is the same:
Address, Function Code, Data and CRC. Only the data field can have a variable size, depending on what is
being requested.
Master (request telegram):
Slave (response telegram):
4.2.1

Address

The master initiates the communication sending a byte with the address of the slave to which the message is
destined. When sending the answer, the slave also initiates the telegram with its own address. The master can
also send a message to the address 0 (zero), which means that the message is destined to all the slaves in the
network (broadcast). In that case, no slave will answer to the master.
4.2.2

Function Code

This field also contains a single byte, where the master specifies the kind of service or function requested to the
slave (reading, writing, etc.). According to the protocol, each function is used to access a specific type of data.
For the available list of supported functions, refer to item 5.
4.2.3

Data Field

It is a variable size field. The format and contents of this field depend on the used function and the transmitted
value. This field is described together with the function description (refer to item 5).
4.2.4

CRC

The last part of the telegram is the field for checking the transmission errors. The used method is the CRC-16
(Cycling Redundancy Check). This field is formed by two bytes; where first the least significant byte is
transmitted (CRC-), and then the most significant (CRC+). The CRC calculation form is described in the protocol
specification; however, information for its implementation is also supplied in the Apêndice B.
4.2.5

Time Between Messages

In the RTU mode there is no specific character that indicates the beginning or the end of a telegram. The
indication of when a new message begins or when it ends is done by the absence of data transmission in the
network, for a minimum period of 3.5 times the transmission time of a data byte (11 bits). Thus, in case a
telegram has initiated after the elapsing of this minimum time, the network elements will assume that the first
Phone: 800.894.0412 - Fax: 888.723.4773 - Web: www.ctiautomation.net - Email: info@ctiautomation.net
Address
Function
(1 byte)
(1 byte)
Address
Function
(1 byte)
(1 byte)
Request Data
(n bytes)
(2 bytes)
Response Data
(n bytes)
(2 bytes)
Modbus RTU Protocol
CRC
CRC

Advertisement

Table of Contents
loading

Table of Contents