# A fix for: https://wokwi.com/projects/408770882420917249
# This Wokwi project: https://wokwi.com/projects/408799400399545345

from machine import Pin
import time

time.sleep(0.1) # Wait for USB to become ready

led = Pin(15, Pin.OUT)                   
button = Pin(13, Pin.IN, Pin.PULL_UP) # Create button object from Pin13 , Set GP13 to input

print("Testing the Serial Monitor")

print("Testing the Led")
led.value(1)
time.sleep(2)
led.value(0)

print("Press the button")

while True:
    if not button.value():
        led.value(1)      # Set led turn on
    else:
        led.value(0)      # Set led turn off
    time.sleep(0.01)      # For Wokwi, speeds up simulation
BOOTSELLED1239USBRaspberryPiPico©2020RP2-8020/21P64M15.00TTT