Well, I got the RGB matrix (#220324377200) and I have an Arduino Duemilanove and I have some 74hc595 chips. My problem is I have no idea what each of the pins on the matrix are for. I have looked at the data sheet. Perhaps a more experienced person could figure this out at a glance, but I’m sorta new to this. Is there a schematic somewhere that I have missed? I would guess that 8 on each side are used to address the cells, but what are the other 8 for?
Thanks for that. I’m looking at it now and trying to figure out how to use this with a Mega. This schematic is just for a “raw” mega168 board yeah? Not necessarily the arduino?
it should be near the same thing. you just have to be mindful of the inputs that the schematic is using, then make sure your using the right ones in your code.
What’s important for you is the right part of the schematic.
The shift register’s serial input (SER) is wired to the arduino’s MOSI line, clock (SRCLK) is wired to the arduino’s SCK line, the latch (RCLK) is wired to the arduino’s SS line, display enable (G) is wired to a digital output of the arduino board. In my code I used pin 9.
MOSI: duemlanove: 11 / MEGA: 51
SCK: duemilanove: 13 / MEGA: 52
SS : duemilanove: 10 / MEGA: 53
enable: duemilanove: 9 / MEGA: (use any digital output line + change the #define in the code)
The code compiles on 168/328/1280 chips without modifications for register names. As I don’t have a MEGA board I can’t test though.
Don’t forget to use a 10k pullup for the (G) line, this keeps the LEDs off if you upload new code. Also wire the (SRCLR) line to +5V. That line is active-low and clears the data, which you don’t want
Thanks for taking the time to post all of this. I actually purchased 4 of these so will be 16 X 16. As soon as I get the 8 x 8 controllable.
Also I’m trying to make an Adobe Air app to produce the animations to make it easy. I’ll try to make it as “dynamic” as possible to to maximize it’s usefulness. Unless somebody knows of something already out there?
Thanks for all the great info, especially the tutorial at instructables.com. I now realize that I should have posted a link to your blog and not directly to the schematic.
I got together 16 74hc595 shift registers to power my 4 8x8 matrix’s. But now I’m wondering how I can push enough current to power all 768 LEDs ((16x16)x3(RGB).
I found a post on instructables where they mentioned using this part instead:
whats the need to power them all at once? you could simulate that by just cycling through them faster than the eye can notice. that way you can stay under the large power requirements and not have to have extra hardware to turn them all on at once.
The effect depends on what’s called Persistence of Vision (POV). I came across it when I was looking into building an N x N LED cube. It’s used to create animation effects among other things.
Do a search for POV on youtube. You’ll find lots of projects that use this.
The HEF4794BP shift register can only SINK current, so you can’t just use 4 of them to drive the 8x8 RGB matrix. That’s why a source driver ( UDN2981A ) was used in the instructable to SOURCE current for the LEDs. Also multiplexing was used there, which works fine for just turning the LEDs on and off. The 74HC595 has tri-state outputs (0V, 5V, high resistance), whereas the HEF4794BP has open collector outputs (0V, high resistance).
2.)
If you plan to use PWM to get more than just 7 colors by turning the LEDs on/off “statically”, you should not use the UDN2981 chip! It is far too slow for that and you’ll get “ghost images” on the matrix. Been there, done that. That’s why the Rainbowduino uses a different source driver! It seems to be hard to get though, at least I couldn’t find a place that sells it.
The problem here is that the current requirements stay the same if you want the same brightness. When multiplexing, you really need to increase the drive current to the LEDs. For instance, if the LED is only on 25% of the time, you need to raise the peak current by a factor of 4 to achieve the same brightness. The average current will be the same regardless of whether the LED is directly driven, or multiplexed.
The only advantage to multiplexing, is to save output drivers, and to simplify the wiring. For large arrays, multiplexing is the only practical way.