Make LED visualization times configurable

master
Fred Sundvik 2016-05-29 17:42:32 +03:00
parent 9c955145f5
commit 0c3189055f
1 changed files with 12 additions and 9 deletions

View File

@ -25,6 +25,9 @@ SOFTWARE.
#include "gfx.h" #include "gfx.h"
#include "math.h" #include "math.h"
#define CROSSFADE_TIME 1000
#define GRADIENT_TIME 3000
keyframe_animation_t led_test_animation = { keyframe_animation_t led_test_animation = {
.num_frames = 14, .num_frames = 14,
.loop = true, .loop = true,
@ -32,17 +35,17 @@ keyframe_animation_t led_test_animation = {
gfxMillisecondsToTicks(1000), // fade in gfxMillisecondsToTicks(1000), // fade in
gfxMillisecondsToTicks(1000), // no op (leds on) gfxMillisecondsToTicks(1000), // no op (leds on)
gfxMillisecondsToTicks(1000), // fade out gfxMillisecondsToTicks(1000), // fade out
gfxMillisecondsToTicks(1000), // crossfade gfxMillisecondsToTicks(CROSSFADE_TIME), // crossfade
gfxMillisecondsToTicks(3000), // left to rigt (outside in) gfxMillisecondsToTicks(GRADIENT_TIME), // left to rigt (outside in)
gfxMillisecondsToTicks(1000), // crossfade gfxMillisecondsToTicks(CROSSFADE_TIME), // crossfade
gfxMillisecondsToTicks(3000), // top_to_bottom gfxMillisecondsToTicks(GRADIENT_TIME), // top_to_bottom
0, // mirror leds 0, // mirror leds
gfxMillisecondsToTicks(1000), // crossfade gfxMillisecondsToTicks(CROSSFADE_TIME), // crossfade
gfxMillisecondsToTicks(3000), // left_to_right (mirrored, so inside out) gfxMillisecondsToTicks(GRADIENT_TIME), // left_to_right (mirrored, so inside out)
gfxMillisecondsToTicks(1000), // crossfade gfxMillisecondsToTicks(CROSSFADE_TIME), // crossfade
gfxMillisecondsToTicks(3000), // top_to_bottom gfxMillisecondsToTicks(GRADIENT_TIME), // top_to_bottom
0, // normal leds 0, // normal leds
gfxMillisecondsToTicks(1000), // crossfade gfxMillisecondsToTicks(CROSSFADE_TIME), // crossfade
}, },
.frame_functions = { .frame_functions = {