from machine import Pin, ADC
import time
adc=ADC(Pin(36))
#adc.atten(ADC.ATTN_0DB)
adc.width(ADC.WIDTH_10BIT)
adc.read()
while True:
value = adc.read()
voltage=value*0.000805
print(value)
print(voltage)
time.sleep(1)
# 12 bit ADC
# 2 power 12 is 4096
# 3.3V/4096=0.000805V