from machine import Pin
from utime import sleep


led=Pin(13,Pin.OUT)
butt=Pin(14,Pin.IN)

while True:
    if butt.value()==1:
        led.value(1)
    elif butt.value()==0:
        led.value(0)
Loading
pi-pico-w