Hi,
I have noticed some issues by controlling leds
I have a matrix of leds 9*7, see the pic bellow
Here is the code i'm executing.
#include <FastLED.h>
//TEENSY 2.0 PINS
#define DATA_PIN 2
#define CLOCK_PIN 1
#define NUM_LEDS 63
CRGB leds[NUM_LEDS];
void led_set_color_strip( int Red, int Green, int Blue )
{
int i;
for ( i=0 ; i<NUM_LEDS ; i+=1)
{
leds[i] = CRGB( Red, Green, Blue), delay(100), FastLED.show();
leds[i] = CRGB( Red, Green, Blue) , FastLED.clear();
}
}
void setup()
{
// put your setup code here, to run once:
FastLED.addLeds<WS2801, RBG>(leds, NUM_LEDS);
led_set_color_strip(0,0,255);
}
void loop()
{
// put your main code here, to run repeatedly:
}
I go throught all led, turning them on then off one by one. Working.
Now if i want all the led to be turned on at the same times, will not work. Colors are not respected, it flashes, and not all the leds are lighted up, it stops like half the way maybe less, depends in matter fact, its pretty random.
#include <FastLED.h>
//TEENSY 2.0 PINS
#define DATA_PIN 2
#define CLOCK_PIN 1
#define NUM_LEDS 63
CRGB leds[NUM_LEDS];
void led_set_color_strip( int Red, int Green, int Blue )
{
int i;
for ( i=0 ; i<NUM_LEDS ; i+=1)
{
leds[i] = CRGB( Red, Green, Blue), delay(100), FastLED.show();
//leds[i] = CRGB( Red, Green, Blue) , FastLED.clear();
}
}
void setup()
{
// put your setup code here, to run once:
FastLED.addLeds<WS2801, RBG>(leds, NUM_LEDS);
led_set_color_strip(0,0,255);
}
void loop()
{
// put your main code here, to run repeatedly:
}
What do you think the problem could be ?
-The PSU is 5V 8A so should manage 63 LEDS easy.
-Wiring problem
Kind regards.