from machine import Pin
import utime
# Connect the push button to GPIO pin 15 (you may need to adjust this)
button = Pin(14, Pin.IN, Pin.PULL_DOWN)
def handle_button_press():
print("Button pressed!")
while True:
# Check the state of the button
if button.value() == 1:
handle_button_press()
utime.sleep(0.1)