12: M
ODBUS
ASCII/RTU C
OMMUNICATION
12-14
FC5A M
ICRO
S
MART
U
SER
’
S
M
ANUAL
FC9Y-B1268
Device Addresses for Modbus Slave
Special internal relays and special data registers are allocated to Modbus slave communication as shown below.
Special Internal Relay Device Addresses
Port 2
Ports 1, 3 to 7
Description
R/W
M8005
—
Communication Error
When a communication error occurs, communication error special internal relay
M8005 turns on for 1 scan time immediately after the error.
The error code is stored to special data register D8053.
R
M8080
—
Modbus Communication Completion Relay
Immediately after a request communication has been completed, Modbus communi-
cation completion relay M8080 turns on for 1 scan time. Similarly, when an error
occurs, M8080 turns on for 1 scan time. At the same time, the error code is stored to
special data register D8053.
R
Special Data Register Device Addresses
Port 2
Ports 1, 3 to 7
Description
R/W
D8053
—
Modbus Communication Error Code
When a Modbus communication error occurs, an error code is stored.
01h: Function error
02h: Access destination error
(address out of range, device quantity out of range)
03h: Device quantity error, 1-bit write data error
11h: ASCII code error (ASCII mode only)
12h: Frame length error
13h: BCC error
R
D8054
—
Modbus Communication Transmission Wait Time
When the MicroSmart sends communication, transmission wait time can be desig-
nated by storing a wait time value to D8054. Valid values are 1 through 5000 in milli-
seconds.
R/W
D8100
Port 1: —
Port 3: D8040
Port 4: D8041
Port 5: D8042
Port 6: D8043
Port 7: D8044
Modbus Slave Number (CPU modules with system program version 110 or higher)
The Modbus slave number of port 2 through port 7 can be changed by storing a num-
ber 1 through 247 into the corresponding special data registers, without the need for
downloading the user program. If the data stored in the special data register is not
within the valid range of slave number, the slave number designated in Function Area
Settings is used.
For example, in order to change the Modbus slave number of port 2, store a new Mod-
bus slave number in special data register D8100. As soon as the data in D8100 is
changed, the data becomes the Modbus slave number of port 2.
The data stored in these special data registers are saved to the ROM in the CPU mod-
ule and maintained even when the backup battery is dead.
R/W
Phone: 800.894.0412 - Fax: 888.723.4773 - Web: www.clrwtr.com - Email: [email protected]