84
Counter function
WAGO-SPEEDWAY 767
767-5801/000-800 8DIO 24V DC 0.5A IF (8xM8)
Manual
Version 1.1.0
9.2.3
Example of Controlling Two Counters via the Process Data
Prerequisite:
For the module in DTM, you have set the
operating mode "DIO 2 counters." For control of the counter via the
output data, the parameter "Simulation" must also be deactivated for the counter.
For the following example, heed the descriptions of the control byte
(section "Control Byte").
To control the counter via the process data (output data), the control mode
(set bit 7) must be activated. In this mode, the counter is stopped. Only with a set
control mode can you set the other bits individually or simultaneously. To check
the configuration, the control mode bit of the status byte is then read via the
process data (input data). When setting the start or limit value, the value must
remain in the output process image after resetting the control mode (at least one
cycle).
The control mode bit must be reset and then set again before configuring the
second counter.
Table 51: Example of controlling two counters via control byte
Binary
Hexadecimal
Description
10010010
92
Counter 1:
Set limit value and gate function for
counter release.
0xxxxxxx
0
Both counters are released
10000110
86
Counter 1:
Set count direction "down" and gate
function for counter release.
Both counters are released
0xxxxxxx
0
Both counters are released
11000011
C3
Counter 2:
Set both start value and gate function for
counter release.
0xxxxxxx
0
Both counters are released
Pos: 40 /D okumentation allgemei n/Glieder ungselemente/---Seitenwechsel--- @ 3\mod_1221108045078_0.docx @ 21810 @ @ 1