Driving a LED Neopixel strip with Electron specifically

Guys,

Anybody drive a Neopixel strip with a Electron specifically? I’m no hardware guru so I have some questions:

  • Can I drive the strip with the Electron’s vUSB since (I think) it’s 5v?
  • I assume I’ll need a 1000 uF 6.3 cap parallel with the vUSB and Gnd?
  • Will need a series resistor between a digitial pin and the DIN of the strip? Like 330ohms +?
  • Will the existing libraries work with the Electron? I read on an old topic that the libraries only support Photon & Core
  • Lastly, the strip uses 5050 LEDs … is that like the WS2812b?

Sorry for all the questions. And thanks for any info.

Tahl

1 Like

Can I drive the strip with the Electron's vUSB since (I think) it's 5v?

Yes, but I would limit that to 1A worth of neopixels (1A/0.06A = about 16 pixels full white). If you want more pixels, it's recommended to tie the GND's together and power the strip independently from the Electron. It's also recommended to use a 5V level shifter on the 3.3V output of the Electron, but you can get away without them. YMMV (Your Mileage May Vary). See the Neopixel library headers for info on parts.

I assume I'll need a 1000 uF 6.3 cap parallel with the vUSB and Gnd?

Recommended, yes.

Will need a series resistor between a digitial pin and the DIN of the strip? Like 330ohms +?

Recommended, yes. 220 or 100 can work well too. The trick is not to round off the square wave too much at the neopixel DIN with respect to GND, but enough that you don't get nasty overshoot voltages.

Will the existing libraries work with the Electron? I read on an old topic that the libraries only support Photon & Core

Yep! Supports Core, Photon, P1, Electron, RedBear Duo.

Lastly, the strip uses 5050 LEDs ... is that like the WS2812b?

Most likely, especially if you bought them from Adafruit.com.


EDIT:

1 Like

@BDub thanks for the fast and thoughtful response.

Yes, I looked at the idea of using a level shifter for about 0.01 seconds ;-). Too complicated for me! Since I’m driving the 8 LED Neopixel strip, the vUSB for power should be enough current-wise. In terms of signal level, hopefully the 3.3v that comes out of the DIO bit will be enough to show a “1”. I’ll use smallish resistor.

In terms of a capacitor, it’s been a zillion years since electronics class. Seems like I would use an electrolytic cap or does it matter? I’m hoping to use something I have sitting around as long as it’s 1000 uF+ and 6.3v+.

Best,
Tahl

For 8 pixels, if you are going to keep the wiring short I’d say you don’t need a big 'ol 1000uF electrolytic, but you can add it if you wish. It’s probably not so good for your USB power source to add such large capacitors without an in-rush current limiter as well. It’s a little bit like short circuiting your USB plug. The cap is mainly needed when you are driving a BUNCH of pixels. You’ll be fine without the level shifter, I do typically drive small pixel projects without them… it’s just harder to guarantee it will work :wink:

Thanks. I’ll give it a try.

The 5050 indicates the size of the LED, which in this case is 5mm x 5mm. As such, it doesn't have anything to do with the kind of LEDS you're using. They could be ws2812(b), apa102, sk6812, or plain old analog rgb LEDs. There are other sizes available as well, most commonly the 3528, though the new SK6812 minis are using 3535.

2 Likes