The way your code is written it will only print 1's !?
Try:
Try:
Code:
import machineimport timebutton = machine.Pin(14, machine.Pin.IN, machine.Pin.PULL_DOWN)while True: print(button.value()) time.sleep(0.5)Statistics: Posted by rpiMike — Sun Dec 29, 2024 3:49 pm