Reinstall Batteries

Now that we have our LEDs and wiring removed from the handle, we can start sorting out our power situation. Let's start by putting the batteries back in and reinstalling the cover. We're going to use a multimeter to find out where the voltage is coming from.

Switch PCB

Look for the PCB that's next to the speaker. This PCB has the trigger button and slide switch. There is a ribbon cable that connects this PCB to the other PCB where we disconnected the LEDs. Notice how the ground(black) and power(red) wires from the battery holder is connected to the PCB with the switch. 

Measuring Voltage

We'll use the multimeter to find out which wires on the PCB are voltage and ground. Set the DC voltage mode on the Pocket Multimeter. We can use the two probes to determine which wires are voltage and ground. Poke one of the dots or "pins" on the PCB with the tip of the testing leads. Then use the second lead to "probe" another pin. In my energy sword, the pin with the green wire was ground, and the yellow was voltage – This is of course subject to change. The colored wires might be different in your energy sword. The pins, however, should be in the same positions.

Unmount Switch PCB

Since we'll be working with the PCB, I suggest removing it from the handle so we get better access to the pins. It's secured in place with two machine screws. Remove these and lift the PCB out of the handle.

Switch PCB Pinouts

With the PCB free from the handle, we can flip it over and inspect the back. You'll notice some labels, yaay! Each wire has a label (SW, TRY, OFF, VDD, GND). The VDD label is voltage, and GND is ground. We'll connect wires to these pins to power the Trinket micro-controller and NeoPixel LEDs.

Trinket Power

Now that we know where we'll be getting power from, we can start planning where to mount the Trinket micro-controller. Next to the speaker, is an empty spot, perfect for the micro-controller. Place the Trinket in that spot and gauge how long the wires connections need to be.

Power Wires

Let's make some wires for powering the Trinket! Cut two pieces of wires using wire cutters. Make sure they're long enough to connect the switch PCB to the Trinket. I recommend using 30AWG silicone coated wires because they're more flexible and reliable than wire wrap. We'll need two wires, one for voltage, and the other for ground. Then, use wire strippers to remove a bit of insulation from the tips of each wire. It's good practice to tin the tips of exposed stranded wires to prevent fraying.  A pair of helping third hands can assist you while soldering.

Connect Wires to Trinket

On the back of the Trinket are two pads. These are voltage and ground (labeled with a +positive and –negative symbol). We'll need to connect our two wires to them. I recommend tinning the pads with solder to make it easier to attach the wires. I found it better if the wire is positioned outwards from the microUSB port. Again, a pair of helping third hands is nice and well, handy.

Heat Shrink Tubing

I recommend using pieces of heat shrink tubing. They're like sheathing for wires that need insultation. These also help keep the wires nice and tidy. Cut short pieces. They slip over multiple wires and can shrink when heat is applied to it. Tip: Don't use the tip of your soldering. Use the edge of the pen, or a flame from a lighter. Careful not to over heat!

Connect Trinket to Power

Now we can connect the wires from the Trinket to the voltage and ground pins on the switch PCB. I recommend securing the PCB to helping third hands to assist while soldering. You'll need to apply heat to the pins on the PCB in order to connect the wires to them.

Test Power

With voltage and ground connected to the Trinket micro-controller, we can now do a quick test to see if the power works. Temporarily place the switch PCB back into the handle and flip it over. Then, insert the 3x AAA batteries into the holder and turn the switch to power the circuit on. If we have a solid connection (and wired to the correct pins) our Trinket will power on (indicated by a green LED). Woohoo! Next we can start working on hooking up the NeoPixel LEDs.

This guide was first published on Jan 18, 2017. It was last updated on Jan 18, 2017. This page (Power) was last updated on Oct 30, 2019.