import machine
from time import sleep
potpin=28
mypot=machine.ADC(potpin)
while True:
potvalue=mypot.read_u16()
Voltage=potvalue*3.3/65535
print(f' potentiometre : {potvalue}, \t Tension : {Voltage:.2f}')
sleep(0.5)
import machine
from time import sleep
potpin=28
mypot=machine.ADC(potpin)
while True:
potvalue=mypot.read_u16()
Voltage=potvalue*3.3/65535
print(f' potentiometre : {potvalue}, \t Tension : {Voltage:.2f}')
sleep(0.5)