From f2ada47ca5f0ff6fed2fad76b3fc6c1010467bb8 Mon Sep 17 00:00:00 2001 From: Noah Date: Sun, 17 Dec 2017 23:23:07 -0800 Subject: [PATCH] hue rotation effect on all LEDs --- RGBShades.ino | 3 ++- effects.h | 12 ++++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/RGBShades.ino b/RGBShades.ino index 5583378..69c80c5 100644 --- a/RGBShades.ino +++ b/RGBShades.ino @@ -56,7 +56,8 @@ void setup() { } // list of functions that will be displayed -functionList effectList[] = {threeSine, +functionList effectList[] = {hueRotation, + threeSine, threeDee, scrollTextOne, plasma, diff --git a/effects.h b/effects.h index 6140c2a..1770f71 100644 --- a/effects.h +++ b/effects.h @@ -6,6 +6,18 @@ // * All animation should be controlled with counters and effectDelay, no delay() or loops // * Pixel data should be written using leds[XY(x,y)] to map coordinates to the RGB Shades layout +// Hue Rotation +void hueRotation() { + + // startup tasks + if (effectInit == false) { + effectInit = true; + effectDelay = 60; + } + + fillAll(CHSV(cycleHue, 255, 255)); +} + // Triple Sine Waves byte sineOffset = 0; // counter for current position of sine waves void threeSine() {