Matrix 18x18 with 4 LEDs

Hi buddies!

I'm building a circuit with 4 LEDs (in parallel) in a big Matrix 18x18, in total 1296 LEDs.
I'm going to use a Arduino MEGA because I will use 36 pins, but I have read that the Imax in Arduino MEGA is 50mA, and 4 LEDs have like 80mA.
Does anyone have any ideas?

Another option is using a Multiplexor with 32 pins... but it's difficult to find one with 100 mA.

Thanks a lot!

In building matrices, do not expect to drive them directly with a MCU of any sort.

If you use TPIC6A595s, you can sink up to a few hundred milliamps, and use series chains of four LEDs from 12 or 16V (depending on what sort of LEDs they are). And you only need three lines to drive them (two or three chained) as a shift register.

Then you need to figure out what to use as a "high side" driver which can drive 20 mA into each chain of four LEDs. An easy way is to use PNP transistors and more TPIC6C595s to drive them via resistors (about 10k). You then have five TPIC6A595s or three TPIC6A595s and two TPIC6C595s all in a chain driven by three pins.

Or a possibly less readily available chip as in this thread.

I was thinking to use four of ADG5206 because it's easier to program, I just need to put a binary number with the inputs (A0, A1...). I'm a beginner but think that I have to connect 18 entrance and 18 exists with Arduino if I want to choose which Led I want.
The other option is without multiplexer... With Arduino UNO I can switch on 4 parallel LEDs, but theoretical it has maximum 50 mA, and four LEDs are 80 mA.

kevinm12:
I was thinking to use four of ADG5206 because it's easier to program, I just need to put a binary number with the inputs (A0, A1...). I'm a beginner but think that I have to connect 18 entrance and 18 exists with Arduino if I want to choose which Led I want.
The other option is without multiplexer... With Arduino UNO I can switch on 4 parallel LEDs, but theoretical it has maximum 50 mA, and four LEDs are 80 mA.

Kevin, you should take Paul__B's advice. I do not think your suggested chip will be suitable (on resistance of 155R?!?), and it will not be any easier to program in practice. You certainly cannot drive 1,200 leds directly from the Arduino!

Paul

Maybe I didn't explain correctly. I don't want to switch on 1200 LEDs, just 4, but really quickly, and then it's like "many LEDs at the same time"

I think it's hardly possible to get the "many LEDs at the same time" effect you hope to get with just four LED's.
If you've got 1200 LED's and four of them turn on each... 2-3 Miliseconds, to my knowledge you'll still be using to many Amps in a short time.
1200/4 = 300 LED's you need to have on within a few milliseconds in a row to gain a effect that's even noticable.

Buffer anode drive pins with MIC2981

Buffer cathode drive pins with ULN2803

Vce of MIC2981 is 1.7V to 2V at 100mA
Vce of ULN2803 is 0.9V to 1.1V at 100mA
Total: Best case 2.6V, worst case 3.1V
What is the Vf of your LED?
If you use a Open Drain, High Current output shift register such as TPIC6B595 (150mA rated outputs) the voltage across the output will be more like 0.5V at 80mA.
V = IIR, .08A * .08A * 5.7ohm = 0.04V

You may need to switch to discrete logic level, Low Rds P-channel MOSFET for the anode buffers to reduce that voltage also,

V = IIR, .08A * .08A * 0.2ohm = .001V
Don't forget current limit resistors with your LEDs:
(5V - (anode driver voltage drop) - (cathode driver voltage drop) - (Vf of LED))/.02A = resistor value
(5V - .04V - .001V - 2.2V)/.02A = ~140 ohm; use a standard value 150 ohm resistor for 18.4mA of current.
I used 2.2V for typical Vf of a Red LED - put in the Vf of your LED.
I would wire up an anode buffer and a cathode buffer and the 4 LEDs with expected resistor values and see what kind of voltages are actually occurring before wiring everything up to make sure of resistor values.

I personally would use a design that switches on a whole common cathode row at a time.
18 rows * .08A = 1.44A, which would require discrete logic level low Rds N-channel MOSFET buffers to sink current vs TPIC6B595.

Then you can have 1 of 18 columns on at a time (18 "pixels"), vs 1 of 324 pixels on at a time, the display will appear much brighter.
Refreshing the entire display at 30 Hz for flicker free operation, each row can be on for (1/30 S)/(18 rows) = 1.85mS, or 1850uS. Use blink without delay to do that.
Set up all the anode data to drive the rows, turn on 1 cathode driver to sink current for the columns, let 1850uS pass, turn off cathode driver.
Repeat for next column.