|
|
@ -104,6 +104,7 @@ namespace KaleidoscopePlugins {
|
|
|
|
enum {
|
|
|
|
enum {
|
|
|
|
PALETTE,
|
|
|
|
PALETTE,
|
|
|
|
TOGGLE,
|
|
|
|
TOGGLE,
|
|
|
|
|
|
|
|
CLEAR,
|
|
|
|
} subCommand;
|
|
|
|
} subCommand;
|
|
|
|
|
|
|
|
|
|
|
|
if (strncmp_P (command, PSTR ("fingerpainter."), 14) != 0)
|
|
|
|
if (strncmp_P (command, PSTR ("fingerpainter."), 14) != 0)
|
|
|
@ -113,6 +114,8 @@ namespace KaleidoscopePlugins {
|
|
|
|
subCommand = PALETTE;
|
|
|
|
subCommand = PALETTE;
|
|
|
|
else if (strcmp_P (command + 14, PSTR ("toggle")) == 0)
|
|
|
|
else if (strcmp_P (command + 14, PSTR ("toggle")) == 0)
|
|
|
|
subCommand = TOGGLE;
|
|
|
|
subCommand = TOGGLE;
|
|
|
|
|
|
|
|
else if (strcmp_P (command + 14, PSTR ("clear")) == 0)
|
|
|
|
|
|
|
|
subCommand = CLEAR;
|
|
|
|
else
|
|
|
|
else
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
|
|
|
|
|
|
|
@ -122,6 +125,13 @@ namespace KaleidoscopePlugins {
|
|
|
|
return true;
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (subCommand == CLEAR) {
|
|
|
|
|
|
|
|
for (uint16_t i = 0; i < ROWS * COLS; i++) {
|
|
|
|
|
|
|
|
EEPROM.update (colorBase + i, 0);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
return true;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (Serial.peek () == '\n') {
|
|
|
|
if (Serial.peek () == '\n') {
|
|
|
|
for (uint8_t i = 0; i < 16; i++) {
|
|
|
|
for (uint8_t i = 0; i < 16; i++) {
|
|
|
|
cRGB color;
|
|
|
|
cRGB color;
|
|
|
|