2

Raspberry Pi Zero Wireless

I have a Pi Zero connected to a breadboard using the GPIO Extension Board and ribbon cable.

I have followed several of the basic blinking LED tutorials.

One jump cable is connected to GPIO22. When I run the basic program:

from gpiozero import LED, Button
from time import sleep

led = LED(22)
while True:
    led.on()
    sleep(1)
    led.off()
    sleep(1)

nothing happens.

If I touch the jump cable to 3V3 the LED lights. So, I figure the circuit is a happy one. If I touch the jump cable to RXDO the LED blinks, as expected.

Any ideas why this might be?

Update: So, it's quite interesting. The connection between the end of the ribbon and the Pi is not secure. There's a bit of wiggle-room. If I apply a small amount of pressure one way, vs the other, the power seems to travel a slightly different path.

1
  • 1
    upvote for clear description and for doing basic debugging – jsotola Sep 17 '18 at 15:20
4

Two possibilities.

  1. The gpiozero module exclusively uses the Broadcom GPIO numbering scheme. So 22 refers to Broadcom GPIO 22 which is connected to expansion header pin 15. Are you using the correct pin? See https://pinout.xyz/
  2. The ribbon cable could be inserted the wrong way around. To check we would need to see a photo of your Pi and connections.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.