beautypg.com

Blocks – ProSoft Technology 5204SE-MNET-PDPMV1 User Manual

Page 137

background image

Reference 5204SE-MNET-PDPMV1

♦ ProLinx Gateway

User Manual

Modbus TCP/IP to PROFIBUS DP-V1 Pass-Through Master


ProSoft Technology, Inc.

Page 137 of 235

December 22, 2009

4.5

Modicon Quantum Variables, Derived Data Types and Derived
Function Blocks

4.5.1 Quantum Communication Control and Data Buffer Variables

and Derived Data Types (DDTs)

The MBP_MSTR function used by the Quantum platform performs a similar
function to that of the DATA_EXCH function in the M340 platform. However, the
MBP_MSTR function uses a different structure which requires the use of two
variable arrays: a data buffer array, called BufferArray, and a control parameter
array, called ControlArray.

To make it more convenient for you, the two DDTs and variable arrays have
been combined into one mid-level structure, called ControAndBufferArrays DDT.

The BufferArray is used to hold only the data to be sent or the data received in
the Modbus message created by the MBP_MSTR function. The BufferArray is
an array of 100, 16-bit integer registers. Since this array holds only the data
contained in a Modbus message, the significance of the values in this array
depends on how the data is to be used in the application.

The ControlArray holds all the parameters needed to determine the type of
message to be sent (read or write message), the amount of data to transfer in the
message (register count), and the address of the device that will be the message
target (the IP address of the ProLinx gateway). This array has a fixed structure,
which each element contains the value for a specific MBP_MSTR parameter.
Here are the definitions of the parameters held in the ControlArray.

Variable Name

Size/Type

Description

Control[1] 1

16-bit Integer
Array Element

Holds the MBP_MSTR Block Function Code for the
communication operation to be performed.

1 = Write Operation

2 = Read Operation