From 3a9b6157d07d07a1766dc895d7351d74599b7c04 Mon Sep 17 00:00:00 2001 From: David Madison Date: Wed, 21 Dec 2016 11:19:03 -0500 Subject: [PATCH] Separated and cleaned settings area --- .../LEDstream_WS2812B/LEDstream_WS2812B.ino | 24 ++++++++++++------- 1 file changed, 15 insertions(+), 9 deletions(-) diff --git a/Arduino/LEDstream_WS2812B/LEDstream_WS2812B.ino b/Arduino/LEDstream_WS2812B/LEDstream_WS2812B.ino index 917a814..099b7e1 100644 --- a/Arduino/LEDstream_WS2812B/LEDstream_WS2812B.ino +++ b/Arduino/LEDstream_WS2812B/LEDstream_WS2812B.ino @@ -1,19 +1,25 @@ // Slightly modified Adalight protocol implementation that uses FastLED // library (http://fastled.io) for driving WS2811/WS2812 led strip -#include +#include -#define NUM_LEDS 80 // strip length -#define LED_PIN 6 // Arduino data output pin -#define BRIGHTNESS 255 // maximum brightness -#define SPEED 115200 // serial port speed, max available +// -------------------------------------------------------------------- -//#define GROUND_PIN 10 // additional grounding pin (optional) +// -- General Settings +#define NUM_LEDS 80 // strip length +#define LED_PIN 6 // Arduino data output pin +#define BRIGHTNESS 255 // maximum brightness + +// --- Serial Settings +#define SPEED 115200 // serial port speed, max available +static const unsigned long // time before LEDs are shut off, if no data + serialTimeout = 150000; // 150 seconds + +// -- Optional Settings (Uncomment to add) +//#define GROUND_PIN 10 // additional grounding pin (optional) //#define CALIBRATE // uncomment to set calibration mode -// If no serial data is received for a while, the LEDs are shut off -// automatically. Value in milliseconds. -static const unsigned long serialTimeout = 150000; // 150 seconds +// -------------------------------------------------------------------- CRGB leds[NUM_LEDS]; uint8_t * ledsRaw = (uint8_t *)leds;