EasyManua.ls Logo

Siemens SIMATIC S7-1200 - Page 1184

Siemens SIMATIC S7-1200
1614 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Communication processor and Modbus TCP
13.5 Modbus communication
S7-1200 Programmable controller
1184 System Manual, V4.2, 09/2016, A5E02486680-AK
HR_Start_Offset
Modbus holding register addresses begin at 40001. These addresses correspond to the
beginning PLC memory address of the holding register. However, you can use the
"HR_Start_Offset" variable to start the beginning Modbus holding register address at another
number instead of 40001.
For example, if the holding register starts at MW100 and is 100 words long. An offset of 20
specifies a beginning holding register address of 40021 instead of 40001. Any address less
than 40021 or greater than 40119 results in an addressing error.
Table 13- 68 Example of Modbus holding register addressing
HR_Start_Offset
Address
Minimum
Maximum
0
Modbus address (Word)
40001
40099
S7-1200 address MW100 MW298
20
Modbus address (Word)
40021
40119
S7-1200 address MW100 MW298
HR_Start_Offset is word data in the MB_SERVER instance data block that assigns the
starting address of the Modbus holding register. You can set this public static variable by
using the parameter helper drop list, after MB_SERVER is placed in your program.
For example, after you place MB_SERVER in a LAD network, you can go to a previous
network and assign HR_Start_Offset. The start address must be assigned prior to execution
of MB_SERVER.
Entering a Modbus server
variable using the default DB name:
1.
Set the cursor in the parameter field and
type an m character.
2.
Select "MB_SERVER_DB" from the drop
list of DB names.
3.
Select
"MB_SERVER_DB.HR_Start_Offset" from
the drop list of DB variables.

Table of Contents

Other manuals for Siemens SIMATIC S7-1200

Related product manuals