Beruflich Dokumente
Kultur Dokumente
Cube
Tutorial45 Arduino Projects
An Anduino LED Cube is a fantastic project; it can be used as a
decoration piece or used with other equipment like
microphones or motion sensors for various applications.
Basically an LED cube is a 3 dimensional cube made out of
Light Emitting Diodes (LEDs). The Cube can be made in various
ways but for this project, a simple setup is used that is
controlled by an Arduino Uno microcontroller.
All the negative pins of the LEDs are treated as columns of this
matrix cube. So we have 4 layers and 16 columns that make it
20 wires connected to the Arduino. The positive pins (layers)
have 100 Ohm resistors to limit the current flow to 20mA (the
standard current for an LED).
Working
The microcontroller – in our case an Arduino Uno – has current
sourcing limitation on its output pins i.e. it can only deliver a
safe amount of current before damage occurs. In the Arduino
Uno’s case, it is 40mA. So you must be wondering, wait a
minute, if an LED takes 20mA, how come we can turn on all
the lights at the same time and still not burn the Arduino
board? This is because at any given time, only a single LED is
on.
List of Components:
1. Cardboard or wood (about 1 inch thick)
2. 3V Button Cell
3. Sandpaper (medium grade)
4. 64 x Blue Light Emitting Diodes (LEDs)
5. 4 x 100 Ohm Resistors
6. 24 x Male-Male Coloured Ribbon Wires
7. 1 x Female Pin Socket/Header (should have 20 pin
sockets inline)
8. PCB Perfboard (about 24×10 cm)
9. Arduino Uno + USB Cable
10. Arduino Uno power socket adapter
11. 9V Batter adapter
12. 9V Battery
13. Zip-tie (25 cm)
14. Glue Gun + Glue Stick
15. Soldering Iron + Soldering Wire + Wet Foam
16. Desoldering Pump (incase soldering is bad)
17. Magnifying glass (to see your soldering)
18. Mini Wire Cutter
19. Mini Nose Plier
20. Connection wire for under PCB wiring (about 1m) and
sticky tape
How to Build
First of all, you will need a moderately thick cardboard or wood
(about an inch will do). Drill holes into it so that it forms a 4×4
cube pattern with equal distances between all holes.
In this case, a printed pattern was placed on top of the
cardboard and 5mm holes (each hole is 2.4cm from the next
one (centre-centre) were drilled for the LEDs. In the picture
below, you can see arrows that point to the direction of LED
legs; we will look at this later.
Now, you have to test and prepare your LEDs. You can use a
3V button cell for this purpose. Test all the LEDs so that you
avoid any trouble later!
If you want light coming out of all sides of the LED, you may
diffuse them by rubbing their plastic shell with sandpaper.
In the image below, the LED on the left is diffused and the one
on the right is in its original transparent form. Check the
difference!
Get your stuff ready for soldering. Line up the LED army and
get ready for some bending and soldering.
Remember, that the short leg of an LED is its Cathode (-ive pin)
and the long leg is Anode (+ive pin). If you are not sure, then
you can test it with a multimeter or a button cell to find the
polarity. Now, using nose pliers bend the cathode (short leg) at
90o angle to the right and then again bend it upwards to make
the shape as shown in the image below.
Now cut all the extra pieces so that it is neat and tidy like the
image below:
After making four layers, you should get ready for the mega
soldering job!
In this project, simple cardboard pieces were cut and placed
between the layers to be soldered. This makes it easy to
solder them but you can always use other tools such as PCB
holders etc.
After soldering three layers, it’s a good idea to check all the
LEDs once again just in case. As before, connect the positive
pin of your button cell tester to the layer and then negative pin
to all the LED columns (-ive pins) one by one.
Looks like we found a bugger! Just cut the faulty LED’s legs as
short as you can and replace it with another one, but be
careful about the bending and lengths of both pins so that it
adjusts in the cube while maintaining integrity of the structure
as well.
Finally, the LED cube is soldered and this is how it should look
like:
Solder a 20 pin (or more) inline female header (0.1 inch gap
between pins) onto a readymade perfboard PCB and place the
Cube on it (column pins). You may temporarily bend some legs
of the LED cube under the board so that it doesn’t fall off but
don’t solder them yet. They will be soldered with the wires
coming from the female header pins later.
For Columns:
1,1 13
1,2 12
1,3 11
1,4 10
2,1 9
2,2 8
2,3 7
2,4 6
3,1 5
3,2 4
3,3 3
3,4 2
4,1 1
4,2 0
4,3 A5
4,4 A6
For Layers:
0 A0
1 A1
2 A2
3 A3
Finally, hardware is done. This is how your project may look
like:
After uploading the code onto the Arduino Uno, your 4x4x4 LED
Cube is ready!
More On
A Selection of the Best Arduino Simulators
The advantages of simulating real-time events have been the
bedrock …