Basic WS2812b Strip, whys this happening....

Hello, I’m new, i tried to find an answer for this to no avail.

here’s the deal, using the FirstLight example with the FastLeds library, i have a strip of ws2812b LEDs, 26 leds long. The basic goal was just to make it cycle thru lighting them up one at a time as the program normally does.

here’s what happens…

here’s the code:

// Use if you want to force the software SPI subsystem to be used for some reason (generally, you don't)
// Use if you want to force non-accelerated pin access (hint: you really don't, it breaks lots of things)
#include "FastLED.h"

// Move a white dot along the strip of leds.  This program simply shows how to configure the leds,
// and then how to turn a single pixel white and then off, moving down the line of pixels.

// How many leds are in the strip?
#define NUM_LEDS 26

// Data pin that led data will be written out over
#define DATA_PIN 4

// Clock pin only needed for SPI based chipsets when not using hardware SPI
//#define CLOCK_PIN 8

// This is an array of leds.  One item for each led in your strip.

// This function sets up the ledsand tells the controller about them
void setup() {
 // sanity check delay - allows reprogramming if accidently blowing power w/leds

      // Uncomment one of the following lines for your leds arrangement.
      // FastLED.addLeds<TM1803, DATA_PIN, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<TM1804, DATA_PIN, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<TM1809, DATA_PIN, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<WS2811, DATA_PIN, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<WS2812, DATA_PIN, RGB>(leds, NUM_LEDS);
       FastLED.addLeds<WS2812B, DATA_PIN, GRB>(leds, NUM_LEDS);
      // FastLED.addLeds<NEOPIXEL, DATA_PIN>(leds, NUM_LEDS);
      // FastLED.addLeds<APA104, DATA_PIN>(leds, NUM_LEDS);
      // FastLED.addLeds<WS2811_400, DATA_PIN, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<GW6205, DATA_PIN, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<GW6205_400, DATA_PIN, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<UCS1903, DATA_PIN, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<UCS1903B, DATA_PIN, RGB>(leds, NUM_LEDS);

      // FastLED.addLeds<WS2801, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<SM16716, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<LPD8806, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<P9813, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<APA102, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<DOTSTAR, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<WS2801, DATA_PIN, CLOCK_PIN, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<SM16716, DATA_PIN, CLOCK_PIN, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<LPD8806, DATA_PIN, CLOCK_PIN, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<P9813, DATA_PIN, CLOCK_PIN, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<APA102, DATA_PIN, CLOCK_PIN, RGB>(leds, NUM_LEDS);
      // FastLED.addLeds<DOTSTAR, DATA_PIN, CLOCK_PIN, RGB>(leds, NUM_LEDS);

// This function runs over and over, and is where you do the magic to light
// your leds.
void loop() {
   // Move a single white led 
   for(int whiteLed = 0; whiteLed < NUM_LEDS; whiteLed = whiteLed + 1) {
      // Turn our current led on to white, then show the leds
      leds[whiteLed] = CRGB::White;

      // Show the leds (only one of which is set to white, from above);

      // Wait a little bit

      // Turn our current led back to black for the next loop around
      leds[whiteLed] = CRGB::Black;

I am powering the strip wth a 5v/1.5AMP wall wart. the data pin on pin 4, as recommended to me, has a resistor on it. this happens with or without the resistor (a 390 ohm resistor)

im hoping its just something stupid, would love any input.

thank you in advance and i appologize is this is something thats been beaten to death and i couldnt find it thru search.


Have you got the capacitor across the supply and the resistor in line with the data line?

i currently have a 390ohm resistor on the data pin, and a 2200uF capacitor (10v) on the power, with proper polarity.

seemed as tho, at one point if i were to squeeze the connection where the wires were soldered, it'd function properly. i have since removed the LED at the begining of that string and soldered the wires to the next one down the way and its still all wonky and erratic.

i got this strip vs individual LEDs because this is going to be lighting up a xmas candy cane (actually 5 of them, in total) and dindt want to solder all the LEDs together. im beginning to think i made a wrong choice here. :/

at one point if i were to squeeze the connection where the wires were soldered, it'd function properly.

That must be it, there must be an intermittent connection somewhere. How are you connecting the wires to the Arduino, have you a well focused photo of it?

no photo at the moment, i can get one. the original leads from the strip with the 3 pin connector are soldered on to the contacts of the first LED in the strip, then i have into that a male male breadboard connector wire (whatever you wanna call it), going to the arduino uno or nano (with same results)

You need to solder wire onto a pin header and insert that into the Arduino header. You can not just push wires into the Arduino, it is not good enough.