Step 9: Base and soldering resistors:

For the base is is pretty open ended on what you would like to do.  For mine I simply used a PCB (or glued PCB together) to solder my cube to.  Once i had my cube done i soldered wires from each column to a resistor. Each resistor was connected to another wire that i planed to plug the Arduino into. You will also need a wire soldered of each layer allowing for negative control (no resistor needed). You can make this part look alot better than mine but for time reasons i just soldered it up quick.
Thanks for the tutorial. Works like a charm!
Wouldn't the amount of current going through the ground pins blow them out? Like if all the LEDs in one layer are on, you'd need 16x20mA of current for the ground pin on that layer, and doesn't each pin on the Arduino only output like 40 or so mA? <br> <br>I thought that was why you needed a transistor for each layer, because the arduino couldn't sink the right amount of current to ground.
<p>Did you ever figure this one out? bc im confused here as well</p>
are you soldering to the anodes or cathodes
<p>the layers will be negative/Cathode and each column will be a positive/anode.</p>
i am wondering what PCB i should get
Any that the holes are not already connected. :)
Is This called multiplexing where all the cathodes of each layer are soldered together and the anodes of each column are soldered ? <br> <br>Also why weren't any transistors used as I have seen in other tutorials? <br> <br>Thanks <br>Ben
It sure is. <br> <br>If you don't want to use your micro controller pins as a power source you can use transistors. :). You can also control the layer grounds using transistors.
I made my cube and all of the lights work, however, there seems to be a problem with the wiring. Whenever I address a single LED in 6 of the columns, The whole column lights up. This does not happen in 2 columns where the LED's light up individually. <br>Help would be appreciated! <br>Thanks!
Sounds like you are grounding out each layer for those columns. Make sure in the code you are only have one layer ground on at a time. Somehow those 4 layers for the 6 columns are getting grounded make sure the wiring/soldering did not get crossed somehow.
Hey thanks a lot for the work i have created 4x4x4 led cube looking at you tutorial.&nbsp;<iframe frameborder="0" height="315" src="http://www.youtube.com/embed/-8lJ8YVt6cI" width="560"></iframe>
here's my effort using the UNO board. <br> <br>http://youtu.be/SeKxOYz2ri8 <br>Thanks Phogie!
Hey thanks for the information. i studied and did the same cube <br>below is the link for the same <br> <br>http://youtu.be/-8lJ8YVt6cI
Got my first cube done,waiting on proto board and a few components to actually finish the project but the cube is done and running on an arduino uno R3. Thanks everyone for all instructibles,questions,answered questions and most of all your time and patients. http://youtu.be/QjRBElq4a-8
Congrats!! Always feels good to finish a project!
Are you sure that an arduino can handle that current? although, only one led should be on any given time, I am still concerned that i could mess up the code, and end up drawing something like an amp from an arduino pin ( .....) . Do you think I should use darlington transistor arrays to the output pins and supply voltage from an external powersupply? many thanks andrew.
I think most arduinos are 40mA. If you want to live on the save side I would run them off transistors and a different power supply. Its really up to you I just decided to take the risk. My arduino still works I am sure i messed up the code a time or two but can not say for sure. I just remember the LEDs slowly getting more dim toward the top and i unpluged it as soon as possible. Could also set up functions in the code to handle the grounds. Four functions each one turns on a layer and off the others. <br> <br>Best of Luck!!
Okay Im pretty much stuck here..<br>Where do I connect the the layer's negative control wires to? (the black wires)<br>Note: Im very new to arduino
I added a diagram step number 8. I hope that helps if not let me know.
It worked! <br>and here is my result <br>http://youtu.be/VWYiD5FnHZc
Wooo Hoooo!! Looks good!
Great instructable :) Here is my results.<br> <a href="http://www.youtube.com/watch?v=lVW64nfY2PE" rel="nofollow">http://www.youtube.com/watch?v=lVW64nfY2PE</a><br> I used <strong><a href="http://www.instructables.com/id/The-4x4x4-LED-cube-Arduino/" rel="nofollow">forte1994</a></strong> arduino's program
Awesome! It looks good! Not as bent up as mine got hahaha.
hey. ive read your instructions, but im not sure where to connect the leads from the resistors to the arduino? Im not sure what ports to use
I added a diagram step number 8. I hope that helps if not let me know.
I just posted an <a href="http://www.instructables.com/id/3X3-LED-Cube-Programming-tips-Arduino-based/" rel="nofollow">instructable on programming a 3x3x3 cube</a> with an Arduino. It *might* be possible to adapt that to a 4x4x4 and give us even more programming possibilities. One would need to change the pin setup, but that is about all, I think.
I have followed your instructions, definitely the best instructable to help a beginner! I see your map for the columns, but can you tell me which cathode goes to which ground, for the layers?<br>Much appreciated :)
Thanks! It was my first one so its a little rough around the edges. I wrote a note down to get a circuit diagram up. In the code i set up pins 16-19 up as the ground pins. Those should be analog 2-5. Does that help?
Thanks for replying! it was just which ground pin to which layer, should 16 be the bottom layer?<br>I thought your instructable was really good, not completely idiot proof though as I am demonstrating!! I think maybe I was trying to run before I could walk with this, but following yours made it much easier to follow. Thanks again
Hi! I finished the cube, but I'm not sure where to attach the 16 columns of positive diodes, to the Arduino. Also I don't know where to put the negative ones either. Can you tell me which one goes to which pin number (like if the first one goes to A0, or like D3)? Sorry i'm new to Arduino, and the other instuctables used too many pieces. Thanks!
This would be from looking down onto the cube. Hope it helps! Each number represents a column of the cube and corresponds to an port on the arduino. Let me know if that works and ill add it to the tutorial!<br><br>----Back----<br><br>3 7 11 15<br>2 6 10 14<br>1 5 9 13<br>0 4 8 12<br><br>-----Front----<br><br>Yeah this was my first tutorial and i realized that I did not explain the connections very well. <br><br>On the freeduino i was using use the digital outputs for 0-15 and the analog next. So analog 0 corresponds to column 14 and analog 1 corresponds to column 15. Analog 2-5 will be the negative or ground for the 4 layers. <br><br>If you need anything else let me know.
Hey Sir...<br><br>Can you please explain how you write some letters in your 4x4x4 Cube?
I may have to watch the video again but I do not think there are any letters. If you want to write letters i would suggest building a bigger cube. A 4x4x4 does not give much room to create letters or numbers.
Oh, and if you have the electronic circuit, would be great.<br><br>Thank you.<br><br>Great project, congratulations!
Thanks! Ill make a note to create a circuit and let you know once i get it posted. :)
Great project! I played around with different colors on each layer and it makes for some fun patterns.<br><br>http://www.youtube.com/watch?v=fXeoowp5JtE
Nice! I do like the different colors! I would like to do a RGB one sometime just have to wait for a rainy day to spend some more on the LEDs.
I have a project for a subject, and I decided to do this Cube but I have one condition... I need to use transistors, so my question is... How can I design the circuit using my arduino and transistors???
You could use transistors to control when a specific layer is grounded. Instead of grounding the layers to the arduino you would have each layer go to a transistor. Then you can control the transistor with the arduino and chose when to ground out that layer. So in other words connect the ground for a layer to the collector of a NPN transistor and the arduino to the base and the ground to the emmitter. Then you can control that layers ground by setting that arduino pin on and off.
Por que est&aacute; chueco? sabes soldar?
My cube got abused.... it got smashed by a drunk friend and a backpack! I was able to almost bend it back when i put it in the case.<br><br>I hope Google Translate is accurate :)<br><br>Mi cubo se abusa .... que se estrell&oacute; por un amigo borracho y una mochila! Fui capaz de casi lo doble de nuevo cuando lo pongo en el caso.
I don't get how you connect wires to arduino.<br>My leds will just blink as random and not in order when I use the code. 'Cause I wired them up just randomly. Which ports should I be using?<br><br>There is something I do wrong, but I don't know what. Please help!
Hmmm I should have put that in there, my bad. I can see how it would be useful to know how to connect everything :). This would be from looking down onto the cube. Hope it helps! Each number represents a column of the cube and corresponds to an port on the arduino. Let me know if that works and ill add it to the tutorial!<br><br>----Back----<br><br>3 7 11 15<br>2 6 10 14<br>1 5 9 13<br>0 4 8 12<br><br>-----Front----
Does anyone know where to get an Arduino (i.e. the Uno) for less than what I'm finding them for? I can't really justify paying $30 for one (even tho it is very programmable), when I can get a pair of 556 relay timers for ~$.50 a piece that would perform a similar function; with the right capacitor/resistor setup.
My only idea would be to look into a freeduino basically same as Arduino but a little cheaper (although I think you have to solder yourself). I have actually used this arduino for multiple projects so that was my justification. Another justification may be to use the Arduino as an AVR ISP, however I do not know much of anything on that. But it would allow you to only have to replace an AVR when done with a project.
Thanks Phogie,<br>I may just do the 556 for my cube. I only plan on having a couple of groups of LEDs in mine turn on and off, so a 556 (i.e. two 555s) should do the trick. That said, I do plan on buying an Arduino in the future, as they are very robust for what you can do with them.<br>
I'm having trouble downloading the .pde file you've provided. Any help would be appreciated. I'm hoping it will help me figure out the programming side.<br><br>Your instructions have been very helpful. Probably the best I've come across so far. Thanks!
Sorry about the long response took a long vacation! :) I had some troubles downloading it also (never tried before) but i included it in a zip folder. This fixed the problem for me. Should just have to extract it once it is downloaded. If you have any more troubles let me know!<br><br>Thanks for the complements i am glad to hear it helped!
<p> This was my first Arduino project. I built this cube because I like the idea of using just the 20 digital pins, LEDs and a few resisters. Everyone at home and work&nbsp;likes this project and want to see what I can get it to do next. I used Paden's original code on this page to test my cube with excellent results on the first try. Here is the first sketch I was able to make funtion myself.<br> <br> /*&nbsp; 4x4x4 LED Cube<br> Chase around outside edge, counter clockwise, top to bottom.<br> By VoodooVw<br> */<br> <br> // Initalize our LED columns (positive)<br> int LEDPin[] = {0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15};<br> // Initalize the LED layers (ground)<br> int LayerPin[] = {16,17,18,19};<br> // Initalize the outside columns counter clockwise<br> int OuterEdge[] = {0,1,2,3,7,11,15,14,13,12,8,4};<br> <br> // The Setup<br> void setup(){<br> // Set up LED columns as output and off<br> for(int pin = 0; pin &lt; 16 ; pin++ ){<br> pinMode(LEDPin[pin],OUTPUT);<br> digitalWrite(LEDPin[pin],LOW);}<br> // Set up LED Layers as output and off<br> for(int layer = 0; layer &lt; 4; layer++){<br> pinMode(LayerPin[layer], OUTPUT);<br> digitalWrite(LayerPin[layer], HIGH);}}<br> <br> // Loop to chase around outside edge, counter clockwise, top to bottom<br> void loop(){<br> // Setup increment through layers loop<br> for(int layer = 0; layer &lt; 4; layer++){<br> // Setup increment through outer edge loop<br> for(int pin = 0; pin &lt; 12 ; pin++)<br> // Turn on LEDs starting from first column, top layer<br> {digitalWrite(OuterEdge[pin],HIGH);<br> digitalWrite(LayerPin[layer],LOW);<br> // Keep LED on for this time<br> delay(60);<br> // Turn off current lit LED then loop up to light next edge LED<br> digitalWrite(OuterEdge[pin],LOW);}<br> // Once all LEDs have been lit loop all the way up to increment layer<br> digitalWrite(LayerPin[layer],HIGH);}}<br> <br> <br> &nbsp;</p>

About This Instructable


100 favorites


More by Phogie7: TV Dynamic Ambient Lighting Arduino 4x4x4 LED Cube
Add instructable to: