|
|
|
@ -62,7 +62,7 @@ void Model01::setup(void) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void Model01::led_set_crgb_at(uint8_t i, cRGB crgb) {
|
|
|
|
|
if(i<32) {
|
|
|
|
|
if (i<32) {
|
|
|
|
|
cRGB oldColor = led_get_crgb_at(i);
|
|
|
|
|
isLEDChanged |= !(oldColor.r == crgb.r && oldColor.g == crgb.g && oldColor.b == crgb.b);
|
|
|
|
|
|
|
|
|
@ -87,7 +87,7 @@ uint8_t Model01::get_led_index(byte row, byte col) {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
cRGB Model01::led_get_crgb_at(uint8_t i) {
|
|
|
|
|
if(i<32) {
|
|
|
|
|
if (i<32) {
|
|
|
|
|
return leftHand.ledData.leds[i];
|
|
|
|
|
} else if (i<64) {
|
|
|
|
|
return rightHand.ledData.leds[i-32] ;
|
|
|
|
@ -124,7 +124,7 @@ boolean Model01::led_power_fault() {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void debug_keyswitch_event(keydata_t state, keydata_t previousState, uint8_t keynum, uint8_t row, uint8_t col) {
|
|
|
|
|
if (bitRead(state.all, keynum) != bitRead(previousState.all, keynum )) {
|
|
|
|
|
if (bitRead(state.all, keynum) != bitRead(previousState.all, keynum)) {
|
|
|
|
|
Serial.print("Looking at row ");
|
|
|
|
|
Serial.print(row);
|
|
|
|
|
Serial.print(", col ");
|
|
|
|
@ -134,7 +134,7 @@ void debug_keyswitch_event(keydata_t state, keydata_t previousState, uint8_t key
|
|
|
|
|
Serial.print(" ");
|
|
|
|
|
Serial.print(bitRead(previousState.all, keynum));
|
|
|
|
|
Serial.print(" -> ");
|
|
|
|
|
Serial.print(bitRead(state.all, keynum ));
|
|
|
|
|
Serial.print(bitRead(state.all, keynum));
|
|
|
|
|
Serial.println();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|