You can configure the following special functions in a PROFIBUS DP master system if the devices are designed accordingly:
b SYNC/FREEZE groups for synchronous output of output signals and synchronous reading in of input signals
b Direct data exchange between stations on the PROFIBUS
b Equidistant bus cycles and isochronous mode for deterministic response times Configuring SYNC/FREEZE groups
The SYNC control command requests the DP slaves combined into a group to simul- taneously (synchronously) output the output states. The FREEZE control command requests the DP slaves combined into a group to simultaneously (synchronously) freeze the current input signal states to allow them to then be cyclically fetched by the DP master. The UNSYNC and UNFREEZE control commands respectively cancel the effects of SYNC and FREEZE.
You can generate up to eight SYNC/FREEZE groups per DP master system which are to execute either the SYNC command, the FREEZE command, or both. Each DP slave can only be assigned to one group.
Using the system block DPSYC_FR in the user program, you can trigger the output of a command to a group (see Chapter 16.5 “System blocks for distributed I/O” on page 665). The DP master then sends the corresponding command simultaneously to all DP slaves in the specified group.
To assign a DP slave to a SYNC/FREEZE group, open its interface properties and as- sign the DP slave to a group under SYNC/FREEZE. You can find the list with the groups in the interface properties of the DP master under SYNC/FREEZE and can set the properties (SYNC, FREEZE, or both) there for each group.
Configuring direct data exchange
In a DP master system, the DP master only controls the slaves assigned to it. With correspondingly designed stations, only a different station (master or intelligent slave, referred to as receiver or subscriber) on the PROFIBUS subnet can “listen in”
to find out what input data a DP slave (the sender or publisher) is sending to “its”
master. This direct data exchange is also referred to as direct communication.
You can also use direct data exchange between two DP master systems on the same PROFIBUS subnet. For example, the master in master system 1 can “listen in” in this manner to the data of a slave in master system 2.
A prerequisite for configuration of direct data exchange is configuration of the sender station with input modules. First define the partner stations. Select a part- ner in the Network view – with two I-slaves as partners, this must be the sender – and open the I/O communication tab in the configuration table in the bottom part of the working window. The DP slaves which have already been configured are listed here. The Drop the device here or select cell is present in the Partner 2 column. Click in this cell and select the partner station for direct data exchange from the drop- down list or drag the partner station from the graphic into this cell using the mouse. The partner station is entered in a new line in the configuration table with the operating mode Direct data exchange.
Select the line with the partner station and enter the desired transfer areas in the inspector window under Direct data exchange in the Transfer area table. Select the desired module in the Partner module column from the drop-down list and define the input address in the receiver station, the length of the transfer area, and the data consistency.
Configuring equidistant bus cycles (constant bus cycle time) and isochronous mode
Constant bus cycle time
In the normal case, of the DP master controls the DP slaves assigned to it cyclically and without pauses. The time intervals may vary as a result of S7 communication, for example if the programming device carries out control functions over the PROFIBUS subnet. By using constant bus cycle times it is possible to achieve, for example, that outputs are always controlled via DP slaves at equal intervals. The DP master then always starts the bus cycles at equal intervals.
The use of constant bus cycle times is possible with the bus profiles “DP” and
“User-defined”; SYNC/FREEZE groups must not be configured.
Isochronous mode
Reference is made to isochronous mode if a program is executed synchronous to the PROFIBUS DP cycle. In association with constant bus cycle times it is thus possi- ble to achieve reproducible, response times of equal duration to the process I/O, which include the distributed recording of signals, signal transfer over PROFIBUS,
and program execution including process image updating. The user program exe- cuted in isochronous mode is present in one of the organization blocks OB 61 to OB 64. The system functions SYNC_PI and SYNC_PO are available for isochronous updating of the process image.
The application of constant bus cycles is a prerequisite for isochronous mode.
Isochronous mode is only possible with a DP master integrated in the CPU as the on- ly active station on the PROFIBUS.
Fig. 16.17 shows the times involved in the isochronous mode. Ti is the time re- quired for reading in the process values. It contains the execution time in the input modules or electronic modules and, in the case of modular DP slaves, the transfer time on the backplane bus. At the end of Ti, the input information for transfer using the global control command (GC) is available. The constant bus cycle time then commences. This is the time between two global control commands and encom- passes the transfer to the subnet as well as the execution of the isochronous inter- rupt OB. Between completion of the execution of this OB to the next global control command there must be time for execution of the main program.
To is the time required to output the process values. It begins with the global con- trol command and comprises the transfer time on the subnet as well as the process- ing time in the output modules or electronic modules. In the case of modular DP slaves, the transfer time on the backplane bus is also added.
Fig. 16.17 Response time with constant bus cycle time and isochronous mode
Ti Equidistant bus cycle To
Response time in isochronous mode Isochronous mode
The minimum response time in the case of isochronous mode is the total of Ti, the bus cycle, and To. The maximum response time (Ti + To + 2 bus cycle) occurs if a change in the input signal takes place shortly after the global control command.
Correspondingly designed DP slaves allow a reduction in the response time thanks to “overlapping isochronous mode”. This involves overlapped updating of the input and output signals (overlapping of Ti and To). In this case, the DP slave must not ob- tain the Ti/To values from the subnet. If isochronous modules have both inputs and outputs, overlapping of Ti and To is not possible.
Configuration of isochronous mode
A prerequisite for configuration of isochronous mode is the constant bus cycle time and the corresponding functionality of the participating DP components. Following configuration of the DP master system with appropriate modules (CPU with integral DP interface as well as ET 200S and/or ET 200M DP interface modules with input/out- put modules with isochronous mode capability), you assign the DP master system (e.g. 1) and one or several process image partitions to one of the organization blocks OB 61 to OB 64 in the CPU properties in the Isochronous mode interrupts tab.
To switch on the constant bus cycle time and isochronous mode, activate the Enable constant bus cycle time checkbox in the properties of the PROFIBUS subnet under Constant bus cycle time. Activate isochronous mode for the participating DP slaves in the Detailed overview section and, if you “open” a line with a DP slave, the isochro- nous mode of the individual I/O modules in the DP slave. In the Ti/To values column you can select the mode from a drop-down list for calculation of the Ti/To values:
b From subnet: The currently configured DP slave obtains the Ti/To values from the subnet and thus has the same values as the other DP slaves which also obtain their values from the subnet.
b Automatic minimum: If you manually change the Ti/To values of another DP slave when in this setting, any adaptations which may be necessary on the currently configured DP slave are carried out automatically.
b Manual: With this setting, you manually enter the Ti/To values for the currently configured DP slave.
You can also make these settings in the interface properties of the DP slave under Isochronous mode (Fig. 16.18).
Each module or submodule involved in isochronous mode must be addressed in a process image partition TPAx. You set the process image partition for the module in the Device view in the module properties under I/O addresses.
Chapter 5.6.8 “Synchronous cycle interrupts, organization blocks OB 61 to OB 64”
on page 209 describes how you configure the organization blocks for isochronous mode.