add shift_squares animation
This commit is contained in:
parent
0a36308aa9
commit
a9ff478c8e
3 changed files with 7 additions and 2 deletions
|
|
@ -15,7 +15,7 @@ void setup() {
|
|||
lastState = -1;
|
||||
|
||||
// how many secconds until the animation is told to progress
|
||||
animationMax = 10;
|
||||
animationMax = 90;
|
||||
}
|
||||
|
||||
void loop() {
|
||||
|
|
@ -34,6 +34,10 @@ void loop() {
|
|||
tunnel();
|
||||
break;
|
||||
|
||||
case SHIFTSQUARES:
|
||||
shift_squares();
|
||||
break;
|
||||
|
||||
case RAINBOWCORNER:
|
||||
rainbow_corner();
|
||||
break;
|
||||
|
|
|
|||
1
config.h
1
config.h
|
|
@ -5,6 +5,7 @@ typedef enum STATE {
|
|||
CHASETHEDOT,
|
||||
RAINBOWRANDOM,
|
||||
TUNNEL,
|
||||
SHIFTSQUARES,
|
||||
RAINBOWCORNER,
|
||||
PLANARFLOP3D
|
||||
};
|
||||
|
|
|
|||
|
|
@ -582,7 +582,7 @@ int currentTimer = 0;
|
|||
int maxTimer = 6250; // 100ms delay / 16uS interrupt time
|
||||
|
||||
int nextState(int state) {
|
||||
return (state + 1) % 3;
|
||||
return (state + 1) % 4;
|
||||
}
|
||||
|
||||
// the interrupt function to display the leds (T2 = 8 bit timer)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue