from machine import Pin, ADC
from time import sleep
ADC.width(ADC.WIDTH_12BIT) # nicht für ESP8266
# ESP8266 hat nur einen analogen Pin A0
# analogWert = ADC(0)
analogWert = ADC(Pin(32)) # D32/GPIO32 - gelb - ntc1:OUT
#analogWert.atten(ADC.ATTN_11DB) #Full range: 3.3v
#analogWert.atten(ADC.ATTN_6DB) #Full range:
analogWert.atten(ADC.ATTN_0DB) #Full range:
print(ADC.ATTN_6DB)
while True:
print( analogWert.read())
sleep(0.1)