Has anyone figured out an easy/slick way to convert a digital input into a frequency/Rate?
I've got this prox switch out on the plant floor that monitors whenever a part goes by. A part goes by at regular intervals, except that once in a while a part may not be there (removed from product stream for QA reasons). Ok, so I want to know (on average, say in the last 2 minutes) what is the rate in parts per hour.
I guess I kind of want an Derivative Object that will accept a digital input (logical) instead of numeric.
I am currently using a POT as the input to a Derivative Object (updating in 2 minutes, and a time unit of 1 hour), and Incrementing the Pot with the Digital Input from the PLC. However this only works until the POT max's out, then I automaticly reset the pot to zero, and start incrementing again.
I just figure it should be "cleaner" than this solution. Any ideas?
Rich Anderson
Automation Controls Engineer
Anamax Group