Pwm won't work cause I see now the Hz has to be a constant. Where can I find Tprop out?
What I want to do, is simulate a hopper unloading grain, using a pid loop to control the flow rate of the grain, and as the pid loop increases its output, I want that pid output to increase the pulses per second I'm sending to my flow rate (pid.pv),. (Just for simulation)
Basically i need to programmatically control the pulses per second I'm sending to my flowrate calculation, in a linear fashion. I have been doing like first reply, but it is totally non-linear.
On a side note, is there an instruction that can calculate flow rate, not from a pulse input, but from a number that is dropping rapidly, like 100 units per second.