Skip to content

Commit

Permalink
[Keyboard] Fixup RGB Matrix functionality on Planck EZ (qmk#6099)
Browse files Browse the repository at this point in the history
* [Keyboard] Allow RGB Matrix to be disabled on Planck EZ that don't have LEDs

* Add function calls to enabled/disable rgb matrix on idle/wakeup
  • Loading branch information
drashna authored Jun 24, 2019
1 parent 80a4080 commit 0a2894f
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions keyboards/planck/ez/ez.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
*/
#include "ez.h"

#ifdef RGB_MATRIX_ENABLE
const is31_led g_is31_leds[DRIVER_LED_TOTAL] = {
/* Refer to IS31 manual for these locations
* driver
Expand Down Expand Up @@ -100,6 +101,16 @@ led_config_t g_led_config = { {
1, 1, 1, 1, 1, 4, 1, 1, 1, 1, 1
} };

void suspend_power_down_kb(void) {
rgb_matrix_set_suspend_state(true);
suspend_power_down_user();
}

void suspend_wakeup_init_kb(void) {
rgb_matrix_set_suspend_state(false);
suspend_wakeup_init_user();
}
#endif

void matrix_init_kb(void) {
matrix_init_user();
Expand Down

0 comments on commit 0a2894f

Please sign in to comment.