Maker Pro
Maker Pro

Driving an LED Matrix HELP Needed

I'm trying to make an LED Matrix 32x20 and was going to break it up into smaller matrices (32x10s). I'm using shift registers for the 32 columns, but am having a difficult time with the driving mechanism part for the rows. I already have 4017 decade counters and am not sure if I could cascade a couple of them or if getting some other driving mechanism would be better.

Thanks
 

(*steve*)

¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd
Moderator
A 4017 has 10 outputs, just the number you require. Why do you need more?

Each one drives a transistor or mosfet which drives that row high (or low) while the 64 column outputs (you said you were breaking it in 2) drive the columns.

Alternatively you have 2 sets of 32 column drivers and 2 sets of row drivers. But in this case each row driver is driving 10 rows.

You only need to drive 20 rows if you are *not* breaking the matrix into two.
 
I meant to include that this is for my arduino and I wanted to use as few number of pins as possible. The full LED Matrix would be 20 high and 32 long. The 8 bit registers would work easily with the 32 columns, but the rows are a problem. I'm not sure if I can cascade the 4017's because someone suggested to split that up into 10 and 10.
The whole point is to save space because I have another project to interact with the matrix and requires the arduino as well. My question pertains to how to drive the rows, if by decade counters then how do I use multiple of them, if not then what should I use for 20 rows?

Sorry for any confusion
 

(*steve*)

¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd
Moderator
I suggested 8 and 8 and 4 because it fits nicely into bytes. However, you can do 10 and 10.

That way you effectively do a 64 x 10 matrix but construct 2 32 x 10 matricies (the x10 are common) and place them one above the other so they are electrically 64x10, but look like 32x20.

So you have 10 outputs from a 4017 driving the 10 rows and your 63 columns from the shift registers (3 pins on the arduino) driving all the columns.

So you only need a single 4017.

However you should consider how you're going to store the data because 10 bits are bigger than a byte.
 
Since I'm new, I'm unaware how the number of bits would effect it and haven't came into contact with websites/projects which talked about that problem. Any brief info would be nice.
And how would the 8, 8, and 4 work like you were talking about? The only reason I went to 10s was because someone suggested that because of the 4017.
 

(*steve*)

¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd
Moderator
one byte contains 8 bits. So a single byte can tell you exactly what the 8 LEDs in a column should be (on or off for each one) 64 bytes is very simply 64 x 8 bits and can hold all the data for two 32 x 8 matricies of bits.

The remaining 4 bits is exactly half a byte. So for the remaining 32 x 4 you can store 16 bytes with the information packed into them, or another 32 bytes if you use half of each byte. The data is fairly easily accessed.

If you have 32 x 10, then I guess you can store the bits along the 32 columns as 4 bytes, and then multiply this by the 10 rows, resulting in 40 bytes per matrix.

Actually the latter isn't that hard, especially since the number of columns is evenly dividable by 8.

In your case if you do 64 x 10 is is 8 bytes per row (1 row of each sub-matrix) by 10 rows.

The 4017 can be used for any number of rows up to 10. Yes you can cascade them, but it's not trivial and you have no reason to want to.
 
Alright, thanks for your imput, I really appreciate it.
And just to clarify before I start soldering everything, I won't need to do anything special with my hook-ups or the driver with that quantity of columns? Just the simple standard layout with typical registers and 4017? (Kind of vague, but nothing imperative to do in my situation basically is what I'm trying get at.)
And lastly, do you have any sites sites/videos which would help me with programming that I would specifically need for this arduino based project? Because programming the Matrix to its awkward 64x10 dimensions and placing software in which will make it a non computer reliant audio analyzer is the next mile stone.
 

(*steve*)

¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd
Moderator
I wouldn't go straight to wiring things up.

First make sure (on a breadboard) that you know how to make the 74HC595's do the right thing.

Then the same for the 4017.

Then draw up the circuit diagram and check that it is correct before wiring.

The last thing you want to do is wire up the array and not find out you've made a mistake until all 640 LEDs are soldered in place.

I recently made a project with only 200 LEDs and you can bet that I tested things before starting assembly, and several times during the process. Your task is three times larger than mine.
 

(*steve*)

¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd
Moderator
I would recommend that you connect all the anodes (columns) to the 74hc595 outputs via resistors and the cathodes (rows) to the drains of N channel mosfets with the sources grounded and the gates connected to the 4017 outputs (via 100 ohm resistors).

Is that what you plan to do?
 
For reference (hey, its me!), he is referencing most of his circuitry off of my project here, which I admittedly referenced 90% of it from another user and don't fully understand all the code behind it.

I'm willing to help with schematics and all, and extending the display but I'm not that great of a coder. Yet.

I have found a few projects that chain a 4017, most notably this one...

Also, something I would add to the display are transistors on each of the columns. My display couldn't be seen in bright light, so that would help the LED brightness some (assuming that the LED's could take a higher current, or more voltage). Adding 2 or more LEDs or super bright LEDs for the column LEDs would probably help a lot!
 
Also-I would very much reccomend bread boarding this design before soldering it, just in case you need to make a few changes. It might take a couple breadboards though, due to the large amount if circuitry. If you need breadboards I saw some at tayda electronics for $3.50 a pop for a double length breadboard. Shipping isn't bad either!
 

(*steve*)

¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd
Moderator
No need to breadboard it all.

Breadboard 2 or 3 595's so you know you can program the outputs you want on them,

And maybe two columns of LEDs, or a 4x4 block.
 
Top