78
Modbus RTU control (RS-485 communication)
11.3.5 Read/write of multiple holding registers (17h)
With a single function code, reading data and writing data for multiple successive registers can be performed.
Data is written rst, and then data is read from the specied registers.
z
Read
Data can be read from successive registers of up to 125.
Read the upper and lower data at the same time. If they are not read at the same time, the value may be invalid.
If multiple registers are read, they are read in order of register addresses.
z
Write
Data can be written to successive registers of up to 121.
Write the data to the upper and lower at the same time. If not, an invalid value may be written.
Registers are written in order of register addresses. Note that even when an exception response is returned because
some data is invalid as being outside the specied range, etc., other data may have been written properly.
z
Example of read/write
Prepare the read address and write address in a single query.
In this example, after writing the data to "Rotation speed" in the operation data No. 1, read the "Feedback speed" and
"Load factor."
This is an example when the feedback speed is assigned to the indirect reference 6 and the load factor is assigned to the
indirect reference 7. (Factory setting)
Description Register address
Value write
Corresponding hexadecimal Corresponding decimal
Indirect reference 6 (upper) 4876 (130Ch) 0000h
500
Indirect reference 6 (lower) 4877 (130Dh) 01F4h
Indirect reference 7 (upper) 4878 (130Eh) 0000h
50
Indirect reference 7 (lower) 4879 (130Fh) 0032h
Description Register address
Value write
Corresponding hexadecimal Corresponding decimal
Rotation speed of operation data No.0 (upper) 1152 (0480h) 0000h
500
Rotation speed of operation data No.0 (lower) 1153 (0481h) 01F4h
Rotation speed of operation data No.1 (upper) 1154 (0482h) 0000h
2500
Rotation speed of operation data No.1 (lower) 1155 (0483h) 09C4h