from machine import pin
from time import sleep
# This is the built-in green LED on the Pico.
BUILT_IN_LED_PIN = 16
# The line below indicates we are configuring this as an output (not input)
led = machine.Pin(BUILT_IN_LED_PIN, machine.Pin.OUT)
# Main loop: Repeat the forever...
while True:
led.high() # turn on the LED
sleep(0.5) # leave it on for 1/2 second
led.low() # Turn off the LED
sleep(0.5) # leave it off for 1/2 second