Siemens SIMATIC NET CP 5613 Manual page 50

Dp base programming interface
Table of Contents

Advertisement

Overview of the DP Base Interface
Elements of a Polling Cycle
All the steps described below are achieved by direct access to the process image
using the C pointer as the result of the "DP_get_pointer" call.
Taken together, they represent an example of a polling cycle.
Step
1
2
3
4
5
6
7
50
Action
Check the mode of the
master in the process
image (USIF_state,
Section 4.3.6)
Check the state of the
slaves in the process
image (slave_state,
Section 4.3.5)
Optional: Check whether a
slave has changed data
(req_mask, Section 4.3.4),
If yes: reset req_mask
Read input data of the
slaves (slave_in[ ].data,
Section 4.3.1),
consistency by accessing
D_lock_in_slave_adr
Check new diagnostic
data of the slaves
(diag_count, Section
4.3.2)
If applicable, read
diagnostic data of the
slaves (slave_diag[ ].data,
Section 4.3.2),
consistency by accessing
D_lock_diag_slave_adr
Write output data of the
slaves (slave_out[ ].data)
Meaning
Input data are only valid in the
OPERATE and CLEAR modes. Output
data can only be sent in the OPERATE
mode.
Communication functions only when
the slaves are in the READY mode.
Your user program can recognize
whether or not input data from a slave
has changed.
For further processing in the user
program
If the diagnostic counter has changed
since the last cycle, there is new
diagnostic data.
For further processing in the user
program
As the result of processing the input
and diagnostic data
DP Base Programming Interface for CP 5613/CP 5614
C79000-G8976-C108-02

Advertisement

Table of Contents
loading

This manual is also suitable for:

Simatic net cp 5614

Table of Contents