0
\$\begingroup\$

I need to drive 80 RGB leds (so 240 individual leds), physically and conceptually aligned as an 8x8 matrix + an additional vertical line and an additional horizontal line.

I'd like to drive the matrix using 595 shift registers, so that I only need 3 microcontroller lines to drive all the leds, multiplexing the leds. The RGB leds I'm using are common anode. I'd like to have at least 3 levels of brightness for each color (full off, half on, full on).

I found many examples of driving an 8x8 RGB matrix with shift registers, but I'm trying to understand what's the best way (code-wise, mainly) to add the additional 16 RGB leds.

Option 1: a 9x9 matrix. If so, the additional column pin and additional row pin would come directly from the microcontroller and not from and additional shift register, since a shift register for only 2 pins would be wasted.

Option 2: a sub matrix in series with the first, that shares the anodes with the main matrix, but uses only an additional shift register to drive the additional cathodes. Other options?

thank you and sorry for my bad english.

schematic

\$\endgroup\$
  • \$\begingroup\$ You might want to read about charlieplexing \$\endgroup\$ – PlasmaHH Sep 18 '18 at 16:37
  • \$\begingroup\$ Afaik with 4 chained 595's you can drive 32 LEDs, so you need more than 3 pins for 64 or 80 LEDs, unless you use the 595's to drive (sub) 595's. \$\endgroup\$ – Michel Keijzers Sep 18 '18 at 16:37
3
\$\begingroup\$

Make the matrix from WS2812B instead, then just serially data chain the data from one to the next for all of them. Sparkfun carries thru hole 5mm parts in 2 different shapes. Then you don't need complex multiplexing either, just send out 240 bytes of data when you need an update using the FastLed.h library.

Or you can get strings of SMD WS2812Bs and lay out 9 strips of 9 LEDs, makes the wiring even simpler - connect the Gnd, Power all along one end, and a single data line from the end of one strip to the start of the next.

\$\endgroup\$
  • \$\begingroup\$ The WS2811 allows for more configurations of RGB LEDs, but for single LED RGB pixels it's hard to beat the WS2812B or the Adafruit Neo-Pixels \$\endgroup\$ – Jack Creasey Sep 18 '18 at 17:49
  • \$\begingroup\$ Yes, seperate driver chip vs combined driver + LEDs. WS2803 is another option for seperate driver for 18 LEDs (or 6 RGB LEDs), daisy chain a bunch of those. \$\endgroup\$ – CrossRoads Sep 18 '18 at 17:51
  • \$\begingroup\$ @JackCreasey Hard to beat? Have you seen the TI TLC5973. 50 mA, up to 21V outputs, one wire clock and data, 12 Mhz internal oscillator, 12 bit greyscale, 3 Mbs, 2.9 Khz repeat rate, and unlimited pixels. The LEDs in the WS2812B are a bit dismal, and I prefer to select the RGB for the application. I like the Luxeon C Color for color bright mixing apps, I also prefer 660 nm red and 450 nm blue much deeper colors. For billboard video the Cree CLMVB-FKA RGB in a 2 x 2 mm case is very compact. There is also a TLC59731 8 bit. And best of all good documentation. \$\endgroup\$ – Misunderstood Sep 19 '18 at 21:09
  • \$\begingroup\$ @Misunderstood Nice one, I must try some of those TI chips. \$\endgroup\$ – Jack Creasey Sep 19 '18 at 23:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.