Re: Adafruit HUZZAH ESP8266 breakout - driving NeoPixel stri
by adafruit_support_mike on Sat Dec 01, 2018 2:03 am
You probably won't need a 1000uF capacitor for a strip that short.
The capacitor's job is to reduce voltage spikes that happen when the NeoPixel LEDs turn on and off. Each pixel only creates a small spike on its own, but if you add the spikes from 50 or 60 pixels together, you get something big enough to cause trouble.
For future reference, the only capacitors in that value will be electrolytic, and yes, it's important to connect the positive lead of an electrolytic cap to the positive voltage. If you reverse the connections, the cap can explode.
Electrolytic capacitors are made from two layers of aluminum foil with a layer of paper soaked in a conductive liquid (the 'electrolyte') between them. One layer of foil has direct contact with the electrolyte, and the electrolyte takes the same voltage as that piece of foil. The other piece of foil has tiny pits etched in its surface, giving it a lot of surface area, and the etched surface has a very thin layer of non-conductive insulation between the foil and the electrolyte. High-value capacitors need plates with a lot of surface area and a thin conductive layer between them, and the electrolytic structure does that. The etched foil is one plate, and the electrolyte is the other plate.
If there are any holes in the insulating oxide layer, current will flow from the electrolyte to the foil at those points. The electrolyte is also a plating medium though, so the current flowing into exposed foil will automatically pull molecules that create an oxide layer to the gaps in the insulation, closing them.
If you reverse the connections, connecting negative voltage to the etched layer, the plating process will work the other way, stripping the insulating layer away from the foil, and creating regions of bare foil where current can flow. The current heats up the electrolyte, and when it gets hot enough, the water in the electrolyte will turn to steam. If the current creates an arc (several thousand degrees), the electrolyte flashes to steam quickly, and the aluminum can around the foil turns into a bomb.
Electrolytic cans have score marks that should make the can fail at known and relatively safe points, but that doesn't stop an exploding cap from being exciting. They have about the same explosive force as bullets or shotgun shells.
Coming back to your project, you'll want to connect the NeoPixel strip's positive supply rail to the 5V terminal of the USB power supply instead of the ESP8266 breakout's 3V pin.
First, the breakout's 3.3V regulator is made to handle 600mA. That's enough to handle the ESP8266's 500mA burst current, but doesn't leave enough extra current for a NeoPixel strip. Second, and probably more important, the blue LEDs in a NeoPixel strip can't light up from a 3.3V supply. The LEDs themselves need about 3.3V, and then there's some additional voltage for the switch and current regulator.
A NeoPixel strip connected to 5V power won't cause any problems for a 3.3V ESP8266 though. The first pixel's data-in pin isn't connected to the pixel's 5V supply, so it won't damage the ESP8266's GPIO pin. Technically the NeoPixels will want 5V data signals, but we've found that our strips tend to accept 3.3V data signals without any trouble.