EasyManuals Logo

Siemens Simatic S7 Series System Manual

Siemens Simatic S7 Series
726 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
Page #440 background imageLoading...
Page #440 background image
Libraries
9.3 Modbus library instructions
S7-200 SMART
440 System Manual, 09/2015, A5E03822230-AC
The MBUS_MSG instruction will read or write a maximum of 120 words or 1920 bits (240
bytes of data). The actual limit on the value of Count will depend upon the limits in the
Modbus slave device.
The parameter
DataPtr
is an indirect address pointer which points to the V memory in the
CPU for the data associated with the read or write request. For a read request, DataPtr
should point to the first CPU memory location used to store the data read from the Modbus
slave. For a write request, DataPtr should point to the first CPU memory location of the data
to be sent to the Modbus slave.
The DataPtr value is passed into MBUS_MSG as an indirect address pointer. For example, if
the data to be written to a Modbus slave device starts at address VW200 in the CPU, the
value for the DataPtr would be &VB200 (address of VB200). Pointers must always be a type
VB even if they point to word data.
Holding registers (address 4xxxx or 4yyyyy) and input registers (address 3xxxx) are word
values (2 bytes or 16 bits). CPU words are formatted the same as Modbus registers. The
lower numbered V memory address is the most significant byte of the register. The higher
numbered V memory address is the least significant byte of the register. The table below
shows how the CPU byte and word addressing corresponds to the Modbus register format.
Table 9- 26 Modbus Holding Register
CPU memory byte address
CPU memory word address
Modbus holding register address
Address
Hex data
Address
Hex data
Address
Hex data
VB200
12
VW200
12 34
40001
12 34
VB201
34
VB202 56 VW202 56 78 40002 56 78
VB203
78
VB204 9A VW204 9A BC 40003 9A BC
VB205
BC

Table of Contents

Other manuals for Siemens Simatic S7 Series

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Siemens Simatic S7 Series and is the answer not in the manual?

Siemens Simatic S7 Series Specifications

General IconGeneral
CPUVaries by model (e.g., S7-300, S7-400, S7-1200, S7-1500)
Communication InterfacesPROFIBUS, PROFINET, Ethernet, MPI
ProgrammingTIA Portal, STEP 7
Programming LanguagesLAD, FBD, STL, SCL, GRAPH
I/O ModulesDigital, Analog, Specialty modules available
Operating Temperature0°C to 60°C (standard models)
MountingDIN rail mounting
Operating Voltage24V DC or 120/230V AC (varies by model)
Protection ClassIP20 (standard models)
MemoryVaries depending on the S7 model. Includes work memory (RAM) for program execution, load memory (EEPROM or Flash) for program storage, and system memory for operating system functions. Memory sizes range from kilobytes to megabytes.

Related product manuals