2x2x2 cube qeustion

Hi all,

I am new to arduino and as a first try i made a led ube 2x2x2.
I connected the annodes to I/O 13,12,11,10 and the 2 kathodes to 4 and 5.

If i run a simple program and try to light all the leds only one layer will go on.
Why wont both layers go on?

I used no resistors.

My code below

//2x2x2 LED Cube Sequence 1
//By: TT
//23-11-2012
//all lights on/off
int C1 = 13;
int C2 = 12;
int C3 = 11;
int C4 = 10;

int L1 = 3;
int L2 = 4;

void setup() {
pinMode(C1, OUTPUT);
pinMode(C2, OUTPUT);
pinMode(C3, OUTPUT);
pinMode(C4, OUTPUT);

pinMode(L1, OUTPUT);
pinMode(L2, OUTPUT);

}

void loop() {
digitalWrite(L1, HIGH); //Layer 1 on
digitalWrite(L2, HIGH); //Layer 2 on
digitalWrite(C1, HIGH);
delay(50);
digitalWrite(C2, HIGH);
delay(50);
digitalWrite(C3, HIGH);
delay(50);
digitalWrite(C4, HIGH);
delay(500);
digitalWrite(C4, LOW);
digitalWrite(L1, LOW); //Layer 1 Ends
digitalWrite(C1, LOW);
digitalWrite(C2, LOW);
digitalWrite(C3, LOW);
digitalWrite(L2, LOW); //Layer 2 Ends

}

Please edit your post, select the code, and put it between [code] ... [/code] tags.

You can do that by hitting the # button above the posting area.

"I used no resistors."

Because you want to damage all your IO pins right off the bat?

Your ordering is a little off
void loop(){
write Anode(s) HIGH
write cathode1 LOW, pause, write cathode1 HIGH

write Anode(s) HIGH
write cathode2 LOW, pause, write cathode2 HGH
}