Close
0%
0%

8x8x8 Blue LED Cube

512 LEDs driven by an Arduino via eight shift-registers and eight MOSFETs

Similar projects worth following
512 LEDs driven by an Arduino via eight 8-bit shift registers and eight MOSFETs.
Most LED cubes I've seen are limited by the LED lead length. I wanted my cube to be as large as possible while still producing smooth animations. I settled on 4cm between leds, resulting in a 28 cm (11 inch) cube.

I also wanted the cube to be more interactive, so I used the remaining six ports on the Arduino to handle three touch sensors (thanks to Paul Badger for his awesome CapSense library) and two potentiometers.

Videos of this project:
http://www.youtube.com/playlist?list=PL-xZsBalytNBI9KC3nuA_Jo6j9hP-5_9D

I found the 4x4x4 RGB cube very rewarding to build so I'm moving up to 8x8x8.  I decided that I'm not ready for RGB version yet, so I'm only building single color.

WIRING:
Electrically, the cube is made up of 64 pillars containing 8 LEDs each.
Eight 8-bit shift registers (74HC595) supplies the GROUND for those pillars.

Each layer of the cube shares a common +5V switched by a P-Channel MOSFET, for a total of 8 MOSFETs.

HOW IT WORKS:
At any time, a maximum of 64 LEDs of ONE particular layer would be all lit up. Quickly setting up which of those LEDs on that layer should be on and then repeating that for the other layers, gives the illusion that we can individually control every individual LED.

LESSONS LEARNED:
My desire to spread the LEDs beyond the length of the LED leads added a LOT of complexity to the cube construction.  More soldering, having to deal with alignment of the extra wires.  Larger cube also meant more fragile cube.  The result is an impressive 11"x11"x11" cube.  However, it took many more hours to build compared to the usual led cube.

I made a mistake in wiring the ground of the shift register to the AREF pin of the Arduino instead of GND.  This resulted a lot of unnecessary circuit, which I was later able to eliminate.  The final circuit uses a 2N2222A NPN-Transistor and a FQP27P06 P-Channel MOSFET for each layer, and no extra transistors for the shift registers.

CODE:

Various versions of the code is on github

View all 14 components

  • Circuit Diagram

    Hari Wiguna12/05/2014 at 01:16 1 comment

    Click to see larger version.

  • Added Touch Sensors

    Hari Wiguna07/26/2014 at 13:30 0 comments

  • It's done!

    Hari Wiguna07/24/2014 at 23:47 0 comments

    Instead of counting holes on the PCB, I used a piece of paper as a jig.

    All the top LEDs are rested in the holes of the wooden jig.  It was standing like this while I solder all the cross wires.

    Foam core board is my friend.  A very simple jig made of foam core with slits cut using a razor blade. Holds the wires at perfect 4cm spacing.

    This small screwdriver was just the right weight to lightly hold down on the wire that I'm soldering.

    I like how the cube looks when you're looking down the "aisles" rather than straight on the walls.  So I decided to make this the front of the cube.

  • The Base

    Hari Wiguna07/21/2014 at 00:57 1 comment

    The cube will be mounted on a PCB instead of a piece of wood.  Originally, I planned on putting all the components on this one board. That has the advantage of a very clean construction avoiding the ribbon cable mess between the LEDs and the shift register outpus.  However, I've since then decided to keep things modular so if I build another cube or came up with better circuit to drive the cube, I would have options.

    The frame you see below is black foam core board.  Inexpensive and very easy to work with.

    The cube is so large, the base had to be made of two PCBs.  

  • Shift Register board completed

    Hari Wiguna07/17/2014 at 00:38 0 comments

    Everything took longer than expected, but I am pleased with the result. 

    I did a continuity test after soldering each group of wiring.  That paid off!  The circuit worked the first time I plugged it in!

  • Layer MOSFET board completed

    Hari Wiguna07/14/2014 at 18:08 0 comments

    I decided to keep things modular, so the LEDs would be on one board, the column shift registers will be on another, and the layer MOSFETs on yet another PCB.

  • Amazing milestone

    Hari Wiguna06/29/2014 at 02:24 0 comments

    If you love LEDs, you got to see this. 

    LEDs taking over every open table surface :-) These are six of the eight walls.  There are two more 8x8 walls on another table.

  • Halfway there?

    Hari Wiguna06/24/2014 at 04:40 0 comments

    These are all 512 LEDs that will make up the cube. There will be eight vertical walls of 64 LEDs each.  Two such walls have been completed. The other six walls still need to be soldered together (eight strands of eight LEDs each).  Should go pretty quick now that I have the 3D printed jig.

  • More jigs

    Hari Wiguna06/22/2014 at 17:36 0 comments

    I'm sure I'm making this harder than it needs to be, but it took several iterations to make the "vertical" jig.
    I probably should make even more so I don't have to keep moving them as I solder.

    I got impatient and increased the print speed on my printer and that lowered the print quality.  Note how the LED is held crooked.  Thankfully, I was able to straighten it out by holding soldering iron near the trouble spot and correct the hole by inserting an LED to reform the hole.

    With six jigs, the structure is finally rigid enough for soldering.  Here's one finished wall.  Horizontal wires are anodes that will be common per layer.  Vertical wires are cathodes (eight per wall, 64 total).  You can see the excess vertical wires at the top of this photo.  These will elevate the lowest layer 4cm above the base, so the cube would appear to be floating rather than resting on the base.

  • It's easier to do it when you're laying down

    Hari Wiguna06/17/2014 at 05:32 0 comments

    Thanks to my fellow makers BrianM and TonyF for helping me solve the forest of 64 vertical wires!  As you've seen from my previous updates, I've been soldering 64 LEDs as horizontal layers.  This is a mistake!!  Once I have all all eight layers, soldering in a forest of 64 vertical cathode wires would be very difficult if not impossible.  I've seen others solve this by creating pillars or vertical walls of LEDs instead of horizontal layers of LEDs.  The next problem is how to keep the vertical wires straight up while also keeping the LED rows lined up.  BrianM came up with a brilliant solution! Lay them flat on the table!  Although we're making a wall of LEDs, there is no reason why we can't lay them flat while we solder them.  I made a jig using my 3D printer and as you can see, it works very well.  I just need to print a few more so I can solder the whole wall at once without moving the jig.

View all 21 project logs

Enjoy this project?

Share

Discussions

frankstripod wrote 06/09/2014 at 03:29 point
Just saw the chocolate in your picture. Nice :)

  Are you sure? yes | no

frankstripod wrote 06/09/2014 at 03:27 point
I know what you mean about the feedback. Did you try .Stack? http://hackaday.io/stack
This is probably bad advice; Paul at PJRC.com did a giant LED TV. Defiantly not your hardware, but some power supply circuits and other links if you scroll down: http://www.pjrc.com/teensy/td_libs_OctoWS2811.html
I bet you could get me and davedarko to bug enough people here for more advice :)

  Are you sure? yes | no

Hari Wiguna wrote 06/09/2014 at 04:58 point
Holy cow! 3 x 40A PSUs! No, my cube will only need less than 1.5A. Interesting project though. Yes, I tried .stack with poor result. However, I think I'm at a good point now. Despite increased complexity, cost did not rise much and I'm quite happy with the LED brightness. Thanks for the offer to get me more help. I'll take a raincheck for now. Keep on making!

  Are you sure? yes | no

davedarko wrote 06/08/2014 at 10:03 point
Have you thought about using an ULN2803? This way you could at least spare some soldering time. I wonder if one could use only 3 shift registers to control a cube, with two 74HCT08 AND-gates maybe, but I guess that's my part to find out.

  Are you sure? yes | no

Hari Wiguna wrote 06/09/2014 at 02:46 point
ULN2803 is a good idea. However, I do not follow your idea of using 3 shift registers and AND gates. Thanks for the ideas!

  Are you sure? yes | no

davedarko wrote 06/09/2014 at 06:47 point
First of all thank you for following my 3D led pov cube :) I thought my idea would save some chips but that was not thought through ;) if you would take and-gates for one plane you can adress 64 leds with 2 shift registers, switching only one pole. But you would need 16 74hct08s. Doesnt sound like a win anymore ;) i wonder how fast your approach is. Have you considered taking an extra shift register for switching the levels?

  Are you sure? yes | no

Hari Wiguna wrote 06/10/2014 at 01:48 point
davedarko, your pov cube is like a mechanical version of an actual 8x8x8 cube. Mechanical things are hard, but I don't see any reason why it would not work.

As far as the speed of my cube, by experimentation, I got it so it the refresh rate is high enough so I don't see flicker. The shift register is surprisingly fast, and the layer switching is nothing but two digitalWrite() calls. One to turn previous layer off, another to turn the next layer on after the 64 bits for that layer is ready. I did have to put 40ms delay before latching the shift register after I turn off the previous layer because without that delay, I was able to see faint glow of the next layer on the previous layer.

Maybe a shift register to switch layers would help that. However, that would be in addition to the MOSFETs. since the layer shift register would definitely unable to directly drive 64 leds. :-(

BTW, I'm replying to the head of this thread instead of your latest comment. Hopefully it would not be too confusing.

  Are you sure? yes | no

frankstripod wrote 06/08/2014 at 05:32 point
Thank you for the skull on my project! I sure wish I could help out here, but feel under qualified. I am following you because an 8x8x8 is on my project wish list, so your success is important to me. The last thing you probably need is me giving you a link as advice after two minutes of searching. Are you getting any help or good advice other than Alan's?

  Are you sure? yes | no

Hari Wiguna wrote 06/09/2014 at 02:57 point
Maybe I just don't know anybody on hackaday.io, but I'm surprised how little feedback I've been getting. Based on what I see on "Feed", most users are followers and there are not enough makers like us. That's ok. I still find enough interesting projects such as yours. :-)

  Are you sure? yes | no

Hari Wiguna wrote 05/28/2014 at 19:25 point
Thanks Alan!

  Are you sure? yes | no

Hari Wiguna wrote 05/27/2014 at 04:54 point
My plan is to have eight layers of 8x8 LEDs. All cathodes within each layer is connected together and driven by a MOSFET. Each of the 8x8 columns share the same anode driven by 64 individual output pin.

What I'm wondering is if it would be faster to use eight 8-bit latches or eight 8-bit shift registers to control those 64 bits.

  Are you sure? yes | no

Alan Kilian wrote 05/28/2014 at 16:24 point
The 8-bit latches will be faster, but you'll need, well, 8 bits of data and 8 latch enable lines.

The 8-bit serial shift registers will be slower, but you only need 2 or 3 lines depending on the specific device.

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates