I need to program a 8 digit totalizer.I have a pulsed input per 1K gallons.The mech. local totalizer needs to match a remote HMI display (wonderware).When the value reaches 65535 (Modicon PLC) This is where I'm Having Trouble.
Do not use Schneider but why not use a BCD channel and a differentiated increment command? When the channel reaches 9999, increment another channel by 1 and reset the counting channel to 0 using a move command. Very easy really, provided the PLC has the right functions.
The modicon could well be one of those PLCs that only support integers. You are incrementing a data register for each unit passed. If you check the manual you may well find that the maximum value for an integer is 65535If this is the case look to see if there is a DREG DOUBLE or REAL -(yes 32 bit as xyzz says) if not then consider making an overflow flag at 9999 and counting up from there in a second register.
Use your programming PC (not the wonder ware display) to see whats in the register. If it keeps going then your wonderware may be integer.
Thanks for the replys. what I did was increment a up counter so that when it reached 65535 it incremented a second counter by one.Then had the HMI multiply the number in the second counter by 65535 and add the first counter value to it.Then set it up so when the value in the second counter value was 1525 and first counter was 59124 this would equal 99999999.when the first counter hit 59125 this would reset all counters to zero.Matching the remote mechanical totalizer.