RGB LED Cube

by Jakub_Nagy in Circuits > LEDs

7233 Views, 53 Favorites, 0 Comments

RGB LED Cube

IMG_20181213_191443.png

In this instructable, we made a battery powered RGB LED cube. It automatically shifts through colours with the help of a built in microcontroler.

The bottom half of the cube is laser cut and the top half is 3D printed. The cube has a push button on the front and on the side is a DC barrel for charging. Inside is a battery pack consisting of three li-ion batteries powering the 3W LED module as well as the ATTINY85 and the driver circuit.

The purpose of this lamp is primarly decorative, but after the first tests it turned out that the cube actually lit up dark areas pretty well. I will be sure to pack this to my next camping trip and see how it performs.

Note: This project is a collaboration of me and MatejHantabal. He did mainly the design and I did the electronics.

Parts

_DSC0024.JPG
s-l500.jpg
sku_378845_1.jpg
970-01.jpg
transistor-bc327-pnp-pack-of-5.jpg
sku_463381_5.jpg
terminal.jpg

For this project, you'll need the following components:

3W RGB star LED

digispark ATTINY85

ULN2803

BC327

3x 18650 battery

holder for 3 18650 li-ion batteries

3x black 12mm push buttons

perfboard

PCB screw terminals

3x 1K resistors

some M4 nuts and bolts

couple of wires

Estimated project cost: 40€/45$

Tools

_DSC0064.JPG

For this project, you will need the following tools:

3D Printer - This will print the top of the cube

Laser Cutter - This will cut the bottom of the cube from plexiglass

Soldering Iron - To connect the electronics

Hot Glue Gun - The glue will hold all the electronics and the case together

3D Printing

_DSC0033.JPG
_DSC0036.JPG

First of all, let's print the top. You can use any sort of filament that you like for this, as long as light can pass through. We used transparent PLA-D. We used Prusa i3 MK2 to print this part. The print file is included in this step.

Downloads

Cutting the Case

_DSC0029.JPG

You'll need to use a laser cutter to make the case. We used GCC SLS 80. If you don't have acces to a laser cutter there are many local services, that you can give these vector graphics to, and they will cut it to you for affordable price. You can use any material for this. We cut this from acrylic but anything will work fine and make for an interesting combination with the light. All needed files are included in this step.

Note: This case was drawn for 3mm (1/8") thick material. Make sure that you have this thickness.

Perf-board Circuit

THE CUBE schematic.png
_DSC0055.JPG
_DSC0048.JPG
_DSC0051.JPG

Because the driver circuit for the cube includes many electronic components such as transistors, resistors and one integrated circuit, I decided to go with a perfboard instead of breadboard or screw terminals. You just need to solder all the necessary components on the perfboard according to the included scheme. I used PCB screw terminals to connect the board to the battery and to the RGB LED.

Power

_DSC0061.JPG
_DSC0056.JPG

Because we use a 3W RGB LED that draws around 0.7A at full power we need pretty strong batteries to power this device. We decided to use three 18650 3.7 2600 mAh li-ion batteries. They're a bit heavier and bigger than li-po batteries but they're a bit cheaper toothey fit in the case too. You'll need to make a battery pack. The best option is to use battery spot welder but since they're pretty expensive we decided to just glue three 18650 battery holders together and connect them in parallel. We used 5.5/2.1mm DC barrel as charging connector but you can use any other connector. Just keep in mind that the adapter that you will be plugging into this connector has to have 5V 2A output.

Now let's do some simple maths. The total battery pack capacity should be around 7800 mAh. There is step-up voltage converter at the output of the battery pack that triples the output voltage from 4V to 12V. This voltage conversion should lower the battery pack maximum output current to 2600 mAh. Now, the circuit draws around 700 mA and 2600 mAh divided by 700 mA is 3,7. That gives us a total battery life around 3 and 3/4 hours. But keep in mind that this works just in theory and the real battery life is just around 3 hours. The battery pack should be charged afrer about 3 hours. You can still have it connected to power and don't have it battery powered.

Code

Here is the code for the Attiny85. You can upload it using Arduino IDE.

Downloads

Putting It All Together

_DSC0087.JPG
_DSC0098.JPG
_DSC0110.JPG
_DSC0106.JPG

Get the bottom of the box ready, and we can start putting electronics inside. We put the Li-ION batteries on the very bottom. Of course you can put the stuff anywhere you'd like, but this worked the best for us. Now start putting the sides in their place. Put the button into the front piece and the DC barrel into the side. You can start putting hot glue on the inside to hold the sides and batteries in. Lastly, we slide the 3D printed top into the "hole" in the top of the case.

Done

IMG_20181213_191443.png
IMG_9804.jpg
IMG_9790.jpg
The cube 1.0 360° video

So there you have it, a portable, versatile and elegant RGB lamp. If you followed through all the steps, you should have it compled by now. If you have any questions or suggestions, we would be happy to hear them in the comment section below. Enjoy!

If you liked this instructable, please vote for it in the Make it Glow Contest. Thanks.