reset analog pin

Hello I read pin A0 and A1 and all the time there is a voltage even when nothing is connected. How can I reset them
thank u

Tie them to ground.

you can tell me how do it

With a jumper wire.

Or just stop reading. What you describe is perfectly normal.

Better to use a resistor, e.g. 1kOhm. One per pin.

Connect resistor 1 k parallel to gnd

This is the implementation of Post#1, 3.

This is the implementation of Post#5.



Exactly as GolamMostafa sent (second one).

Connecting a resistor between an analog pin an GND may affect the value read from the pin when a legitimate voltage is connected to the pin.

If the pin is not being used then the simple solution is not to read it. Only one analog pin can be connected to the ADC at any one time.


Yes, there is a question why he wants to read if nothing is connected.

Just for an explanation for wire or resistor:
Normally input doesn't matter if there is a resistor or wire if nothing is connected to it. It is just because of case if the pin would be set to output high like by accident or so. Jumper is the short circuit and it will cause damage of port, but with 1k resistor and the voltage 5V, the current via resistor will be 5mA and port allows up to 20mA (we does't know but ATmega?).