Read-only memory read instruction(04) and memory lists
The length of total register requested by a single reading command must be less than or equal to 20 registers. Instructions longer than this will be ignored.
Instruction example
CommentShare feedback on the editorFormat of command (04) from masterCommentShare feedback on the editor
Byte#
1
2
3
4
5
6
7
8
Node ID
Slave Address
Function Code
Address of first reading register
Address of first reading register
Quantity of registers to be read
Quantity of registers to be read
CRC
CRC
Example 01~FF
01
04
00
00
00
02
71
CB
Description of master command
The example will read instantaneous flow volume.
slave address: 01(address of this flowmeter)
function code: 04(read instruction)
Address of first reading register: 0000(Address of first register to read)
Quantity of registers to be read: 0002 (need to read 2 registers from 0000)
CRC: 71 CB(Calculating error correcting code according to CRC algorithm)
Format of flowmeter response(04)
CommentShare feedback on the editor
Byte#
1
2
3
4
5
6
7
8
9
Node ID
Slave Address
Function Code
Amount of response Byte
Data Byte #1
Data Byte#2
Data Byte#3
Data Byte#4
CRC
CRC
Example01~FF
01
04
04
00
00
00
00
FB
84
Description of flowmeter response example
slave address: 01(address of this flowmeter)
function code: 04(read instruction)
Amount of response Byte: 04 (2 register=4 byte)
Data Byte: 00 00 00 00(Assume the instantaneous flow volume is 0)
CRC: FB 84(Calculating error correcting code according to CRC algorithm)
Definition and address of memory
How to use these charts
Read-write memory type
Function
Memory content
Describe the memory content function.
Register location
Read-write memory locations are not shared with read-only memory.
Register length
The length of variable memory. The unit is Register(2Byte).