If you're new to soldering headers, check out this handy How to Solder Headers guide for some tips.
Place the headers included with the QT Py short side-up into a solderless breadboard. Solder the QT Py face-up on top of the headers.
Pull the QT Py out and sandwich the BFF on the back of the board, with the USB port and battery port facing the same way and the boards back-to-back.Â
Solder the headers in place on the BFF. I find it easiest to tape the QT Py to the table to hold it still for this process.
DO NOT TRIM THE HEADER LEGS YET.
First, find the +5v pin on the QT Py. This is the pin we need to connect to in order to power our pixels safely. We've just made this harder by soldering headers into the through-holes, but we can still connect to the pin if we solder a wire to the remaining header leg.Â
I trimmed all the other legs so they're short and out of the way, but left this one long to give myself something to solder to in the next step.
Which Wire is Which?
Take a look at your NeoPixel strand. It ships with a male connector on one end an a female on the other, but it's a long strand so we're going to cut it into pieces. You can cut between any of the LEDs and the strand will continue working. The tricky bits are 1. figuring out which wire is which, and 2. soldering to those short pesky wires.
Look closely at the wires and you'll also see that one of the wires is marked -- it has tiny dots / stripes all along the length. This is the power (+5v) wire. It's soldered to the red wire on your connector. The black wire is on the far side and is connected to G, leaving the middle wire (green) as the data wire.Â
NeoPixel strips and strands are directional. There is a data IN end and a data OUT end. The red and black wires could connect at either end, or somewhere in the middle, and the strip will work fine, but that data wire must be connected at IN end or the pixels won't light up.
There's no industry standard for which connector comes on the IN end. Some strands of pixels have male on the IN, some have female. This is kind of annoying, since it means we've got a 50/50 chance of guessing right.Â
Cut your LED strand right behind one of the pixels to give yourself as much wire to work with as possible. Separate the 3 wires. This is harder than it seems: these wires are solidly stuck together. I found it easiest to use a pair of flush cutters to carefully snip in between the 3 wires. These are easily one of my favorite tools!Â
Then, use a good pair of wire strippers to strip about 1/4 of shielding off all three wires.Â
Prep your Stemma QT connector also. Trim the yellow and red wires to get them out of the way. We're just using the blue and black for this project -- but if you wanted to add sensors or a microphone, these wires are available for such things.
Next, you'll want to confirm which wire is which before soldering. Grab your alligator clips. Connect the wire with the copper coil to the +5v header pin, the blue Stemma QT wire to the middle wire, and the black Stemma QT wire to the remaining wire.
Make sure nothing's shorting (the clips aren't touching each other) and connect the QT Py to power. You can use either the USB port or the JST battery port. If you've got it right, the lights will come on.Â
If you've got lights, go ahead and solder up the connections. Splice the two wires to the Stemma QT connector together. For the red 5v wire, strip about 1/2" of shielding and slide on a small piece of heat shrink. Wind the bare wire around the header pin a few times as best you can, and solder it in place. Tug gently on it -- the physical connection should be such that it doesn't pop right off. Cover with your heat shrink.
Splice the black and blue wires from the Stemma QT connector to the corresponding wires on the LED strip and plug the stemma connector into the QT Py.
Troubleshooting
If your lights didn't come on, here are a few things to try:
- Flip the on/off switch on the BFF. Was it just turned off?
- Head back to WLED and check your pinout configuration under LED Preferences. Be sure you've told WLED that we are using pin 22 (blue wire.. check the pinout)
- Check your wiring! Be sure you soldered to the IN end of the LED strip. These strips can be inconsistent so this is a pretty common problem. Use an alligator clip to try the data wire on the other end.
- Try re-uploading the WLED software.Â
- If the lights come on but you can't control them, make sure you're on the correct WiFi network - if you're on a different network you won't see the WLED connection.
Color Order
Normally when WLED first boots up, the default is a warm yellow light color. But our lights didn't boot up in yellow.. they booted up in blue. What gives?
Open the WLED interface (open snowcrown.local or whatever you named your project in a browser window). Choose "solid" as your effect and red as your color from the color picker.Â
If your lights come on in any color other than red, your color order is set incorrectly. This is an easy fix. Head to the LED settings tab and find the Hardware Setup section (this is where you set up your pin number earlier). Choose BRG from the dropdown, click save, and see if your pixel colors match your color picker now. If not, try another combo until the lights look correct.
FYI: This can be a problem when mixing different types of strips or strands. Normally you can solder together any kind of NeoPixels as long as you match the pins and get the data order right. But if the color order is different on one of the strands, there's no way to tell WLED to treat the different parts of the strand differently.Â
You can solder different strands to up to 3 pins, and you can control the color order independently on each pin with WLED. It's only a problem if you try to connect a different type of pixels to the end of this strand.
Text editor powered by tinymce.