A friend had approached me about helping to complete a cosplay project in short order. It was to be a backpack for a cyborg character, with some lighting effects. Normally I’d decline, but there were NeoPixels involved. I’m sure you understand.
The electronic parts — most from Adafruit — included:
- Nickel-metal hydride (NiMH) cells: forget to pack your charger and you’re out of commission. Someone “helps” by putting alkaline cells in your 4-cell holder and fries your 5V electronics (four NiMH=4.8V, alkaline=6V).
- USB power bank: most will automatically shut off when connected to a low-current circuit. Also, USB plugs do not latch strongly and they stick way out.
- Lithium-polymer (LiPo) cells: Somewhat fragile, potentially flammable. Because cosplay can limit vision and mobility, and because costume materials are sometimes themselves flammable, adding an incendiary device to the mix really scares me. Also the pack-the-charger problem again. A USB charge circuit can be built in, but this adds cost and complexity to something you only use a few times a year.
Alkalines may not be “sexy” but they’re ubiquitous and cheap (unless purchased in a hotel gift shop, don’t do that). You can travel light and buy them at your destination. And no probing from the TSA.
(I’m not saying to never use other varieties…all have a place in portable projects…just that this route is beginner-friendly and is affordable. The alkaline battery holder is four bucks!)
So this circuit has 16 regular-size (two 7-pixel Jewels, two Flora pixels) and 60 mini NeoPixels. Doing The Math to estimate a worst-case current use for all these pixels:
16 × 60 + 60 × 35 = 3060 mA
Three amps! Consider, your typical alkaline AA cell has a capacity around 2,500 mA…so this would run for less than an hour, assuming the battery could even deliver that kind of current (no…they fare best under one Amp, the lower the better).
Switching out batteries all day is no fun. Cosplay is powered by caffeine, adrenaline and foolishness and ideally should go on for hours. Time to put all those strategies to use…
I did not actually plan everything out and budget for power, instead just running with power-saving approaches I’ve internalized from prior projects. Basically, the more “off” the pixels — the more “spaces between the notes,” the better. I had a hunch that four or possibly five hours’ run time could be achieved…
Graphing the brightness of the “vacuum tubes” — there’s two big ones up top, and two smaller ones on the side — these could have simply been lit solid purple and call it done, but I added sine waves to both (except for the one red pixel at the center)…partly to make it more visually interesting, partly to save power. For the NeoPixel jewel, each pixel is 60 degrees out of phase along the wave.
The smaller tubes never go to full brightness, it just wasn’t necessary and looked more “balanced” with the large ones.
These graphs aren’t very precise, they’re just to give an impression of what the software is calculating. Also, these are the perceived brightness levels before gamma correction. The actual duty cycle assigned to the LEDs is a fraction of this!
The hoses are even more subdued. Though the Mini Skinny NeoPixels are already somewhat dimmer than the full-sized variety, the brightness was further turned way down on these. Power saving, of course, but also because I didn’t want the LEDs to be overly distracting and upstage the rest of the costume.
The compulsion to run a rainbow cycle on NeoPixel strips is a force of nature. But again, so as not to overpower the rest of the suit (which is mostly muted colors), the palette was kept toward the cyan side of things. Think of early computer graphics, with all its garish, overdone colors…the medium gained respectability as artists dialed down the palette toward nature.
Rather than just sine-waving pure cyan, there are two waves slightly out of phase, so you see pulses of green-cyan-blue travel down the line. It really looks as though there’s some purple mixed in as well, but this is just a reflection of the vacuum tubes.
Again the graph is before gamma correction is applied. The actual “on” time of any of these LEDs is tiny.
I’d hoped for a five hour run time. Nothing too scientific, just gut feeling with the LED count and the numbers I was using in the code. The actual run time for this project was sixteen hours from three AA batteries! So all those NeoPixels are sipping a mere 160 milliamps (~2,500 ÷ 16), not the 500 mA I’d guesstimated. Even with the secondary colors, it’s getting a 19-fold improvement over the crude rule-of-thumb estimate. You can make cool stuff work with modest batteries! If space and weight were at a premium, I probably could even have run this from AAA cells (about half the capacity of AA’s).
Think about that for a moment: in terms of average, overall duty cycle, the LEDs are off something like 95% of the time. We just notice all the motion and colors.
This “Guggenhat” project with hundreds of NeoPixels also does its job just fine with lowly AA batteries.