Modbus Instruction Operation Instructions - Ebyte ME31-XAAX0440 User Manual

Network i/o networking module
Hide thumbs Also See for ME31-XAAX0440:
Table of Contents

Advertisement

Chengdu Ebyte Electronic Technology Co.,Ltd.

4.9.5 Modbus instruction operation instructions

(1) Read the status of the coil (DO)
Use the read coil status (01) function code to read the output coil status, for example:
01
Modbus address
Function Code
After sending the above command to the device via the RS485 bus, the device will return the following values:
01
Modbus address
The status data 01 returned above indicates that the output DO1 is on.
(2) Control coil (DO) status
Support operation of single coil (05), operation of multiple coils (0F) function code operation.
Use the 05 command to write a single command, for example:
01
Modbus address
After sending the above command to the device via the 485 bus, the device will return the following values:
01
Modbus address
The DO1 coil is turned on.
Use 0F function code to write multiple coil commands, for example:
01
0F
Modbus
Function
address
Code
After sending the above command to the device via the 485 bus, the device will return the following values:
01
Modbus address
The coils are all turned on.
(3) Read the holding register
Copyright ©2012–2021,Chengdu Ebyte Electronic Technology Co.,Ltd.
01
00 00
Register first
address
01
Number of bytes of
Function Code
05
Function Code
Register first address
05
Function Code
Register first address
00 00
00 04
Number of
initial address
0F
Function Code
Register Address
00 04
Number of output coils read
01
Status data returned
data
00 00
Conduction:FF 00
closure:00 00
00 00
Operation method
01
Number of
coils
bytes of data
00 00
Number of coils
ME31-XAAX0440_UserManul_EN
CRC checkcode
01
90 48
CRC checkcode
FF 00
8C 3A
CRC checkcode
FF 00
8C 3A
CRC checkcode
0F
Control coil data
OO O4
54 08
CRC checkcode
3D C9
7E 92
CRC
checkcode
22

Advertisement

Table of Contents
loading

Table of Contents