ProSoft Technology 5204SE-MNET-PDPMV1 User Manual

Page 161

Advertising
background image

Reference 5204SE-MNET-PDPMV1

♦ ProLinx Gateway

User Manual

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


ProSoft Technology, Inc.

Page 161 of 235

December 22, 2009

4.5.5 Sample Control and Sequencing Logic for Cyclic Data Polling -

Quantum

Here is a structured text (ST) logic example of how you might control and
sequence the PROFIBUS cyclic data DFBs. You may adapt this sample to fit
your application or you may choose to create your own control and sequencing
scheme that is more suitable for your specific needs.

For this example, start by creating two variables:

LastExecuted as

type

INT

Start as

type

BOOL

Then, you can use the following ST logic code. Each time you set the variable
Start equal to 1, it will begin executing a sequence to read cyclic inputs, write
cyclic outputs, get general gateway status, and get standard PROFIBUS slave-
specific diagnostic data. As long as Start remains equal to 1, this sequence will
roll-over and be repeated until interrupted by setting Start = 0.

Advertising