Need some help - all turns green
Hi guys! I’ve just started to work with neopixels for my latest project: I have a hexacopter and I would like to have on each arm one of These neopixel-stripes with 8 leds. The first step was to have simple positioning light: 2 of them green, two of them red and two of them White. So I set up 6 arrays, connected them to Pins 7-12 on my Aduino Nano uploaded my simple code:
#include “FastLED.h”
#define NUM_LEDS_PER_STRIP 8
CRGB VRleds[NUM_LEDS_PER_STRIP];
CRGB RRleds[NUM_LEDS_PER_STRIP];
CRGB HRleds[NUM_LEDS_PER_STRIP];
CRGB HLleds[NUM_LEDS_PER_STRIP];
CRGB LLleds[NUM_LEDS_PER_STRIP];
CRGB VLleds[NUM_LEDS_PER_STRIP];
void setup() {
FastLED.addLeds<NEOPIXEL, 7>(VRleds, NUM_LEDS_PER_STRIP);
FastLED.addLeds<NEOPIXEL, 8>(RRleds, NUM_LEDS_PER_STRIP);
FastLED.addLeds<NEOPIXEL, 9>(HRleds, NUM_LEDS_PER_STRIP);
FastLED.addLeds<NEOPIXEL, 10>(HLleds, NUM_LEDS_PER_STRIP);
FastLED.addLeds<NEOPIXEL, 11>(LLleds, NUM_LEDS_PER_STRIP);
FastLED.addLeds<NEOPIXEL, 12>(VLleds, NUM_LEDS_PER_STRIP);
FastLED.setBrightness(32);
}
void loop() {
for(int i = 0; i < NUM_LEDS_PER_STRIP; i++) {
VRleds[i] = CRGB::Green;
RRleds[i] = CRGB::Green;
HRleds[i] = CRGB::White;
HLleds[i] = CRGB::White;
LLleds[i] = CRGB::Red;
VLleds[i] = CRGB::Red;
FastLED.show();
delay(100);
}
}
Now there is a mystery for me: if I comment (“turn off”) two of the six arrays all is wokring fine. But as soon as I upload the sketch with all six arrays “engaged” all of them turn green! Has anyone had such a behaviour before? Is there any limitation I am not Aware about? Tested different Pins as well as an 2560 base aduino without any sucess. I am running out of ideas…