I just started learning how to use the raspberry pi. One of the first issues I encountered with the raspberry pi was that the most common library (the one that all tutorials use) RPi.GPIO does not work with the raspberry pi 5 due to hardware changes. This means I have to use a library that supports the new hardware like the gpiod or GPIOZERO. I was told to use GPIOZERO as it is more begginer friendly and has more features like pwm and built in pull up resistors.
Upon trying to turn on a led with the GPIOZERO library, I encountered an issue where my code wasn’t making the gpio pin output any voltage (I tested this with a multimeter). Here is my python code:
from gpiozero import LED
led = LED(2)
led.on()
I wonder if it is an issue with the new chip system on the raspberry pi 5. Does anyone know how I can fix this?
I tried switching around the gpio pin from 3 to 2, nothing changed, I’ve tried researching if it might be something to do with the new chip system, but I found that this exact code and wiring worked for other Pi 5 users.
Matthew Moller is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.