20
Commander SK Advanced User Guide
www.controltechniques.com Issue Number: 9
FC23 Read/Write multiple
Writes and reads two contiguous arrays of registers. The slave imposes an upper limit on the number of registers which can be written. If this is
exceeded the slave will discard the request and the master will time out.
Table 6-7 Master request
Table 6-8 Slave response
6.1.7 Communications
timeouts
When a CT Modbus RTU master sends a message to a slave, the master should use a timeout to detect a missing response from a slave. Ideally, a
variable timeout will be used based on the number of hops a CT Modbus RTU message makes between the master and its eventual destination.
In practice a master may not be able to handle variable timeouts in such a fashion. If this is the case a single timeout should be used which is large
enough to cater for the longest route to a destination. The recommended timeouts for use with a specific product are given in the specific product user
guides.
6.1.8 Extended
data
types
Standard MODBUS registers are 16bit and the standard mapping maps a single X.Y parameter to a single MODBUS register. To support 32bit data
types (integer and float) the MODBUS multiple read and write services are used to transfer a contiguous array of 16bit registers.
Slave devices typically contain a mixed set of 16bit and 32bit registers. To permit the master to select the desired 16bit or 32bit access the top two bits
of the register address are used to indicate the selected data type.
The selection is applied for the whole block access
Byte
Description
0
Slave node address 1 through 247
0 is global
1
Function code 0x17
2
Start register address to read MSB
3
Start register address to read LSB
4
Number of 16bit registers to read MSB
5
Number of 16bit registers to read LSB
6
Start register address to write MSB
7
Start register address to write LSB
8
Number of 16bit registers to write MSB
9
Number of 16bit registers to write LSB
10
Length of register data to write (in bytes)
11
Register data 0 MSB
12
Register data 0 LSB
11+byte count CRC LSB
12+byte
count
CRC MSB
Byte
Description
0
Slave source node address
1
Function code 0x17
2
Length of register data in read block (in bytes)
3
Register data 0 MSB
4
Register data 0 LSB
3+byte count CRC LSB
4+byte count CRC MSB
NOTE
bit 15
TYP1
bits 0 - 13
Type select
Parameter address
X x 100+Y-1
bit 14
TYP0
Summary of Contents for 2202
Page 199: ......
Page 200: ...0472 0001 09 ...