hlxldb

LED光立方制作全过程(二十三)

0
阅读(2692)

 

Step 39Build the controller: Transistor array

Build the controller: Transistor array
loading...
i
Build the controller: Transistor array
Build the controller: Transistor array
loading...
 
i
loading...
i
The transistor array is responsible for switching on and off GND for each layer in the LED cube.

Our first attempt at this was an epic fail. We bought some transistors rated for over 500mA, thinking that would be plenty of juice. We don't remember the model number.

The LED cube worked, but it wasn't very bright, and the brightness was inversely proportional to the number of LEDs switched on in any given layer. In addition to that, there was some ghosting. Layers didn't switch completely off when they were supposed to be off.

Needless to say, we were kind of disappointed, and started debugging. The first thing we did was to add pull-up resistors to try to combat the ghosting. This removed almost all the ghosting, yay! But the cube was still very dim, bah!

We didn't have any powerful transistors or MOSFETs lying around, so we had to come up with another solution.

We posted a thread in the electronics section of the AVRFreaks.net forum, asking if it was possible to use two smaller transistors in parallel. This is the only option available to us using the parts we had on hand. The general response was, this will never work so don't even bother trying. They even had valid theories and stuff, but that didn't deter us from trying. It was our only solution that didn't involve waiting for new parts to arrive in the mail.

We ended up trying PN2222A, NPN general purpose amplifier. Ideally, you'd want a switching transistor for this kind of application, but we needed 16 transistors of the same type. This transistor was rated at 1000mA current, so we decided to give it a try.

For each layer, we used two PN2222As in parallel. The collectors connected together to GND. The emitters connected together, then connected to a ground layer. The base of each transistors was connected to it's own resistor, and the two resistors connected to an output pin on the ATmega.

We soldered in all the transistors and turned the thing on again, and it worked, perfectly!

If you know what you are doing, you should probably do some research and find a more suitable transistor or MOSFET. But our solution is tried and tested and also does the trick!

1) Start by placing all 8 all transistors on the PBC and soldering each of their pins.

2) Run a solder trace between the the emitters of all 16 transistors. Connect this solder trace to GND.

3) Solder in a resistor for each transistor, the solder the resistors together in pairs of two.

4) Run kynar wire from the output pins on the ATmega to each of the 8 resistor pairs.

5) Solder together the collectors of the transistors in pairs of two and run solder trace or wire from the collector pairs to an 8 pin header.