I'm trying to string together a few components I have into something. The first step is to control a 64-LED matrix I have from a kit. It have 16 pins, 8 for the columns and 8 for the rows. I've attached a photo of the back of the LED matrix showing the two rows of 8 pins each. I've also attached a Fritzing image that shows my wiring configuration. In the Fritzing image I have the two rows of 8 pins each going out into space as there is no similar LED matrix in the library (there is only a 10-pin version).
I wired it following the ShiftOut tutorial (http://arduino.cc/en/tutorial/ShiftOut), except that in that tutorial the shift register is connected to 8 LEDs via resistors. In my case, it's an LED matrix, so each register matches up to a column or row.
So a few questions:
-
Just curious, why does the shift register link to power and ground twice?
-
In the example, each LED is connected via a 220R resistor. That's obviously impossible in a matrix, unless the matrix itself has the resistors. I have no documentation on the matrix, so I don't know. Is it common for LED matrixes to have resistors inside? I think I saw an article somewhere that showed a
similar 16-pin matrix hooked up directly to an Arduino, but I couldn't find it now. -
If I need to add resistors, would I add to each column and row? I did find the following instructable (http://www.instructables.com/id/Multiplexing-with-Arduino-and-the-74HC595/step8/Current-Limiting-Resistors/) which shows adding resistors to just the cathodes. Considering I have no specs on the LEDs, is there a way to figure out the needed resistance using a multimeter or some such tool?
-
If you look at my diagram I'm actually connecting two rows and two columns to each register. That's because it's an 8x8 matrix and later on I'm going to be connecting it to a 4x4 keypad and want one button press on the keypad to light up the LEDs that match up to the location of the button on the keypad, which would be 4 LEDs. I'm not sure if this will work, but I am guessing I can send a signal to the right registers and light up 4 LEDs instead of 1, as long as I get the resistance calculated correctly - which is a bit more complicated with two LEDs, so any help here would be appreciated.
-
Once I get the hardware configured correctly, how do I program the Arduino to properly address the matrix? Is there a library for using a shift register to control an LED matrix such as this, or do I just use ShiftOut or the SPI libraries to address the hardware directly? Does anyone know of write-ups of similar setups online?
Thank you.

