DC power input circuit making NeoPixel LED strip go haywire

Imgur: The magic of the Internet (Schematic)
Imgur: The magic of the Internet (Breadboard)

I have a NeoPixel strip with 105 pixels...I'm testing the above circuit on my breadboard to power the strip before I get a PCB made for a much larger project (images attached are my schematic & pic of the breadboard w/ components).

Components pictured (left to right):

1N4001 - rectifier diode
100uF electrolytic capacitor
LM7805 - 5 Volt regulator
10uF capacitor
1000uF capacitor (as suggested in the NeoPixel Uberguide)

(Not pictured - the wire I have going from the NeoPixel data line into pin #6 on my Arduino Uno)

I'm using a 5V 3000mA DC power adapter -- But no matter what 5V adapter I use, the strip just starts going crazy flashing at random, random variations of colors. Even when using the Adafruit example sketches w/ Arduino (strandtest, simple)

Can anyone figure out what I'm doing wrong here?

Post a link to the Adafruit code.

This is the "simple" NeoPixel sketch...But the LEDs go crazy no matter what sketch I upload to the Uno

// NeoPixel Ring simple sketch (c) 2013 Shae Erisson
// released under the GPLv3 license to match the rest of the AdaFruit NeoPixel library

#include <Adafruit_NeoPixel.h>
#ifdef __AVR__
  #include <avr/power.h>
#endif

// Which pin on the Arduino is connected to the NeoPixels?
// On a Trinket or Gemma we suggest changing this to 1
#define PIN            6

// How many NeoPixels are attached to the Arduino?
#define NUMPIXELS      105

// When we setup the NeoPixel library, we tell it how many pixels, and which pin to use to send signals.
// Note that for older NeoPixel strips you might need to change the third parameter--see the strandtest
// example for more information on possible values.
Adafruit_NeoPixel pixels = Adafruit_NeoPixel(NUMPIXELS, PIN, NEO_GRB + NEO_KHZ800);

int delayval = 500; // delay for half a second

void setup() {
  // This is for Trinket 5V 16MHz, you can remove these three lines if you are not using a Trinket
#if defined (__AVR_ATtiny85__)
  if (F_CPU == 16000000) clock_prescale_set(clock_div_1);
#endif
  // End of trinket special code

  pixels.begin(); // This initializes the NeoPixel library.
}

void loop() {

  // For a set of NeoPixels the first NeoPixel is 0, second is 1, all the way up to the count of pixels minus one.

  for(int i=0;i<NUMPIXELS;i++){

    // pixels.Color takes RGB values, from 0,0,0 up to 255,255,255
    pixels.setPixelColor(i, pixels.Color(0,150,0)); // Moderately bright green color.

    pixels.show(); // This sends the updated pixel color to the hardware.

    delay(delayval); // Delay for a period of time (in milliseconds).

  }
}

You need a 100nF cap on the input of the regulator to GND (close to the terminals).
You need a minimum of ~8v on the left side of the breadboard.
You need a common GND to the strip and Arduino.

.

Why are you using a 5volt linear regulator (that needs 7volt to work).

And power that regulator with a 5volt/3Amp supply.

You will have 3.5volt at the output of the regulator at best, and it could run stinking hot.

Post a link/picture of that supply (or of the sticker on the supply).
Leo..

Did you MEASURE the input voltage to the Neopixel ?

Thanks LarryD, the problem I was the lack of common GND & the input voltage.

Wawa - I'm using a 3000mA power adapter with variable voltage (i cranked the voltage up to 9.5) because I will eventually be upscaling this project to include 300+ LEDs. This is from the Adafruit NeoPixel guide:

Each individual NeoPixel draws up to 60 milliamps at maximum brightness...

To estimate power supply needs, multiply the number of pixels by 20, then divide the result by 1,000 for the “rule of thumb” power supply rating in Amps. Or use 60 (instead of 20) if you want to guarantee an absolute margin of safety for all situations. For example:

60 NeoPixels × 20 mA ÷ 1,000 = 1.2 Amps minimum
60 NeoPixels × 60 mA ÷ 1,000 = 3.6 Amps minimum

Even though I'm only using 105 NeoPixels at the moment, I might need even more amperage down the line to run 300+ LEDs, correct?

And you're right about the regulator running hot, is a heat-sink the answer that that?

9.5volt - 0.7volt(the diode) - 5volt(regulator output) = 3.8volt across the regulator.

With 300 LEDs at full brightness (18Amp), 3.8*18= 68.4watt has to be dissipated in the regulator.
That's the size of a beefy computer CPU cooler with 12cm fan on full.

Apart from that, the 7805 regulator (with heatsink) and the diode can't handle more than ~1Amp (15 NeoPixels).

Forget about linear supplies.
You need a 5volt/20Amp switching supply for 300 NeoPixels.
Leo..

I've actually got all 105 NeoPixels running at full brightness now... Thanks for the advice, I'm sure if I lower the brightness to say 100 (or less) instead of 255 I could run a lot more of them. Full brightness at 255 is almost painfully bright anyway.

Adafruit sells a 5V 10A switching power supply that they recommend for running a "couple hundred NeoPixels or more"...

(From the NeoPixel guide)

Adafruit offers 5V DC power supplies up to 10 Amps. This is usually sufficient for a couple hundred NeoPixels or more.

Link to the power supply

Would this be the solution if I also lower the brightness of the NeoPixels?

Yes, that is a switching power supply.
Good for about 150+ NeoPixels at full brightness, and more if you reduce the brightness of one or more colours.
Leo..