import time
from machine import Pin
LED = Pin(32, Pin.OUT)
PB = Pin(33,Pin.IN)
while True:
logic_state = PB.value()
if logic_state == True:
LED.value(1)
else:
LED.value(0)import time
from machine import Pin
LED = Pin(32, Pin.OUT)
PB = Pin(33,Pin.IN)
while True:
logic_state = PB.value()
if logic_state == True:
LED.value(1)
else:
LED.value(0)