## Step 12: Finishing Up

Finally we are going to finish this cube! We can close the photo cube. One last check to make sure that no wires are touching that are not supposed to touch and than put the headers in the ports of the Arduino!

Upload the following sketch (code) and start experimenting with it.

I hope you will make manny changes and improvements on it and invite you to post them in the comments.

int tijd = 50; // set the speed
int tijdx = 0;

int basis1 = 0;
int basis2 = 0;
int basis3 = 0;
int basis4 = 0;
int sens1 = 0;
int sens2 = 0;
int sens3 = 0;
int sens4 = 0;
int x = 0;
int y = 0;
int totaal1 = 0;
int totaal2 = 0;
int totaal3 = 0;
int totaal4 = 0;

int map1 = 0;
int map2 = 0;
int map3 = 0;
int map4 = 0;

int led0 = 8;
int led1 = 9;
int led2 = 10;
int led3 = 11;
int led4 = 0; // nul
int led5 = 1; // nul
int led6 = 2; // nul
int led7 = 3; // nul
int led8 = 4;
int led9 = 5;
int led10 = 6;
int led11 = 7;

void setup()
{
pinMode(led0, INPUT);
pinMode(led1, INPUT);
pinMode(led2, INPUT);
pinMode(led3, INPUT);
pinMode(led4, INPUT);
pinMode(led5, INPUT);
pinMode(led6, INPUT);
pinMode(led7, INPUT);
pinMode(led8, INPUT);
pinMode(led9, INPUT);
pinMode(led10, INPUT);
pinMode(led11, INPUT);

// Serial.begin(9600);
}

void loop()
{
for(x =0; x < 50; x++)
{
totaal1 = totaal1 + sens1;
totaal2 = totaal2 + sens2;
totaal3 = totaal3 + sens3;
totaal4 = totaal4 + sens4;
}
sens1 = totaal1/x;
totaal1 = 0;
basis1 = sens1-20; // instellen van de gevoeligheid
sens2 = totaal2/x;
totaal2 = 0;
basis2 = sens2-20;
sens3 = totaal3/x;
totaal3 = 0;
basis3 = sens3-20;
sens4 = totaal4/x;
totaal4 = 0;
basis4 = sens4-20;

for(y=0;y<2000;y++){
for(x =0; x < 30; x++)
{

totaal1 = totaal1 + sens1;
totaal2 = totaal2 + sens2;
totaal3 = totaal3 + sens3;
totaal4 = totaal4 + sens4;
// delay(10);
}
sens1 = totaal1/x;
sens2 = totaal2/x;
sens3 = totaal3/x;
sens4 = totaal4/x;

if (sens1<basis1){
if (sens1 < ((sens2 + sens3 + sens4)/3))
splash1();
}

if (sens2<basis2){
if (sens2 < ((sens1 + sens3 + sens4)/3))
splash2();
}

if (sens3<basis3){
if (sens3 < ((sens1 + sens2 + sens4)/3))
splash3();
}

if (sens4<basis4){
if (sens4 < ((sens1 + sens3 + sens2)/3))
splash4();
}

totaal1 = 0;
totaal2 = 0;
totaal3 = 0;
totaal4 = 0;
delay(5);

/*
Serial.print(sens1, DEC); Serial.print(" - "); Serial.print(basis1, DEC);
Serial.println();
Serial.print(sens2, DEC); Serial.print(" - "); Serial.print(basis2, DEC);
Serial.println();
Serial.print(sens3, DEC); Serial.print(" - "); Serial.print(basis3, DEC);
Serial.println();
Serial.print(sens4, DEC); Serial.print(" - "); Serial.print(basis4, DEC);
Serial.println(); Serial.println();
*/
}

}

void splash1()
{
a4(); b4(); c4(); d4(); h4(); l4(); p4(); o4(); n4(); m4(); i4(); e4(); f4(); g4(); k4(); j4();
j3(); f3(); g3(); k3(); o3(); n3(); m3(); i3(); e3(); a3(); b3(); c3(); d3(); h3(); l3(); p3();
p2(); o2(); n2(); m2(); i2(); e2(); a2(); b2(); c2(); d2(); h2(); l2(); k2(); j2(); f2(); g2();
g1(); k1(); j1(); f1(); b1(); c1(); d1(); h1(); l1(); p1(); o1(); n1(); m1(); i1(); e1(); a1();
}

void splash2()
{
p4(); o4(); n4(); m4(); l4(); k4(); j4(); i4(); h4(); g4(); f4(); e4(); d4(); c4(); b4(); a4();
a3(); b3(); c3(); d3(); e3(); f3(); g3(); h3(); i3(); j3(); k3(); l3(); m3(); n3(); o3(); p3();
p2(); o2(); n2(); m2(); l2(); k2(); j2(); i2(); h2(); g2(); f2(); e2(); d2(); c2(); b2(); a2();
a1(); b1(); c1(); d1(); e1(); f1(); g1(); h1(); i1(); j1(); k1(); l1(); m1(); n1(); o1(); p1();
uit();
}

void splash3()
{
tijdx = tijd;
tijd = 0;
for (y = 0; y < 5 ; y++)
{
for (x = 0; x < tijdx/4 ; x++)
{
a1(); a2(); a3(); a4(); f1(); f2(); f3(); f4();
}
for (x = 0; x < tijdx/4 ; x++)
{
b1(); b2(); b3(); b4(); f1(); f2(); f3(); f4();
}
for (x = 0; x < tijdx/4 ; x++)
{
c1(); c2(); c3(); c4(); g1(); g2(); g3(); g4();
}
for (x = 0; x < tijdx/4 ; x++)
{
d1(); d2(); d3(); d4(); g1(); g2(); g3(); g4();
}
for (x = 0; x < tijdx/4 ; x++)
{
h1(); h2(); h3(); h4(); g1(); g2(); g3(); g4();
}
for (x = 0; x < tijdx/4 ; x++)
{
l1(); l2(); l3(); l4(); k1(); k2(); k3(); k4();
}
for (x = 0; x < tijdx/4 ; x++)
{
p1(); p2(); p3(); p4(); k1(); k2(); k3(); k4();
}
for (x = 0; x < tijdx/4 ; x++)
{
o1(); o2(); o3(); o4(); k1(); k2(); k3(); k4();
}
for (x = 0; x < tijdx/4 ; x++)
{
n1(); n2(); n3(); n4(); j1(); j2(); j3(); j4();
}
for (x = 0; x < tijdx/4 ; x++)
{
m1(); m2(); m3(); m4(); j1(); j2(); j3(); j4();
}
for (x = 0; x < tijdx/4 ; x++)
{
i1(); i2(); i3(); i4(); j1(); j2(); j3(); j4();
}
for (x = 0; x < tijdx/4 ; x++)
{
e1(); e2(); e3(); e4(); f1(); f2(); f3(); f4();
}
}
tijd = tijdx;
}

void splash4()
{
test();
}

void uit(){
pinMode(led0, INPUT);
pinMode(led1, INPUT);
pinMode(led2, INPUT);
pinMode(led3, INPUT);
pinMode(led4, INPUT);
pinMode(led5, INPUT);
pinMode(led6, INPUT);
pinMode(led7, INPUT);
pinMode(led8, INPUT);
pinMode(led9, INPUT);
pinMode(led10, INPUT);
pinMode(led11, INPUT);
pinMode(14, INPUT);
digitalWrite(14, LOW);
pinMode(15, INPUT);
digitalWrite(15, LOW);
pinMode(16, INPUT);
digitalWrite(16, LOW);
pinMode(17, INPUT);
digitalWrite(17, LOW);
}

void a1(){
pinMode(led0, OUTPUT);
digitalWrite(led0, LOW);
pinMode(led4, OUTPUT);
digitalWrite(led4, HIGH);
delay (tijd);
uit();
}

void b1(){
pinMode(led1, OUTPUT);
digitalWrite(led1, LOW);
pinMode(led4, OUTPUT);
digitalWrite(led4, HIGH);
delay (tijd);
uit();
}

void c1(){
pinMode(led2, OUTPUT);
digitalWrite(led2, LOW);
pinMode(led4, OUTPUT);
digitalWrite(led4, HIGH);
delay (tijd);
uit();
}

void d1(){
pinMode(led3, OUTPUT);
digitalWrite(led3, LOW);
pinMode(led4, OUTPUT);
digitalWrite(led4, HIGH);
delay (tijd);
uit();
}

void e1(){
pinMode(led0, OUTPUT);
digitalWrite(led0, LOW);
pinMode(led5, OUTPUT);
digitalWrite(led5, HIGH);
delay (tijd);
uit();
}

void f1(){
pinMode(led1, OUTPUT);
digitalWrite(led1, LOW);
pinMode(led5, OUTPUT);
digitalWrite(led5, HIGH);
delay (tijd);
uit();
}

void g1(){
pinMode(led2, OUTPUT);
digitalWrite(led2, LOW);
pinMode(led5, OUTPUT);
digitalWrite(led5, HIGH);
delay (tijd);
uit();
}

void h1(){
pinMode(led3, OUTPUT);
digitalWrite(led3, LOW);
pinMode(led5, OUTPUT);
digitalWrite(led5, HIGH);
delay (tijd);
uit();
}

void i1(){
pinMode(led0, OUTPUT);
digitalWrite(led0, LOW);
pinMode(led6, OUTPUT);
digitalWrite(led6, HIGH);
delay (tijd);
uit();
}

void j1(){
pinMode(led1, OUTPUT);
digitalWrite(led1, LOW);
pinMode(led6, OUTPUT);
digitalWrite(led6, HIGH);
delay (tijd);
uit();
}

void k1(){
pinMode(led2, OUTPUT);
digitalWrite(led2, LOW);
pinMode(led6, OUTPUT);
digitalWrite(led6, HIGH);
delay (tijd);
uit();
}

void l1(){
pinMode(led3, OUTPUT);
digitalWrite(led3, LOW);
pinMode(led6, OUTPUT);
digitalWrite(led6, HIGH);
delay (tijd);
uit();
}

void m1(){
pinMode(led0, OUTPUT);
digitalWrite(led0, LOW);
pinMode(led7, OUTPUT);
digitalWrite(led7, HIGH);
delay (tijd);
uit();
}

void n1(){
pinMode(led1, OUTPUT);
digitalWrite(led1, LOW);
pinMode(led7, OUTPUT);
digitalWrite(led7, HIGH);
delay (tijd);
uit();
}

void o1(){
pinMode(led2, OUTPUT);
digitalWrite(led2, LOW);
pinMode(led7, OUTPUT);
digitalWrite(led7, HIGH);
delay (tijd);
uit();
}

void p1(){
pinMode(led3, OUTPUT);
digitalWrite(led3, LOW);
pinMode(led7, OUTPUT);
digitalWrite(led7, HIGH);
delay (tijd);
uit();
}

void a2(){
pinMode(led0, OUTPUT);
digitalWrite(led0, HIGH);
pinMode(led4, OUTPUT);
digitalWrite(led4, LOW);
delay (tijd);
uit();
}

void b2(){
pinMode(led1, OUTPUT);
digitalWrite(led1, HIGH);
pinMode(led4, OUTPUT);
digitalWrite(led4, LOW);
delay (tijd);
uit();
}

void c2(){
pinMode(led2, OUTPUT);
digitalWrite(led2, HIGH);
pinMode(led4, OUTPUT);
digitalWrite(led4, LOW);
delay (tijd);
uit();
}

void d2(){
pinMode(led3, OUTPUT);
digitalWrite(led3, HIGH);
pinMode(led4, OUTPUT);
digitalWrite(led4, LOW);
delay (tijd);
uit();
}

void e2(){
pinMode(led0, OUTPUT);
digitalWrite(led0, HIGH);
pinMode(led5, OUTPUT);
digitalWrite(led5, LOW);
delay (tijd);
uit();
}

void f2(){
pinMode(led1, OUTPUT);
digitalWrite(led1, HIGH);
pinMode(led5, OUTPUT);
digitalWrite(led5, LOW);
delay (tijd);
uit();
}

void g2(){
pinMode(led2, OUTPUT);
digitalWrite(led2, HIGH);
pinMode(led5, OUTPUT);
digitalWrite(led5, LOW);
delay (tijd);
uit();
}

void h2(){
pinMode(led3, OUTPUT);
digitalWrite(led3, HIGH);
pinMode(led5, OUTPUT);
digitalWrite(led5, LOW);
delay (tijd);
uit();
}

void i2(){
pinMode(led0, OUTPUT);
digitalWrite(led0, HIGH);
pinMode(led6, OUTPUT);
digitalWrite(led6, LOW);
delay (tijd);
uit();
}

void j2(){
pinMode(led1, OUTPUT);
digitalWrite(led1, HIGH);
pinMode(led6, OUTPUT);
digitalWrite(led6, LOW);
delay (tijd);
uit();
}

void k2(){
pinMode(led2, OUTPUT);
digitalWrite(led2, HIGH);
pinMode(led6, OUTPUT);
digitalWrite(led6, LOW);
delay (tijd);
uit();
}

void l2(){
pinMode(led3, OUTPUT);
digitalWrite(led3, HIGH);
pinMode(led6, OUTPUT);
digitalWrite(led6, LOW);
delay (tijd);
uit();
}

void m2(){
pinMode(led0, OUTPUT);
digitalWrite(led0, HIGH);
pinMode(led7, OUTPUT);
digitalWrite(led7, LOW);
delay (tijd);
uit();
}

void n2(){
pinMode(led1, OUTPUT);
digitalWrite(led1, HIGH);
pinMode(led7, OUTPUT);
digitalWrite(led7, LOW);
delay (tijd);
uit();
}

void o2(){
pinMode(led2, OUTPUT);
digitalWrite(led2, HIGH);
pinMode(led7, OUTPUT);
digitalWrite(led7, LOW);
delay (tijd);
uit();
}

void p2(){
pinMode(led3, OUTPUT);
digitalWrite(led3, HIGH);
pinMode(led7, OUTPUT);
digitalWrite(led7, LOW);
delay (tijd);
uit();
}

void a3(){
pinMode(led8, OUTPUT);
digitalWrite(led8, LOW);
pinMode(led4, OUTPUT);
digitalWrite(led4, HIGH);
delay (tijd);
uit();
}

void b3(){
pinMode(led9, OUTPUT);
digitalWrite(led9, LOW);
pinMode(led4, OUTPUT);
digitalWrite(led4, HIGH);
delay (tijd);
uit();
}

void c3(){
pinMode(led10, OUTPUT);
digitalWrite(led10, LOW);
pinMode(led4, OUTPUT);
digitalWrite(led4, HIGH);
delay (tijd);
uit();
}

void d3(){
pinMode(led11, OUTPUT);
digitalWrite(led11, LOW);
pinMode(led4, OUTPUT);
digitalWrite(led4, HIGH);
delay (tijd);
uit();
}

void e3(){
pinMode(led8, OUTPUT);
digitalWrite(led8, LOW);
pinMode(led5, OUTPUT);
digitalWrite(led5, HIGH);
delay (tijd);
uit();
}

void f3(){
pinMode(led9, OUTPUT);
digitalWrite(led9, LOW);
pinMode(led5, OUTPUT);
digitalWrite(led5, HIGH);
delay (tijd);
uit();
}

void g3(){
pinMode(led10, OUTPUT);
digitalWrite(led10, LOW);
pinMode(led5, OUTPUT);
digitalWrite(led5, HIGH);
delay (tijd);
uit();
}

void h3(){
pinMode(led11, OUTPUT);
digitalWrite(led11, LOW);
pinMode(led5, OUTPUT);
digitalWrite(led5, HIGH);
delay (tijd);
uit();
}

void i3(){
pinMode(led8, OUTPUT);
digitalWrite(led8, LOW);
pinMode(led6, OUTPUT);
digitalWrite(led6, HIGH);
delay (tijd);
uit();
}

void j3(){
pinMode(led9, OUTPUT);
digitalWrite(led9, LOW);
pinMode(led6, OUTPUT);
digitalWrite(led6, HIGH);
delay (tijd);
uit();
}

void k3(){
pinMode(led10, OUTPUT);
digitalWrite(led10, LOW);
pinMode(led6, OUTPUT);
digitalWrite(led6, HIGH);
delay (tijd);
uit();
}

void l3(){
pinMode(led11, OUTPUT);
digitalWrite(led11, LOW);
pinMode(led6, OUTPUT);
digitalWrite(led6, HIGH);
delay (tijd);
uit();
}

void m3(){
pinMode(led8, OUTPUT);
digitalWrite(led8, LOW);
pinMode(led7, OUTPUT);
digitalWrite(led7, HIGH);
delay (tijd);
uit();
}

void n3(){
pinMode(led9, OUTPUT);
digitalWrite(led9, LOW);
pinMode(led7, OUTPUT);
digitalWrite(led7, HIGH);
delay (tijd);
uit();
}

void o3(){
pinMode(led10, OUTPUT);
digitalWrite(led10, LOW);
pinMode(led7, OUTPUT);
digitalWrite(led7, HIGH);
delay (tijd);
uit();
}

void p3(){
pinMode(led11, OUTPUT);
digitalWrite(led11, LOW);
pinMode(led7, OUTPUT);
digitalWrite(led7, HIGH);

uit();
}

void a4(){
digitalWrite(14, HIGH);
pinMode(14, OUTPUT);
digitalWrite(14, HIGH);
delay (tijd);
uit();

}

void b4(){
pinMode(led9, OUTPUT);
digitalWrite(led9, HIGH);
pinMode(led4, OUTPUT);
digitalWrite(led4, LOW);
delay (tijd);
uit();
}

void c4(){
pinMode(led10, OUTPUT);
digitalWrite(led10, HIGH);
pinMode(led4, OUTPUT);
digitalWrite(led4, LOW);
delay (tijd);
uit();
}

void d4(){
digitalWrite(15, HIGH);
pinMode(15, OUTPUT);
digitalWrite(15, HIGH);
delay (tijd);
uit();
}

void e4(){
pinMode(led8, OUTPUT);
digitalWrite(led8, HIGH);
pinMode(led5, OUTPUT);
digitalWrite(led5, LOW);
delay (tijd);
uit();
}

void f4(){
pinMode(led9, OUTPUT);
digitalWrite(led9, HIGH);
pinMode(led5, OUTPUT);
digitalWrite(led5, LOW);
delay (tijd);
uit();
}

void g4(){
pinMode(led10, OUTPUT);
digitalWrite(led10, HIGH);
pinMode(led5, OUTPUT);
digitalWrite(led5, LOW);
delay (tijd);
uit();
}

void h4(){
pinMode(led11, OUTPUT);
digitalWrite(led11, HIGH);
pinMode(led5, OUTPUT);
digitalWrite(led5, LOW);
delay (tijd);
uit();
}

void i4(){
pinMode(led8, OUTPUT);
digitalWrite(led8, HIGH);
pinMode(led6, OUTPUT);
digitalWrite(led6, LOW);
delay (tijd);
uit();
}

void j4(){
pinMode(led9, OUTPUT);
digitalWrite(led9, HIGH);
pinMode(led6, OUTPUT);
digitalWrite(led6, LOW);
delay (tijd);
uit();
}

void k4(){
pinMode(led10, OUTPUT);
digitalWrite(led10, HIGH);
pinMode(led6, OUTPUT);
digitalWrite(led6, LOW);
delay (tijd);
uit();
}

void l4(){
pinMode(led11, OUTPUT);
digitalWrite(led11, HIGH);
pinMode(led6, OUTPUT);
digitalWrite(led6, LOW);
delay (tijd);
uit();
}

void m4(){
digitalWrite(17, HIGH);
pinMode(17, OUTPUT);
digitalWrite(17, HIGH);
delay (tijd);
uit();
}

void n4(){
pinMode(led9, OUTPUT);
digitalWrite(led9, HIGH);
pinMode(led7, OUTPUT);
digitalWrite(led7, LOW);
delay (tijd);
uit();
}

void o4(){
pinMode(led10, OUTPUT);
digitalWrite(led10, HIGH);
pinMode(led7, OUTPUT);
digitalWrite(led7, LOW);
delay (tijd);
uit();
}

void p4(){
digitalWrite(16, HIGH);
pinMode(16, OUTPUT);
digitalWrite(16, HIGH);
delay (tijd);
uit();
}

void test(){
pinMode(led0, OUTPUT);
pinMode(led1, OUTPUT);
pinMode(led2, OUTPUT);
pinMode(led3, OUTPUT);
pinMode(led4, OUTPUT);
pinMode(led5, OUTPUT);
pinMode(led6, OUTPUT);
pinMode(led7, OUTPUT);
pinMode(led8, INPUT);
pinMode(led9, INPUT);
pinMode(led10, INPUT);
pinMode(led11, INPUT);

digitalWrite(led0, LOW);
digitalWrite(led1, LOW);
digitalWrite(led2, LOW);
digitalWrite(led3, LOW);

digitalWrite(led4, HIGH);
digitalWrite(led5, HIGH);
digitalWrite(led6, HIGH);
digitalWrite(led7, HIGH);
delay (tijd*4);

digitalWrite(led0, HIGH);
digitalWrite(led1, HIGH);
digitalWrite(led2, HIGH);
digitalWrite(led3, HIGH);

digitalWrite(led4, LOW);
digitalWrite(led5, LOW);
digitalWrite(led6, LOW);
digitalWrite(led7, LOW);
delay (tijd*4);

pinMode(led0, INPUT);
pinMode(led1, INPUT);
pinMode(led2, INPUT);
pinMode(led3, INPUT);
pinMode(led8, OUTPUT);
pinMode(led9, OUTPUT);
pinMode(led10, OUTPUT);
pinMode(led11, OUTPUT);

digitalWrite(led8, LOW);
digitalWrite(led9, LOW);
digitalWrite(led10, LOW);
digitalWrite(led11, LOW);

digitalWrite(led4, HIGH);
digitalWrite(led5, HIGH);
digitalWrite(led6, HIGH);
digitalWrite(led7, HIGH);
delay (tijd*4);

digitalWrite(led8, HIGH);
digitalWrite(led9, HIGH);
digitalWrite(led10, HIGH);
digitalWrite(led11, HIGH);

digitalWrite(led4, LOW);
digitalWrite(led5, LOW);
digitalWrite(led6, LOW);
digitalWrite(led7, LOW);
delay (tijd*4);
uit();

}
i think i may have soldered the third layer down to the second layer incorrectly. i soldered the anodes of the third layer to the cathodes of the second. That meant i had to turn the third layer 90 degrees clockwise instead of counter clockwise as your instructions say. I'm not sure what i did wrong
That could mess up the patterns a little (what you could fix in the sketch) but they should still light up correctly. So there must be something else...
I double checked polarity. Everything seems correct. double checked resisters. Using 100 ohm as per led calculator for 3v@20mah leds at 5v+. Every led is functioning at some point. i can't seem to figure it out:/
Very informative instructable. I'm trying to duplicate your work here. I've finished the cube as far as i can tell, but the top 2 layers only light up to half of the brightness and do not seem to follow the rest of the patterns of the first 2 layers. I've double checked everything i can think of (anode touching cathode, wire disconnected, short... ) im still new to arduino so any help would be appreciated
I can't think of any reason that would happen except the things you already checked. You could check the values of your resistors and the polarity of the LED's although I don't really think that would be it. When I think of something smarter I will let you know.<br>Sorry I can't be of better assistance at this moment.
Any Arduino board would work, but to start with I would choose the UNO or leonardo. The (old) Duemilanove would also work fine.<br>I would advise you to start with some simple playing with LED's and sensors before you try this more complex LED-cube. Adafruit (http://www.adafruit.com) and Oomlout (http://www.oomlout.com) have some great tutorials.<br>If you have already some electronics experience and you understand what multiplexing and charlyplexing is about, this project will not be a problem for you.<br>Have fun!
ya i have done some led project in clg,so m trying this one. <br>I m not understanding the concept of top corner four sensors led n how are its connection so plz help me out with it and m using blue led for 1st &amp;4th layer and green for 2nd &amp;3rd layer let me know weather its ok or not. <br>n thanks for previous reply
The color you use is up to you. Just be sure to use the right resistors to go with your LED's.<br>It might help to look at this ible to understand the tot corner LED's: https://www.instructables.com/id/LED-as-lightsensor-on-the-arduino/<br>This YouTube clip might also be helpful:<br>http://www.youtube.com/watch?v=lzh4xMi0l2Y
i just completed my cube but the problem is,when the rotational function comes the LED's become very dim n the fourth layer is also not glowing.i used 560ohm resister let me know weather its correct for green n blue led or not. <br>i under stood the sensor part Thanks for that...
The resistor can be different for every type and brand of LED. If you can find a datasheet with your LED's, this might help. Otherwise just ask your supplier what resistor should go with your LED's for a 5 volt supply.
Thanks,I got my fourth layer on but still the rotational function is very dim n not at all clear
can u plzz suggest me about my question,i have almost completed the project
The only thing I can think of is that you use the wrong resistor. The LED's will never be in full brightness because they are not burning full time but blinking very fast. (faster then the eye can see) but they should not burn dim.
ok...thanks for your suggestion n help throught the working. <br>comment:keep making and sharing such innovative things ;):)
Super cool!
(I'm also having problems with the captcha and replying, sorry) <br> <br>I finished it now, but the problem with the LEDs in the second row always lightly burning still exists... If you have any idea about that I'll be gratefull. <br> <br>I also had to change the portnumbers and some other things in the code because I think I did things slightly different. <br> <br>Now I'm working on 3D snake code :) I'll post a video link when it's done. <br> <br>Thanks very much for your instructions
No it's not , want me to post a picture? <br>Ps: sorry but for some reason it won't let me reply
Yes, a picture might be helpful.
also i have another question, i dont know if you are going to know this but with my arduino uno came a nother board that mounts on top of the arduino with the arduino ports. do you know what that board is for or if i should even use it? i tried serching for it on the internet but couldnt find anything
Could it be a protoshield? http://arduino.cc/en/Main/ArduinoProtoShield
i did the first two layers succesfull, but im having trouble with the 3rd and 4th. <br>i dont quite understand what you mean by the corner LED's. <br>on mine i didnt finish reading the instructions so i did the 4th layer like i did the first one. How can i fix this and how to i hook it up properly
When you didn't leave out the top corner led's, you will end up with a normal 4x4x4 LED-cube without the interactivity aspect of it. If you do want the interactivity, you will need to desolder the corner led's and resume as instructed. The four top corner led's need to be totally separate from the rest of the cube.
Hmmm... I have a 3x3x3, but this looks so good I may have to make one! Great instructions. Thanks!
is there something besides COAX wire you can use? something like maybe speaker/lead wire?
The wire needs to be shielded in some way to work. The signal from the LED is very weak and easily disturbed.
Could you tell me the music you used in your final video?
I just used one of the tunes Youtube provides.
What are the dimensions of just the led cube part?
The distance between the LED's is 12,5 mm, so the cube is approximately 40 x 40 x 60 mm.
oh that's perfect thanks! <br>
thanks a lot kenyer. I am now half-way on finishing the project. your work really appreciated specially the codes. <br> <br>Questions: If i want to replace the 4 LED sensor and replace it by a switch, how would i write the code. I mean where would i start?...
Hi Zealroy, <br> <br>If you leave out the sensors, it will make your code much easier. You can delete everything in the void loop() and replace it by code that will test your button(s) and then calls one of the four splash voids. <br> <br>I hope this was helpful for you
Alright here is the finished product, as promised.
WOW really nice! I like the nice box for the electronics.
Thank you, I bought the wood at micheals and built, sanded and stained it. <br />I am impressed with the finished product, now I need to attempt a larger cube!
So I just completed this cube and I did it without the sensors, <br>I did layer one as described, layer two charlieplexed with layer 1, layer 3 i have the anodes of layer 3 bent down and soldered with the cathodes of layer 2, and i have the cathodes of layer 3 soldered to the anodes of layer 4. <br> <br> <br>I have the code uploaded to the arduino, and it seems to be working, well the bottom two layers work fine, the top 2 layers, are half working? the leds are very dim and dont seem to follow the pattern expected. I may have mis soldered layer 2-3 im not sure any idea? <br>
Turns out the pin zero on my arduino is shorted, i moved them all over one pin and made the adjustments and it works great!
Cool to hear that it works. I'm curious how it turned out. Can you post a picture?
I'm brand new with arduino and i was curious to how you would upload the code on to it? any help will be appreciated. Also great work.<br> - Thanks
Hi,<br>That is really easy. You just need to download the free software from www.arduino.cc (for windows, mac or linux) and you can write your code in this program and push &quot;play&quot; to send it trough a USB-cable to your Arduino.
Thank you so much. i know this was a simple question but like i said i'm brand new with arduino <br> -Thanks <br>
Question...<br>If i want to remove &quot;sensors&quot; LEDs and make normal LED cube, what would i have to change? Would it work if i just solder 4 corner LEDs like the others are and then solder them to third layer as the rest are? And then i do little reprograming?<br>BTW i already build first 3 layers and it works like a charm...:D<br><br>Thanks
Hi Cvenko,<br><br>Yes if you just solder the corners in like the rest, you will have a &quot;normal&quot; 4x4x4 LED-cube.<br>Will you show the result?<br><br>Peter
waw... Thanks for quick reply...<br><br>For now only layers 1 and 2 are working correctly... the 3 and 4 are behaving wierd... I will need to check if soldering was done correctly... But tomorrow;)<br><br>I will show result when the project is finished...<br><br>Thanks again
hey. i am trying to finish the first layer, but i cant seem to get the wiring right to go to the arduino. is there any way you could post a picture?<br>thanks
Hi Kenyer, <br> Can you explain why the void setup - PinMode have to set to INPUT?? Thanks :)
That is a need trick. Normally the pin is HIGH or LOW, but when it is set on INPUT it is neither. It just goes along with whatever it gets.
If the extra LED is a sensor then why can the sensor itself blinking ? is it possible ?<br>