Activity › Forums › Questions & Troubleshooting › Neopixel and Controllino
-
Neopixel and Controllino
-
Hi there,
I am a little confused.
I want to control neopixels. Everything works with the Arduino MEGA 2560. But when I use the same program with Conntrollino MAXI, unfortunately no LED flashes. What am I doing wrong?
I have included a sample code:
#include <Controllino.h>
#include <Adafruit_NeoPixel.h>
#define PIN CONTROLLINO_D0
#define NUMPIXELS 40
Adafruit_NeoPixel pixels = Adafruit_NeoPixel(NUMPIXELS, PIN, NEO_GRB + NEO_KHZ800);
int pause=100;
void setup() {
pixels.begin();
}
void loop() {
pixels.setPixelColor(1, pixels.Color(0,255,0)); // Pixel1 leuchtet in der Farbe Grün
pixels.show();
delay (pause);
pixels.setPixelColor(2, pixels.Color(0,150,0));
pixels.show();
delay (pause);
pixels.setPixelColor(3, pixels.Color(0,50,0));
pixels.show();
delay (pause);
pixels.setPixelColor(4, pixels.Color(0,10,0));
pixels.show();
delay (pause);
pixels.setPixelColor(5, pixels.Color(0,1,0));
pixels.show();
delay (pause);
pixels.setPixelColor(1, pixels.Color(0,0,0));
pixels.setPixelColor(2, pixels.Color(0,0,0));
pixels.setPixelColor(3, pixels.Color(0,0,0));
pixels.setPixelColor(4, pixels.Color(0,0,0));
pixels.setPixelColor(5, pixels.Color(0,0,0));
pixels.show();
delay (pause);
}
-
Hi, do you have any progress so far?
Have you connected the stripe to the pin header? And interconnected the GND of CONTROLLINO and external 5V power supply?
Thanks,
Lukas
Log in to reply.