#include <Adafruit_NeoPixel.h>
const byte neoPin = 5;
const byte numPixels = 32;
Adafruit_NeoPixel pixels(numPixels, neoPin, NEO_GRB + NEO_KHZ800);
const uint32_t couleurs[] = {
0x0000FF, 0x0000FF, 0x0000FF, 0x0000FF, // 4 en bleu
0x00FF00, 0x00FF00, 0x00FF00, 0x00FF00, // 4 en vert
0xFF0000, 0xFF0000, 0xFF0000, 0xFF0000, // 4 en rouge
0xFF00FF, 0xFF00FF, 0xFF00FF, 0xFF00FF, // 4 en rouge+bleu = violet
0x00FFFF, 0x00FFFF, 0x00FFFF, 0x00FFFF, // 4 en vert+bleu = turquoise
0xFFFF00, 0xFFFF00, 0xFFFF00, 0xFFFF00, // 4 en rouge+vert = jaune
0x000000, 0x000000, 0x000000, 0x000000, // 4 en noir
0xFFFFFF, 0xFFFFFF, 0xFFFFFF, 0xFFFFFF, // 4 en rouge+vert/bleu = blanc
};
void setup() {
Serial.begin(115200);
pixels.begin();
pixels.setBrightness(255); // Set BRIGHTNESS to about 1/5 (max = 255)
pixels.clear();
pixels.show();
for (byte i = 0; i < numPixels; i++) pixels.setPixelColor(i, couleurs[i]);
pixels.show();
}
void loop() {}