I'm trying to make a feedback loop using a water level sensor. I want to display the analog input in milimeters (mm). So what I understand is the following:
Arduino ADC displays values from 0 to 1023 correspondig to 0-5V.
However, when I inmerse the sensor to the max point (30mm aprox) it only returns values up to 700 max which is around 3V, right?
I think that I should set up the max input value (700) to the max water level of 30mm and convert the signal into mm by using a y=ax+b linear equation?? Not really sure how to convert ADC digital output into milimeters.
Can you please post your code?
Can you please post a link to spec/data of your sensor?
What model Arduino are you using?
Can you please post a copy of your circuit, a picture of a hand drawn circuit in jpg, png?
Hand drawn and photographed is perfectly acceptable.
Please include ALL hardware, power supplies, component names and pin labels.