89inline Sequencer classicEndgameSeq(classicEgPhases, 3);
90inline void classicEgActivate(LedStrand& s) { classicEndgameSeq.start(s); }
91inline void classicEgTick (LedStrand& s) { classicEndgameSeq.update(s); }
95 {
"Showoff", 15,
showoff,
nullptr},
101 {
"Endgame", 100, classicEgActivate, classicEgTick},
119inline void modernRed (LedStrand& s) { s.pulse(0xFF0000, 14, 1, 0xFF6200); }
120inline void modernBlue (LedStrand& s) { s.pulse(0x0000FF, 14, 1, 0x009DFF); }
121inline void modernScore (LedStrand& s) { s.flash(0x11FF00, 100, 100); }
122inline void modernMatchloader (LedStrand& s) { s.pulse(0xEED202, 5, 1); }
123inline void modernEgGreen (LedStrand& s) { s.setColor(0x11FF00); }
124inline void modernEgPulse (LedStrand& s) { s.pulse(0x11FF00, 8, 2); }
126inline const Sequencer::Phase modernEgPhases[] = {
127 {15000, modernEgGreen},
128 {4000, modernEgPulse},
130inline Sequencer modernEndgameSeq(modernEgPhases, 2);
131inline void modernEgActivate(LedStrand& s) { modernEndgameSeq.start(s); }
132inline void modernEgTick (LedStrand& s) { modernEndgameSeq.update(s); }
136 {
"Showoff", 15,
showoff,
nullptr},
137 {
"Idle", 10, modernIdle,
nullptr},
138 {
"Red", 20, modernRed,
nullptr},
139 {
"Blue", 20, modernBlue,
nullptr},
140 {
"Scoring", 70, modernScore,
nullptr},
141 {
"Matchloading", 90, modernMatchloader,
nullptr},
142 {
"Endgame", 100, modernEgActivate, modernEgTick},
158inline void showyIdle (
LedStrand& s) { s.
flow(0xAC00FF, 0x000000, 1); }
159inline void showyRed (LedStrand& s) { s.pulse(0xFFFFFF, 4, 1, 0xFF0000); }
160inline void showyBlue (LedStrand& s) { s.pulse(0xFFFFFF, 4, 1, 0x0000FF); }
161inline void showyScore (LedStrand& s) { s.pulse(0x00FF88, 6, 2); }
162inline void showyEgPulse (LedStrand& s) { s.pulse(0xFFFF00, 6, 1); }
163inline void showyEgRainbow (LedStrand& s) { s.rainbow(2); }
165inline const Sequencer::Phase showyEgPhases[] = {
166 {2000, showyEgPulse},
167 {8000, showyEgRainbow},
169inline Sequencer showyEndgameSeq(showyEgPhases, 2);
170inline void showyEgActivate(LedStrand& s) { showyEndgameSeq.start(s); }
171inline void showyEgTick (LedStrand& s) { showyEndgameSeq.update(s); }
175 {
"Idle", 10, showyIdle,
nullptr},
176 {
"Red", 20, showyRed,
nullptr},
177 {
"Blue", 20, showyBlue,
nullptr},
178 {
"Scoring", 90, showyScore,
nullptr},
179 {
"Endgame", 100, showyEgActivate, showyEgTick},
Driver for a single WS2812B-compatible LED strip on a VEX ADI port.
Definition led_strand.hpp:53
void flow(uint32_t color1, uint32_t color2, Speed speed, bool invert=false, bool seamless=true)
Scroll a two-color gradient across the strip.
void flash(uint32_t color, uint32_t onMs, uint32_t offMs, uint32_t bgColor=0x000000)
Blink the whole strip on and off.
void rainbow(Speed speed)
Scroll a full HSV rainbow across the strip.
void setColor(uint32_t color)
Set all LEDs to a solid color.
void pulse(uint32_t color, uint8_t runLength, Speed speed, uint32_t bgColor=0x000000, bool invert=false, bool bounce=false)
Animate a run of color moving across a background.
const ProfileMode showyModes[]
Definition classic.hpp:174
void classicRed(LedStrand &s)
Definition classic.hpp:72
void classicEgCycle(LedStrand &s)
Definition classic.hpp:80
void classicIdle(LedStrand &s)
Definition classic.hpp:71
void classicScore(LedStrand &s)
Definition classic.hpp:74
const Profile modern
Modern profile instance.
Definition classic.hpp:151
const Profile classic
Classic profile instance.
Definition classic.hpp:111
void showoff(LedStrand &s)
Definition classic.hpp:76
const ProfileMode modernModes[]
Definition classic.hpp:135
void classicEgWarn(LedStrand &s)
Definition classic.hpp:78
const ProfileMode classicModes[]
Definition classic.hpp:94
const Profile showy
Showy profile instance.
Definition classic.hpp:188
void classicEgWhite(LedStrand &s)
Definition classic.hpp:79
void classicMatchloader(LedStrand &s)
Definition classic.hpp:75
void classicBlue(LedStrand &s)
Definition classic.hpp:73
Profile and mode descriptors for the hitlib event-driven animation system.
Multi-phase timed animation sequencer.
Single addressable LED strip driver with layered animation engine.
Definition classic.hpp:56
Describes a single named animation mode within a Profile.
Definition led_profile.hpp:38
An immutable, statically-allocated collection of ProfileMode entries.
Definition led_profile.hpp:68
One phase in the animation sequence.
Definition led_sequencer.hpp:59