Trying to read values from adc
Posted: Tue Oct 25, 2022 4:40 pm
I have made a sketch that reads from the adc and displays them:
void setup() {
Serial.begin(115200);
pinMode(A0, INPUT);
}
void loop() {
Serial.println(analogRead(A0));
}
Problem is that I am not seeing 0 on the serial monitor, just random values starting at 230 and slowly decreasing. I should be seeing 0 imo because I have a pull down resistor on the Reset pin which is the ADC pin according to the datasheet. Please help, any help is appreciated.
Thanks
void setup() {
Serial.begin(115200);
pinMode(A0, INPUT);
}
void loop() {
Serial.println(analogRead(A0));
}
Problem is that I am not seeing 0 on the serial monitor, just random values starting at 230 and slowly decreasing. I should be seeing 0 imo because I have a pull down resistor on the Reset pin which is the ADC pin according to the datasheet. Please help, any help is appreciated.
Thanks