Appendix B – Modbus Protocol
B-4
NMBA-01 Installation and Start-up Guide
Modbus Message
Framing
In either of the two serial transmission modes (ASCII or RTU), a Mod-
bus message is placed by the transmitting device into a frame that has
a known beginning and ending point. This allows receiving devices to
begin at the start of the message, read the address portion and deter-
mine which device is addressed (or all devices, if the message is
broadcast), and to know when the message is completed. Partial mes-
sages can be detected and errors can be set as a result.
RTU Framing
In RTU mode, messages start with a silent interval of at least 3.5 char-
acter times. This is most easily implemented as a multiple of character
times at the baud rate that is being used on the network (shown as
T1-T2-T3-T4 in the figure below). The first field then transmitted is the
device address.
The allowable characters transmitted for all fields are hexadecimal 0-9,
A-F. Networked devices monitor the network bus continuously, includ-
ing during the ‘silent’ intervals. When the first field (the address field) is
received, each device decodes it to find out if it is the addressed
device.
Following the last transmitted character, a similar interval of at least 3.5
character times marks the end of the message. A new message can
begin after this interval.
The entire message frame must be transmitted as a continuous
stream. If a silent interval of more than 1.5 character times occurs
before completion of the frame, the receiving device flushes the incom-
plete message and assumes that the next byte will be the address field
of a new message.
Similarly, if a new message begins earlier than 3.5 character times fol-
lowing a previous message, the receiving device will consider it a con-
tinuation of the previous message. This will set an error, as the value in
the final CRC field will not be valid for the combined messages. A typi-
cal message frame is shown below.
Figure B-2 Message Frame
START ADDRESS
FUNCTION
DATA
CRC
CHECK
END
T1–T2–T3–T4
8 BITS
8 BITS
n × 8 BITS
16 BITS
T1–T2–T3–T4
efesotomasyon.com - Control Techniques,emerson,saftronics -ac drive-servo motor