ExpertInterfaces & Displays
16-Output Pattern Panel with Cascaded Registers
Cascade two SN74HC595s to expand three Pico output wires into a 16-LED pattern panel.
Parts from the database
- SN74HC595N × 2Two eight-bit registers
- Raspberry-Pi-Pico × 1Sends output patterns
Other supplies
- breadboardCommon build supply
- sixteen LEDsCommon build supply
- sixteen 2.2 kΩ resistorsCommon build supply
- two 100 nF capacitorsCommon build supply
- jumper wiresCommon build supply
- MicroPython installedCommon build supply
Amazon links may be affiliate links. As an Amazon Associate, Electronics Hobby Hub earns from qualifying purchases.
Connections
- Power both HC595s from Pico 3V3/GND; on each chip pin 10 (/SRCLR) high, pin 13 (/OE) low, and 100 nF across pins 16/8.
- Pico GP19 MOSI to first pin 14 SER, GP18 SCK to both pin 11 SRCLK, GP17 to both pin 12 RCLK. First QH' pin 9 connects to second SER pin 14.
- Connect each QA–QH output (pins 15,1,2,3,4,5,6,7) through 2.2 kΩ and LED to ground. Keep currents within package limits.
Build steps
- Run the pattern code and first display all off, then all on.
- Observe one LED walking across all outputs.
- Record which half belongs to each chip; byte order may be reversed physically.
- Exchange bytes in `spi.write` if the two banks appear swapped.
Software and firmware setup
from machine import Pin, SPI
from time import sleep_ms
spi = SPI(0, baudrate=500000, polarity=0, phase=0, sck=Pin(18), mosi=Pin(19))
latch = Pin(17, Pin.OUT, value=0)
def show(pattern):
latch.value(0)
spi.write(bytes([(pattern >> 8) & 255, pattern & 255]))
latch.value(1); latch.value(0)
while True:
for bit in range(16):
show(1 << bit); sleep_ms(120)
show(0); sleep_ms(300)Test your build
One LED walks through all 16 outputs. If the banks are reversed, exchange the two bytes sent to the cascade.
Troubleshooting
- No LEDs: /OE must be low and /SRCLR high.
- Second chip inactive: check first QH' pin 9 to second SER pin 14.
- Pico resets/dim outputs: lower LED current or use a separate properly grounded load supply.
Safety and limitations
Do not drive strips, relays, or motors from the logic outputs; use external drivers for substantial loads.
Manufacturer and platform documentation
Community Notes for This Project
These are unverified visitor contributions, separate from the build guide and manufacturer specifications. Verify technical advice against the linked datasheets before relying on it.
Set up the comments service to load community notes.