By any chance are there any examples of using the derivative function?
I am trying to measure the gallons per min of a water pump we have. In the pump there is a linear (0.5v to 4.5v) sensor. So I am trying to use the derivative function to calculate the in/sec at which the sensor is traveling to calculate the GPM. In addition to just reading the in/sec I need to know in which direction the sensor is moving, because the amount of water is different on the return stroke due to the rod diameter.
I am currently using the derivative, but the issue I am facing is that when I am reading the sensor and applying the derivative the value is very finicky (jumps around alot) and if I apply any sort of filter to the sensor input the calculated flow lags the actual flow too much for our application.
Customer support service by UserEcho