User manual

Modbus Commands
2-16
SIMATIC TI505/TI500 MODNIM User Manual
Modbus Function Descriptions (continued)
Code
06 allows the contents of a holding register to be changed. Addressing
is sequential up to the maximum memory size for a particular PLC. This
function is limited to integer values contained in V
-memory
. The MODNIM
will also direct any broadcast address (00) to all attached secondaries.
[This command is comparable to a TIW
A
Y I request using Primitive 30 and
TT
-type 01 (V
ariable memory)].
Because
of differences in memory mapping between Modbus PLCs
and SIMA
TIC TI PLCs, you should be quite certain of the effects of
the broadcast command before issuing it.
Example:
Request: 07 06 0064 0220 XXXX
Checksum (XXXX)
Data value (0220)
Register address (0064)
Function code (06)
Slave address (07)
Figure 2-16 Write
a Single Register Example — Request
This request to secondary 7 is asking for the value of holding register 0064
(100 decimal) to be changed to 0220 (544 decimal).
Response: 07 06 0064 0220 XXXX
Checksum (XXXX)
Data value (0220)
Register address (0064)
Function code (06)
Slave address (07)
Figure 2-17 Write
a Single Register Example — Response
The response to Function Code 06 is to return the request as received. In
the case of a broadcast request, there is no response.
Code 06 — W
rite a
Single Register
WARNING
!