Skip to content

Controlling inputs (push buttons) and outputs (LEDs) with the 74HC595 IC

License

Notifications You must be signed in to change notification settings

gacarrillor/Electronics-Shift-Registers

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Shift Registers

Controlling (mixing) inputs (push buttons) and outputs (LEDs) with the 74HC595 IC.

Contents


Background

Work inspired by and adapted from Kevin Darrah's video on How to Control a Ton of Inputs using Shift Registers!. Note: In the video, Kevin shared and explained his great idea as well as his code. However, schematics/diagrams are missing, what makes the process a bit difficult to follow. In case you're wondering, this image describes the main idea:

Your image title

Main goal

My goal is to optimize my Soccer Penalty Kicks Game's control, which is currently working with 2 analog input reads based on resistors, controlling 12 push buttons, which, as mentioned by Kevin in his video, becomes problematic at the end of the day when having a number of inputs.

While Kevin's work handles multiple buttons (like a piano), my control has only one active button, so in the code, as soon as I identify a button press, I exit the button inspection and only light one LED.

IMG_7026

Cases

One shift register (74HC595): 4 inputs and 4 outputs

Schematics 1 Shift Register

See the source code.

Your image title

Two daisy-chained shift registers (74HC595): 8 inputs and 8 outputs

Schematics 2 Shift Registers

See the source code.

Your image title
Your image title
Your image title

Three daisy-chained shift registers (74HC595): 12 inputs and 11 outputs

This is what I actually needed for my game. One of the buttons triggers another action and is not connected to any LED, that's why the odd numbers :).

Schematics 3 Shift Registers

See the source code.

Parts

Amount Part
11 Red LED
11 330Ω Resistor
12 Push button
12 Diode 1N4001
1 10kΩ Resistor
3 Ceramic capacitor 1µF
1 Electrolytic capacitor 100µF
3 74HC595 Shift Register
1 Arduino Uno (Rev3) - ICSP
3_daisy_chained_shift_registers_12_inputs_11_outputs.mp4
Your image title

Results

This is how the control looks ike after implementing Kevin's approach.

penalty_kicks_goalkeeper_control.mp4

About

Controlling inputs (push buttons) and outputs (LEDs) with the 74HC595 IC

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages