mignev / shiftpi

ShiftPi is the easiest way to work with 74HC595 shift registers on your Raspberry Pi in Arduino style :)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

SparkFun Bar Graph

qbit opened this issue · comments

Has anyone tested this with the SparkFun bar graph?

I have it connected to what i believe are the proper pins ( following this [pdf] ) but I am getting no love.

Running the below script:

import RPi.GPIO as GPIO
import shiftpi.shiftpi as shiftpi

shiftpi.shiftRegisters(4)

shiftpi.startupMode(shiftpi.HIGH, True)

# turns shift register's pin 1 to HIGH
shiftpi.digitalWrite(1, shiftpi.HIGH)
shiftpi.delay(1000)

# turns shift register's pin 1 to LOW
shiftpi.digitalWrite(1, shiftpi.LOW)
shiftpi.delay(1000)

# turns all shift register pins to HIGH
shiftpi.digitalWrite(shiftpi.ALL, shiftpi.LOW)
shiftpi.delay(1000)

Turns out I was using the RasPI pinouts and not the RasPI 3! Works like a charm!