Skip to content

Commit

Permalink
Add missing LED Matrix suspend code to suspend.c (#12878)
Browse files Browse the repository at this point in the history
Co-authored-by: Ryan <fauxpark@gmail.com>
drashna and fauxpark authored May 13, 2021

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
1 parent d200e3d commit da0c551
Showing 2 changed files with 15 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tmk_core/common/avr/suspend.c
Original file line number Diff line number Diff line change
@@ -163,6 +163,9 @@ void suspend_power_down(void) {
rgblight_suspend();
# endif

# if defined(LED_MATRIX_ENABLE)
led_matrix_set_suspend_state(true);
# endif
# if defined(RGB_MATRIX_ENABLE)
rgb_matrix_set_suspend_state(true);
# endif
@@ -218,6 +221,10 @@ void suspend_wakeup_init(void) {
#if defined(RGBLIGHT_SLEEP) && defined(RGBLIGHT_ENABLE)
rgblight_wakeup();
#endif

#if defined(LED_MATRIX_ENABLE)
led_matrix_set_suspend_state(false);
#endif
#if defined(RGB_MATRIX_ENABLE)
rgb_matrix_set_suspend_state(false);
#endif
8 changes: 8 additions & 0 deletions tmk_core/common/chibios/suspend.c
Original file line number Diff line number Diff line change
@@ -83,6 +83,10 @@ void suspend_power_down(void) {
#if defined(RGBLIGHT_SLEEP) && defined(RGBLIGHT_ENABLE)
rgblight_suspend();
#endif

#if defined(LED_MATRIX_ENABLE)
led_matrix_set_suspend_state(true);
#endif
#if defined(RGB_MATRIX_ENABLE)
rgb_matrix_set_suspend_state(true);
#endif
@@ -154,6 +158,10 @@ void suspend_wakeup_init(void) {
#if defined(RGBLIGHT_SLEEP) && defined(RGBLIGHT_ENABLE)
rgblight_wakeup();
#endif

#if defined(LED_MATRIX_ENABLE)
led_matrix_set_suspend_state(false);
#endif
#if defined(RGB_MATRIX_ENABLE)
rgb_matrix_set_suspend_state(false);
#endif

0 comments on commit da0c551

Please sign in to comment.