When you're using S7 or SIMATIC counters in your PLC program, one of the things that might be limiting in some projects is that these counters can only count up to 999 and not beyond that. That means, for instance, when you're using an S7 counter to count the number of the products passing on a conveyor belt, when the counter counts up to 999, it stops there and the counters accumulated value will not increment any further when it receives new input signals in the software. Now the question is what if you needed the counter to count a larger amount? Meaning more than 999. Well, in that scenario just like what you learned for extending the time for S7 timers, you can implement some programming tricks and techniques here as well to extend the amount that an S7 counter is able to count. So let's see how you can do that.
In the previous lesson you learned how you can build a customized counter by combining two counters to extend the amount that an S7 counter is able to count. As I previously explained, the basic idea here is since each of these counters can only count up to 999, I will combine them in a way that ...
In the first two parts of this series you learned how you can combine two S7 counters and build a customized counter that is able to count amounts higher than 999. As you saw in the previous lesson I tested the software and everything seemed to work fine but believe it or not, the program has sti...
It's clear for me now that the limitation that I have here is because the data type for the instructions are defined as integer so what do you think of changing the data type for the multiply instruction to double integer or long integer?
2 Comments