import machine
import time
led = machine.Pin(2, machine.Pin.OUT)
while True:
led.value(1) # Turn the LED on
time.sleep(0.5) # Wait for 0.5 seconds
led.value(0) # Turn the LED off
time.sleep(0.5) # Wait for 0.5 seconds
import machine
import time
led = machine.Pin(2, machine.Pin.OUT)
while True:
led.value(1) # Turn the LED on
time.sleep(0.5) # Wait for 0.5 seconds
led.value(0) # Turn the LED off
time.sleep(0.5) # Wait for 0.5 seconds