summaryrefslogtreecommitdiff
path: root/keyboards/4pplet/waffling60/rev_b
diff options
context:
space:
mode:
author4pplet <mail@4pplet.com>2022-04-13 16:11:19 +0200
committerGitHub <noreply@github.com>2022-04-13 07:11:19 -0700
commitcf152dd16bb8a0bc1aba3d98f307303d96799fa7 (patch)
tree65ebef57159f1e85fff814ddc02c3e287eed2dab /keyboards/4pplet/waffling60/rev_b
parentb8cb147573b39f5c613569d19e8a9ed4f6252676 (diff)
downloadqmk_firmware-cf152dd16bb8a0bc1aba3d98f307303d96799fa7.tar.gz
qmk_firmware-cf152dd16bb8a0bc1aba3d98f307303d96799fa7.zip
[Keyboard] Waffling60 - minor tweak, improve default behavior of caps lock indicator. (#16836)
Co-authored-by: Drashna Jaelre <drashna@live.com> Co-authored-by: 4pplet <4pplet@protonmail.com> Co-authored-by: 4pplet <stefan.ess@gmail.com>
Diffstat (limited to 'keyboards/4pplet/waffling60/rev_b')
-rw-r--r--keyboards/4pplet/waffling60/rev_b/rev_b.c19
-rw-r--r--keyboards/4pplet/waffling60/rev_b/rev_b.h5
2 files changed, 12 insertions, 12 deletions
diff --git a/keyboards/4pplet/waffling60/rev_b/rev_b.c b/keyboards/4pplet/waffling60/rev_b/rev_b.c
index 5f701b57f4..c03f3630e6 100644
--- a/keyboards/4pplet/waffling60/rev_b/rev_b.c
+++ b/keyboards/4pplet/waffling60/rev_b/rev_b.c
@@ -18,15 +18,16 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
bool led_update_kb(led_t led_state) {
bool res = led_update_user(led_state);
- if(CAPS_LOCK_ENABLE){
- if(res) {
- if(led_state.caps_lock){
- rgblight_enable();
- rgblight_mode(1);
- rgblight_sethsv_noeeprom(CAPS_LOCK_COLOR);
- }
- else
- rgblight_disable_noeeprom();
+ if (CAPS_LOCK_ENABLE && res) {
+ if(led_state.caps_lock) {
+ #ifdef CAPS_LOCK_COLOR
+ rgblight_sethsv_at(CAPS_LOCK_COLOR, 0);
+ #else
+ rgblight_sethsv_at(rgblight_get_hue(),rgblight_get_sat(),rgblight_get_val(), 0);
+ #endif
+ }
+ else{
+ rgblight_sethsv_at(HSV_OFF, 0);
}
}
return res;
diff --git a/keyboards/4pplet/waffling60/rev_b/rev_b.h b/keyboards/4pplet/waffling60/rev_b/rev_b.h
index e6dc7a15db..e54e020354 100644
--- a/keyboards/4pplet/waffling60/rev_b/rev_b.h
+++ b/keyboards/4pplet/waffling60/rev_b/rev_b.h
@@ -16,9 +16,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
-// defines to set RGB-led behaviour. Off by default
-#define CAPS_LOCK_ENABLE false
-#define CAPS_LOCK_COLOR HSV_ORANGE
+#define CAPS_LOCK_ENABLE true
+//#define CAPS_LOCK_COLOR HSV_ORANGE
#include "quantum.h"