big led matrix

Hi,

I’m new about arduino(i get it yesterday) but my first project is yet ambitious. I want to control a matrix panel 32x64 within 2048 leds.
Now I only want to understand how can i do this, i tried to simulate the matrix with one led and a loop who simulate the others leds but there is a problem, led resfresh is not quite fast to keep led on.
I’m surprise about this bheavior because arduino work with 16MHz clock.

for this project i’ ve planned to use some 16 line demultiplexer(2 mux rows and 4 mux columns), I suppose to select each led and turn on it with quick refresh.
I use 11 digital output, 5(2^5=32) for rows address and 6(2^6=64) for columns address.

what’s wrong and what can i do?
I’ve seen max2219 but if possible i want to use ttl demulitiplexer 74154, it’s so easy to use and much cheap.
can I write digital output in one shot?

that is the sample code who simulate the matrix.i tried to insert a delay to keep output, with this delay led is much bright but is not acceptable, however, without delay led don’t turn on(only a very very little glow

void setup()
{
pinMode(13, OUTPUT); // sets the digital pin as output
pinMode(12, OUTPUT); // sets the digital pin as output
pinMode(11, OUTPUT); // sets the digital pin as output
pinMode(10, OUTPUT); // sets the digital pin as output
pinMode(9, OUTPUT); // sets the digital pin as output
pinMode(8, OUTPUT); // sets the digital pin as output
pinMode(7, OUTPUT); // sets the digital pin as output
pinMode(6, OUTPUT); // sets the digital pin as output
pinMode(5, OUTPUT); // sets the digital pin as output
pinMode(4, OUTPUT); // sets the digital pin as output
pinMode(3, OUTPUT); // sets the digital pin as output
}

void loop()
{
digitalWrite(13, HIGH); // TEST LED i turn it on to check resfresh
digitalWrite(12, LOW);
digitalWrite(11, HIGH);
digitalWrite(10, LOW);
digitalWrite(9, HIGH);
digitalWrite(8, LOW);
digitalWrite(7, HIGH);
digitalWrite(6, LOW);
digitalWrite(5, HIGH);
digitalWrite(4, LOW);
digitalWrite(3, LOW);
// delay(10);
for (int i=0; i <= 2048; i++){
digitalWrite(13, LOW); // TEST LED: i turn off it to check resfresh
digitalWrite(12, LOW);
digitalWrite(11, HIGH);
digitalWrite(10, LOW);
digitalWrite(9, HIGH);
digitalWrite(8, LOW);
digitalWrite(7, HIGH);
digitalWrite(6, LOW);
digitalWrite(5, HIGH);
digitalWrite(4, LOW);
digitalWrite(3, LOW);
}
}

Hi q

Hi,
I want to control a matrix panel 32x64 within 2048 leds.
for this project i' ve planned to use some 16 line demultiplexer(2 mux rows and 4 mux columns), I suppose to select each led and turn on it with quick refresh.
I've seen max2219 but if possible i want to use ttl demulitiplexer 74154, it's so easy to use and much cheap.
can I write digital output in one shot?

I don't want to get into this too much, because I don't think you're on the right track.
A MAX7219 does a lot more than simply multiplex a few outputs.
I'm not sure your concept with the 74154 will even work. Do you have some sort of schematic for a small 4x4 Matrix that you intend to build?

I agree that the 7219 is not very cheap, but it will be definitly much easier to use than your own setup software- and hardware-wise .

Your code switches the test-Led on for only 2 ms per second. This is way too short.
A MAX7219 guarantees that every lit Led is on for 125ms per second. I think you have to get near that value to make your concept work.

Think about the 7219 again, in the end its going to be the cheaper solution.
Eberhard

hi,

Ok, now i think that I can't make logic with 74154, also i can start with 2 or 4 max7219 to create a small matrix.
Next week i will get two max7219 to test my system, also i have read about sprite and matrix library who supports multiple max7219, i suppose that can i use one or two bit to select each max7219. it's correct?
for example if i have a 16x8 matrix i will use 3 bit to mapping both max7219 rows and i'll use another bit to select the chip.
rows-out: 1001, select the first rows on the second chip, or something like this no?

can you suggest me a store to buy max7219 with good price?
what's different between max7219 and max7221?

thank for your reply

Andrea

Maxim very readily sent me two 7219s and 7221s as samples. They seem to have a fairly liberal sample policy...

thanks, now I remeber about maxim sample, I'll order it today.

The following program will perform a knight rider function with 16 LEDs using only four lines from the Arduino. This should give you an idea of what is possible.

The wiring is from the playground page though they are a bit lacking. I’ll need to write it down at some point.

/* Dual hef4794 knightrider toy
Public domain by MrMeval@gmail.com
*/

int data = 9;
int strob = 8;
int clock = 10;
int oe = 11;
int count = 0;
int dato = 0;
int ack = 13;

void setup()
{
pinMode(data, OUTPUT);
pinMode(clock, OUTPUT);
pinMode(strob, OUTPUT);
pinMode(oe, OUTPUT);
pinMode(ack, OUTPUT);
}

void loop()
{
digitalWrite(ack, HIGH);
dato = 1;
for (int i = 0 ; i < 16 ; i++){
shiftOut(data, clock, LSBFIRST, dato>>8);
shiftOut(data, clock, LSBFIRST, dato);
dato = dato<<1;
digitalWrite(oe, LOW);
digitalWrite(strob, HIGH);
digitalWrite(oe, HIGH);
digitalWrite(strob, LOW);
delay(50); // waits for a moment
digitalWrite(ack, LOW);
}
dato = 32768;
for (int i = 16 ; i > 0 ; i–){
shiftOut(data, clock, LSBFIRST, dato>>8);
shiftOut(data, clock, LSBFIRST, dato);
dato = unsigned (dato)>>1;
digitalWrite(oe, LOW);
digitalWrite(strob, HIGH);
digitalWrite(oe, HIGH);
digitalWrite(strob, LOW);
delay(50); // waits for a moment
digitalWrite(ack, LOW);
}

}