Go Down

Topic: Base Analog Port Reading (Read 560 times) previous topic - next topic

rastilin

Apologies if this has been posted before, I didn't find it with the search function.

During the implementation of our project, I put enough power through a wrong wire to shut down the USB port the Arduino was attached to. Since then we've been getting some highly variable readings off the analog ports, even though the Arduino responds to Xbee commands and is otherwise perfectly functional.

What's the base reading off A0 when nothing's attached to it if you do an analogRead command to it? It should be 0 ish right? So our readings of 300~400 are wrong... or perhaps we're not grounding something properly and that's what's throwing it off.

retrolefty

Quote
What's the base reading off A0 when nothing's attached to it if you do an analogRead command to it? It should be 0 ish right? So our readings of 300~400 are wrong... or perhaps we're not grounding something properly and that's what's throwing it off.


So called 'base' readings of analog input pins with nothing wired to the pins are invalid as that represents a 'floating input pin condition'. If you want to test that a analog input pin is functioning properly just wire the pin to ground and you should get a steady 0 counts value, wire it to the +5vdc pin and you should get a steady 1023 count value.

Lefty


Go Up