Driving multiple LEDs

Hey guys,

I am currently designing a traffic light system. I need to drive around 25 LED’s. I was thinking of using a LED driver and connect the inputs of this driver to the GPIO of the beagle bone black board and the outputs to the LED’s. The driver that I thought of using is the MAX7219. Could anyone tell me whether this design would function or does anyone have a better approach to this problem?

Thanks in advance.

Depends what you mean by “function.”

The MAX7219 uses a SPI bus for control, so best to use SPI peripheral, rather than GPIO to interface to the MAX7219, or you could write a little driver to “bit-bang” a SPI bus with GPIO lines.
The MAX7219 is a +5V device, and BBB SPI/GPIO ports are 3.3 Volts, so you will need to do some voltage translation on the control interface lines.
The MAX7219 scans the LEDs, so make sure side-effects are not a problem. ie., brightness, break-up when your eyes move, etc.

You could also do it with a pair of PCA9555, which uses I2C bus, and can run directly from 3.3V as an option.

— Graham