From 36c410592dbd35da33ccc5fd6d2a5cbf4b25a708 Mon Sep 17 00:00:00 2001 From: Ryan Date: Fri, 23 Sep 2022 22:46:23 +1000 Subject: Change `DRIVER_LED_COUNT` to `{LED,RGB}_MATRIX_LED_COUNT` (#18399) --- keyboards/opendeck/32/rev1/config.h | 2 +- keyboards/opendeck/32/rev1/rev1.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'keyboards/opendeck/32') diff --git a/keyboards/opendeck/32/rev1/config.h b/keyboards/opendeck/32/rev1/config.h index 6a87ad86b4..87b153c736 100644 --- a/keyboards/opendeck/32/rev1/config.h +++ b/keyboards/opendeck/32/rev1/config.h @@ -29,7 +29,7 @@ // RGB matrix #define DRIVER_ADDR_1 0b1110100 #define DRIVER_COUNT 1 -#define DRIVER_LED_TOTAL (4 * 8 * 3) +#define RGB_MATRIX_LED_COUNT (4 * 8 * 3) #define RGB_DISABLE_WHEN_USB_SUSPENDED #define RGB_MATRIX_STARTUP_MODE RGB_MATRIX_CYCLE_SPIRAL #define RGB_MATRIX_DISABLE_KEYCODES diff --git a/keyboards/opendeck/32/rev1/rev1.c b/keyboards/opendeck/32/rev1/rev1.c index 332dc3cc40..be50d91944 100644 --- a/keyboards/opendeck/32/rev1/rev1.c +++ b/keyboards/opendeck/32/rev1/rev1.c @@ -17,7 +17,7 @@ #include "rev1.h" #ifdef RGB_MATRIX_ENABLE -const is31_led PROGMEM g_is31_leds[DRIVER_LED_TOTAL] = { +const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { /* Refer to IS31 manual for these locations * driver * | R location -- cgit v1.2.3 From 64b1ed45507a15d5594b1f90b936c2096918f5a4 Mon Sep 17 00:00:00 2001 From: Drashna Jaelre Date: Tue, 4 Oct 2022 15:24:22 -0700 Subject: Fix Per Key LED Indicator Callbacks (#18450) Co-authored-by: Dasky <32983009+daskygit@users.noreply.github.com> Co-authored-by: Nick Brassel --- keyboards/opendeck/32/rev1/rev1.c | 10 ---------- 1 file changed, 10 deletions(-) (limited to 'keyboards/opendeck/32') diff --git a/keyboards/opendeck/32/rev1/rev1.c b/keyboards/opendeck/32/rev1/rev1.c index be50d91944..34862873d0 100644 --- a/keyboards/opendeck/32/rev1/rev1.c +++ b/keyboards/opendeck/32/rev1/rev1.c @@ -87,16 +87,6 @@ led_config_t g_led_config = { // clang-format on -// Set custom key colors here, in order to change the RGB effect, either reserve some keys -// in the keymap to adjust the pattern (see QMK docs, incompatible with wrapper keys) or -// change the default pattern in config.h. -/* -void rgb_matrix_indicators_kb(void) { - //rgb_matrix_set_color(0, 255, 255, 255); - //rgb_matrix_set_color_all(0x86,0xff,0xff); -} -*/ - void keyboard_pre_init_kb(void) { // Light power LED setPinOutput(POWER_LED_PIN); -- cgit v1.2.3 From 20ed138236a88c8b1fc3924f4b883618f6e01920 Mon Sep 17 00:00:00 2001 From: Ryan Date: Fri, 11 Nov 2022 12:15:19 +1100 Subject: LED config fixes (#18973) --- keyboards/opendeck/32/rev1/rev1.c | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) (limited to 'keyboards/opendeck/32') diff --git a/keyboards/opendeck/32/rev1/rev1.c b/keyboards/opendeck/32/rev1/rev1.c index 34862873d0..b803682b7d 100644 --- a/keyboards/opendeck/32/rev1/rev1.c +++ b/keyboards/opendeck/32/rev1/rev1.c @@ -63,27 +63,28 @@ const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { // clang-format on }; -#define P(x,y) {(x*224 / (MATRIX_COLS - 1)), (y*64 / (MATRIX_ROWS - 1))} // clang-format off led_config_t g_led_config = { - // Key Matrix to LED Index { - {0, 1, 2, 3, 4, 5, 6, 7}, - {8, 9, 10, 11, 12, 13, 14, 15}, - {16, 17, 18, 19, 20, 21, 22, 23}, - {24, 25, 26, 27, 28, 29, 30, 31} + // Key Matrix to LED Index + { 0, 1, 2, 3, 4, 5, 6, 7 }, + { 8, 9, 10, 11, 12, 13, 14, 15 }, + { 16, 17, 18, 19, 20, 21, 22, 23 }, + { 24, 25, 26, 27, 28, 29, 30, 31 } }, { // LED Index to Physical Position - P(0, 0), P(1, 0), P(2, 0), P(3, 0), P(4, 0), P(5, 0), P(6, 0), P(7, 0), - P(0, 1), P(1, 1), P(2, 1), P(3, 1), P(4, 1), P(5, 1), P(6, 1), P(7, 1), - P(0, 2), P(1, 2), P(2, 2), P(3, 2), P(4, 2), P(5, 2), P(6, 2), P(7, 2), - P(0, 3), P(1, 3), P(2, 3), P(3, 3), P(4, 3), P(5, 3), P(6, 3), P(7, 3), + { 0, 0 }, { 32, 0 }, { 64, 0 }, { 96, 0 }, { 128, 0 }, { 160, 0 }, { 192, 0 }, { 224, 0 }, + { 0, 21 }, { 32, 21 }, { 64, 21 }, { 96, 21 }, { 128, 21 }, { 160, 21 }, { 192, 21 }, { 224, 21 }, + { 0, 43 }, { 32, 43 }, { 64, 43 }, { 96, 43 }, { 128, 43 }, { 160, 43 }, { 192, 43 }, { 224, 43 }, + { 0, 64 }, { 32, 64 }, { 64, 64 }, { 96, 64 }, { 128, 64 }, { 160, 64 }, { 192, 64 }, { 224, 64 } }, { // LED Index to Flag - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4 + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4 } }; -#undef P // clang-format on @@ -112,7 +113,7 @@ void keyboard_post_init_user() { static uint8_t g_key_wrapper_tracker = 0; bool process_record_kb(uint16_t keycode, keyrecord_t *record) { - if (!process_record_user(keycode, record) { return false; } + if (!process_record_user(keycode, record)) { return false; } if (record->event.pressed && keycode != KC_WRAPPER_KEY) { register_code(KC_WRAPPER_KEY); register_code(keycode); -- cgit v1.2.3 From e12ca14af8fc1799357bbfffd156d53b4a51001c Mon Sep 17 00:00:00 2001 From: Ryan Date: Sun, 27 Nov 2022 04:18:24 +1100 Subject: Change `RGB_MATRIX_STARTUP_*` defines to `RGB_MATRIX_DEFAULT_*` (#19079) --- keyboards/opendeck/32/rev1/config.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'keyboards/opendeck/32') diff --git a/keyboards/opendeck/32/rev1/config.h b/keyboards/opendeck/32/rev1/config.h index 87b153c736..ba07576ee2 100644 --- a/keyboards/opendeck/32/rev1/config.h +++ b/keyboards/opendeck/32/rev1/config.h @@ -31,7 +31,7 @@ #define DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT (4 * 8 * 3) #define RGB_DISABLE_WHEN_USB_SUSPENDED -#define RGB_MATRIX_STARTUP_MODE RGB_MATRIX_CYCLE_SPIRAL +#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_SPIRAL #define RGB_MATRIX_DISABLE_KEYCODES // RGB Matrix Animation modes. Explicitly enabled // For full list of effects, see: -- cgit v1.2.3