Raspberry Pi practice problem · LEDs & PWM
Upside-down LED
EasyBudget $2Python · gpiozero
A GPIO can sink current as well as source it. Wire the LED the other way up:
3.3 V → resistor → LED → GPIO17
Now the LED lights when GPIO17 is low. Make it blink 1 s on, 1 s off, starting on at 0 s.
Tip: LED(17, active_high=False) tells gpiozero that "on" means low.