I don't see anything obviously wrong. Perhaps a delay(1) just before the analogRead() would help get stable readings.
What is the value of the fixed resistor? It should probably be 100k or lower.
I don't see anything obviously wrong. Perhaps a delay(1) just before the analogRead() would help get stable readings.
What is the value of the fixed resistor? It should probably be 100k or lower.