6/10/2009 2:46 PM | |
Joined: 10/7/2005 Last visit: 6/3/2023 Posts: 2966 Rating:
|
Hello ronin237 whiele there is nothing wrong with using counters you do of course have a "---|ONS|---" equivalent in S7 which you can use tofor example enable an "ADD Integer" calculation to achieve your counting. S7 calls these"Positive edge detection". Have a look at the Bit logic elements and you'll find a "---(P)---" symbol. Click on it and use "F1" to find out more about it. Btw, if you need to do your counting on anegative (falling) edge, you can use the "---(N)---" element. Lastley, there's two more instructions whichessentailly do thesame as the above two mentionedones and are called "POS" and "NEG" respectively. I'd stay away fromusing these too though asI find that they make code less readable than the "P" and "N" ones. Cheers Fritz |
Cheers |
|
Follow us on