Hi, I am currently trying to design a project which uses 96 individual LED bulbs (2V forward voltage, 20 mA). I want to be able to address each individual bulb so I am planning to use 10 74HC595 shift registers daisy chained together to achieve the amount of I/O pins needed. I plan to have all 96 in parallel with each other as well as each LED being in series to a 150 ohm resistor. Can the Arduino power this set up and will this even work the way I am intending it to?
Use twelve TPIC 6B595 chips.
They are functionally identical with 74H595 chips. However, they use MOSFETs in the output stage, so your chip will not heat up when all LEDs are ON. And they have 2 pins more.
Daisychaining (connecting chips) is no problem. The Arduino ShiftOut function works well. To be honest, I have never tried it with 12 chips, but had no problem with up to 6 chips.
96 times 20mA is 2 Amperes!
You will need an extra power supply. When you power your Arduino via USB 2.0 you will have a maximum of 500mA. USB 3.0 can give you up to 2 Amperes, but only if the target asks for it. The Arduino will not do this. When you power the Arduino externally, the integrated power converter will not give you 2 Amperes.
It may be worth considering whether 20mA per LED is really neccesary. LEDs can vary tremendously from type to type (and quality). Dependant on the components and the environment the project will be used in, you may be able to reduce individual LED currents to as little as a few milliamps. Experiment with one LED, and try several current limit resistor values up to as much as 2k7 ohms (just over 1mA with the 2v LED drop and a 5v supply). You may be surprised how bright a seemingly small current can provide, as effective brightness per mA is non-linear with our human eyes. The quoted current is often a recommened MAXIMUM not a typical value. Also bear in mind that 96 light sources is a lot. Are you planning on including PWM modulation to allow control over the overall brightness too? That should be interesting to achieve!
The pin named “G” on the chip allows for easy PWM. It will switch on and off the LEDs. Just connect your PWM signal to this pin. If you do not use PWM, connect this pin to ground.
I was not planning on using PWM as I don’t really need brightness control, I am planning on setting up an 8x12 grid of the LEDs and then programming it to play simple games like Tetris and the Snake game with an NES usb controller I have. I have not received my LEDs yet, they should arrive sometime this week so I will test if I can use a lower current to power them. Where would I buy some TPIC6B595 chips? Are the ones on eBay from china fine to buy or do I need to find some better quality ones?