from machine import Pin, ADC
from time import sleep
led = {
1: Pin(18, Pin.PULL_UP),
2: Pin(5, Pin.PULL_UP),
3: Pin(17, Pin.PULL_UP),
4: Pin(16, Pin.PULL_UP)
}
while True:
for i in led:
led[i].on()
sleep(0.5)
led[i].off()from machine import Pin, ADC
from time import sleep
led = {
1: Pin(18, Pin.PULL_UP),
2: Pin(5, Pin.PULL_UP),
3: Pin(17, Pin.PULL_UP),
4: Pin(16, Pin.PULL_UP)
}
while True:
for i in led:
led[i].on()
sleep(0.5)
led[i].off()