#define PIN_ANALOG_IN 34 //the pin of the Potentiometer
void setup() {
Serial.begin(9600);
}
void loop() {
int adcVal = analogRead(PIN_ANALOG_IN);
double voltage = adcVal / 4095.0 * 3.3;
Serial.printf("ADC Val: %d, \t Voltage: %.2fV\n", adcVal, voltage);
delay(200);
}