Pollard
Member
I am currently working on a project that utilizes a pair of digital water flowmeters.
Each flowmeter continuously generates a single pulsed output, the frequency of which is directly proportional to the flow through the meter.
I plan to use the frequency input mode of the PLC (S7 313-c) and buffer the returned value over a number of sample cycles.
Ideally, I would like to have a rolling 20 cycles stored. I will then sum and average the buffer to give a value to be used in further calculations.
When the buffer is full, the oldest sample can be "lost" as a new sample enters.
My question is this (and please excuse my ignorance if the answer is obvious!): what would be the best method of generating the buffers?
Each flowmeter continuously generates a single pulsed output, the frequency of which is directly proportional to the flow through the meter.
I plan to use the frequency input mode of the PLC (S7 313-c) and buffer the returned value over a number of sample cycles.
Ideally, I would like to have a rolling 20 cycles stored. I will then sum and average the buffer to give a value to be used in further calculations.
When the buffer is full, the oldest sample can be "lost" as a new sample enters.
My question is this (and please excuse my ignorance if the answer is obvious!): what would be the best method of generating the buffers?