Example 1: Setting / changing the current setting (Action = 1)
1.
Set M0=ON, the counter starts counting.
2.
In DHCCNT instruction, set the value in Action to 1 and the value in Value to 10000. When the Update flag M1 is
ON, the value in CurCnt is updated to 10000.
3.
After execution, the Update flag M1 clears to OFF automatically.
Counter value
10000
Action
Value
Update flag
0
1
10000
Cha p ter 6 App l ied Ins truc tio ns
6_
6-491