This 4x4x4 cube is interactive by using the top four corner LEDs both as LEDs and as sensors that will react on light. Depending on what LED gets the least light, the cube will run a different show.
Remove these ads by
Signing UpStep 1You will need:
soldering iron
pliers
small screwdriver
some drillbits
drill
solder
piece of wood
pencil
ruler
computer with Arduino software
USB-cable
snips
sharpie
breadboard (optional)
PARTS
64 led's
4 resistors that go with the LED's (yes just 4)
1 Photocube
1 Arduino
some wire
some small COAX wire (isolated wire)
16 headerpins
| « Previous Step | Download PDFView All Steps | Next Step » |



















































- Thanks
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 "play" to send it trough a USB-cable to your Arduino.
-Thanks
If i want to remove "sensors" 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?
BTW i already build first 3 layers and it works like a charm...:D
Thanks
Yes if you just solder the corners in like the rest, you will have a "normal" 4x4x4 LED-cube.
Will you show the result?
Peter
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;)
I will show result when the project is finished...
Thanks again
thanks
Can you explain why the void setup - PinMode have to set to INPUT?? Thanks :)
So far I have put together another layer like the second layer and soldered the Cathodes to the Anodes, and have the Anodes free to be connected to the Arduino.
I don't understand how to connect the 4th layer at all...
(Sorry, I am not really good with schematics)
With the corners, do I connect the Cathode and Anode to Arduino? Will I need more resistors?
Yes, the LED is the sensor and it is also a LED. It is not both in the same time, but on the arduino, we can change the ports from input to output, so the LED can first be sensor with the analog-port on the Arduino being input and next it is a normal LED if we put the analog-port in output-mode.
See also my mini-instructable on the subject and play a bit with that:
http://www.instructables.com/id/LED-as-lightsensor-on-the-arduino/
You will just need the 4 resistors as mentioned. No other electronics-parts needed.
I used the newer Arduino Duemilanove board, (not the uno that is on the picture, but that will work also), so that must be the ATmega328p. But I'm sure it will also work with the 168. The sketch is not that big. I just don't have one to try.
The ATmega8 chip on the Uno is just the chip that handles the USB-connection and has nothing to do with het actual chip that handles the Arduino-software. That is also the ATmega328.
Thanks,
Christian
Yes, you can just delete everything in Splash 3 and put a4(); there, than just 1 LED will light up, instead of what is playing now.
Thanks,
Christian
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;
"instellen van de gevoeligheid" means setting the sensitivity in Dutch. Here it is set on 20 for all four sensors. If you increase this number for all four sensors, they will be less sensitive.
It is also very important that you use cable with the anode connected to the inside and the cathode connected to a wire that is totally surrounding the inside cable and shielding it for interference that is all around us.
Best,
Christian
That must be a nice school you are on.
You should use single, male headers. Most of the time I cut them with a stanley-knife. If you break them they often break at the wrong place.
You can also do without the headers and bend en put the ends of the wires directly in the Arduino. It is just a little bit more fiddly.
Peter
If I have some time I will give a better explanation of the code, to make it easier to tinker with it.
I would love to see a picture or youtube-clip of your cube.