I/O Terminal /
OVERVIEW
12
Diagnosis During Cyclic Data Exchange
A slave can send a diagnostics signal to the master during cyclic data exchange. In this case, the
slave sets a flag in the DataExchange response telegram, whereby the master recognizes that
there is new diagnostic data in the slave. It then fetches that data in the SlaveDiag telegram. This
means that diagnostic data is not transmitted to the controller with the cyclic I/O data in real-time,
but is always at least one DP cycle later.
Synchronization with Sync and Freeze
The Sync and Freeze commands in the GlobalControl request telegram (broadcast telegram)
allow the master to synchronize the activation of the outputs (Sync) or the reading of the inputs
(Freeze) in a number of slaves. When the Sync command is used, the slaves are first switched
into Sync mode (a process that is acknowledged in the diagnostic data). The I/O data is then
exchanged sequentially with the slaves in the DataExchange telegram. Transmitting the Sync
command in the GlobalControl telegram then has the effect of causing the slaves to generate the
most recently received outputs. In Freeze operation a Freeze command is first sent in the
GlobalControl telegram, in response to which all the slaves latch their inputs. These are then
fetched sequentially by the master in the DataExchange telegram.
States in the Master
The master distinguishes between the CLEAR state (all outputs are set to the Fail_Safe value)
and the OPERATE state (all outputs have the process value). The Master is usually switched into
the CLEAR mode when, for instance, the PLC enters STOP.
Class 1 and Class 2 DP Masters
The Class 1 master refers to the controller that carries out cyclic I/O data exchange with the
slaves, while a Class 2 master is a B&B device that generally only has read access to the slaves'
I/O data.
2.4 PROFIBUS
DPV1
PROFIBUS DPV1 refers primarily to the acyclic read and write telegrams, with which data sets in
the slave are cyclically accessed. A distinction between a Class 1 and a Class 2 master is also
made for DPV1. The difference between acyclic Class 1 (C1) and Class 2 (C2) connections is
that the acyclic C1 connection is established during the DP StartUp phase of cyclic DP operation.
Once the slave has reached the WAIT-CFG state it is possible for acyclic DPV1-C1 read and
write telegrams to be sent from the master to the slave, whereas the C2 connection is established
separately, independently of the cyclic DP connection. This is usually carried out by a second
(C2) master so that, for instance, a manufacturer-specific project configuration and diagnostic tool
can access the slave's data.
When two masters are used, however, is must always be borne in mind that these share bus
access (a token is exchanged), so that time relationships are less favorable than in the case of a
single master system.