Merge pull request #24 from keyboardio/f/focus-readcolor

Use Focus.readColor in the focusHook
pull/365/head
Jesse Vincent 6 years ago committed by GitHub
commit 279ac89ca6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -194,9 +194,7 @@ bool LEDControl::focusHook(const char *command) {
} else {
cRGB c;
c.r = Serial.parseInt();
c.g = Serial.parseInt();
c.b = Serial.parseInt();
::Focus.readColor(c);
setCrgbAt(idx, c);
}
@ -205,9 +203,7 @@ bool LEDControl::focusHook(const char *command) {
case SETALL: {
cRGB c;
c.r = Serial.parseInt();
c.g = Serial.parseInt();
c.b = Serial.parseInt();
::Focus.readColor(c);
set_all_leds_to(c);
@ -246,9 +242,7 @@ bool LEDControl::focusHook(const char *command) {
while (idx < LED_COUNT && Serial.peek() != '\n') {
cRGB color;
color.r = Serial.parseInt();
color.g = Serial.parseInt();
color.b = Serial.parseInt();
::Focus.readColor(color);
setCrgbAt(idx, color);
idx++;

Loading…
Cancel
Save