8 x 8 matrix

Just starting to play about with led matrix 8 x 8 just cant get my head round how the matrix work's ...if I have this rite I can use 2 shift registers one for the columns with resistors and one for the row's with transistor's this seemed to work until I started to think about it ...... If I want to display a letter L i would power row 8 and columns 1 to 8 for the base of the L but I could not display the vertical line as giving power to any other row would light up the full row ... What am I missing ??

Thanks Dave

The design you are describing needs persistence of vision to work. If you wanted to light up the letter L all at the same time you would need 8 shift registers each 1 controlling its own row. The persistence of vision method is going to light up the correct LEDs in each row 1 at a time in rapid succession so that it appears that to humans that the letter L is displayed.

It'd probably be easier to use 3-to-8 line decoders(and inverters for one of them)

I like the decoder idea I've never given it serious thought though. I think using a demuxer to ground would probably be better than using a 2nd shift register also... avoid the transistor switches.

What's happening here http://www.arduino.cc/playground/Main/DirectDriveLEDMatrix

maddave: What's happening here http://www.arduino.cc/playground/Main/DirectDriveLEDMatrix

They are driving the LED's directly from the pins(you can configure the analog in pins as digital I/O). It may be easier to simply do this, but you won't really have any more pins left to use. I did this once and tried to use a for loop, but i forgot to make them turn off! Arduino does NOT like turning on 30 LED's at one time. I unplugged it before the smoke got out, though.

but how can it display… lets say a letter T on a grid

You cannot address each led on an 8x8 array directly from the arduino. You DO need shift registers. This is the exact reason why the 74HC595 is so popular, because it is a tri-state IC. You can set the output to HIGH, LOW, or HIGH Impedence (which means the entire circuit can't see that pin, like its not there). Just look around a bit, i'm sure you will find your answer.

And answering your question as to how it is wired, it is charlieplexed so thats how they do it, and because of that, you cannot address each led by itself, it requires current to go in certain directions to light up certain leds.

Not so much charlieplexed as multiplexed.

@maddave, your matrix can be setup like this: 8 outputs (with a current limit resistor), driving 8 anodes, so you have 64 LEDs. The output can be a shift register, or an arduino pin. Now take 1 LED from each output, and connect all their cathodes together. Connect this output to the output of an ULN2803. The input to the ULN2803 can be another shift register, or an arduino pin. Now say you wanted to make a T, consisting of the top row being on and one column being on. You write a loop that: drives the row data, and turns on column 1 only; in this case just Anode 1 drives the row data, and turns on column 2 only; in this case just Anode 1 drives the row data, and turns on column 3 only; in this case just Anode 1 drives the row data, and turns on column 4 only; in this case just Anode 1 drives the row data, and turns on column 5 only; in this case all 8 Anodes drives the row data, and turns on column 6 only; in this case just Anode 1 drives the row data, and turns on column 7 only; in this case just Anode 1 drives the row data, and turns on column 8 only; in this case just Anode 1

As the code goes thru this loop repeatedly, your eyes see it as 1 stable image, of a T. If the loop updates more often then 24 'frames' per second (TV speed), you don't even see if flicker. So every 41.6mS, (1/24th of a second) you go thru the loop. The rest of the time you can be updating the data you will send out to change the image, read some switches, etc.

You can do this without shift registers, it just ties up 16 of 20 I/IO lines. If you connect 2 shift registers to the SPI lines, you can control it with fewer pins: SCK, MOSI, (MISO tied up by default) and 2 chip selects. Make the collector shift register a TPIC6B595 to sink current from the common cathodes and you do not need the ULN2803.

This is much easier to see as a schematic picture.

Thanks for that Mr Roads I think I understand