GPIO Zero Button + LED from gpiozero import Button, LED button = Button(21) led = LED(25) while True: button.wait_for_press() led.on() button.wait_for_release() led.off()
GPIO Zero Button + LED from gpiozero import Button, LED button = Button(21) led = LED(25) while True: led.on() button.wait_for_press() led.off() button.wait_for_release()
GPIO Zero Button + LED from gpiozero import Button, LED button = Button(21) led = LED(25) while True: led.blink() button.wait_for_press() led.off() button.wait_for_release()
Traffic Lights Sequence ● Can you make a full traffic lights sequence? ● Use the button for a pedestrian crossing ● Use buzzer.beep() to indicate safe crossing