Chapter 8 20 Points RS485 type Models Instruction
209
MU instruction (Modbus RTU master)
MU function performs Modbus RTU communication at RS485 port. There are 15 MU coils can be used in
ladder mode, MU01~MU0F, and up to 250 MU function blocks diagram in FBD mode.
There can be several MU commands executed at the same time, but only one command can be performed, the
rest are postponed until the performed one is accomplished.
Hardware Configuration:
1.
Connect the RS485 port A on each SG2 unit together, also do it to port B, as shown in below figure.
2.
Set SG2 in the SET menu to No Remote IO.
3.
Set SG2 ID = 01~99.
Function mode corresponding communication function code:
mode Communication
function
code
1
03 (Read Registers)
2
06 (Write Single Register)
3
10 (Write Multiple Registers)
4
01 (Read Coils)
5
05 (Write Single Coil)
The M coil used for Modbus function:
Received (M3D)
M3D turns ON after received, then check-up for error. Transferring data to
target address if there is no error.
Error flag (M3E)
communication error flag
Time out flag (M3F)
M3F turns ON when the master does not get any response from slaver within
certain time. M3F will automatically reset if M3D reset.
The time of time out is depending communication baud rate as shown in the table below:
Baud rate (bps)
Time (ms)
4800
、
9600
、
19200
、
38400
125
57600 100
115200 80
In Ladder mode, there are 5 parameters in Modbus function as shown in below.
symbol Description
PDF compression, OCR, web optimization using a watermarked evaluation copy of CVISION PDFCompressor