summaryrefslogtreecommitdiff
path: root/keyboards
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
parentb8cb147573b39f5c613569d19e8a9ed4f6252676 (diff)
[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')
-rw-r--r--keyboards/4pplet/waffling60/keymaps/default/keymap.c6
-rw-r--r--keyboards/4pplet/waffling60/keymaps/via/keymap.c26
-rw-r--r--keyboards/4pplet/waffling60/rev_b/rev_b.c19
-rw-r--r--keyboards/4pplet/waffling60/rev_b/rev_b.h5
-rw-r--r--keyboards/4pplet/waffling60/rev_c/rev_c.c15
-rw-r--r--keyboards/4pplet/waffling60/rev_c/rev_c.h5
6 files changed, 39 insertions, 37 deletions
diff --git a/keyboards/4pplet/waffling60/keymaps/default/keymap.c b/keyboards/4pplet/waffling60/keymaps/default/keymap.c
index c9ae421af1..b60a7154d7 100644
--- a/keyboards/4pplet/waffling60/keymaps/default/keymap.c
+++ b/keyboards/4pplet/waffling60/keymaps/default/keymap.c
@@ -20,9 +20,9 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// main layer
[0] = LAYOUT_all(
KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_NO, KC_BSPC,
- KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS,
- KC_LCTRL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT,
- KC_LSFT, KC_NO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_NO,
+ KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS,
+ KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT,
+ KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, MO(1),
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, KC_RGUI, KC_APP, MO(1)),
// basic function layer
[1] = LAYOUT_all(
diff --git a/keyboards/4pplet/waffling60/keymaps/via/keymap.c b/keyboards/4pplet/waffling60/keymaps/via/keymap.c
index d20c6bf06c..3e20ef9f56 100644
--- a/keyboards/4pplet/waffling60/keymaps/via/keymap.c
+++ b/keyboards/4pplet/waffling60/keymaps/via/keymap.c
@@ -19,10 +19,10 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
// main layer
[0] = LAYOUT_all(
- KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_NO, KC_BSPC,
- KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS,
- KC_LCTRL, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT,
- KC_LSFT, KC_NO, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_NO,
+ KC_ESC, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSLS, KC_BSPC,
+ KC_TAB, KC_Q, KC_W, KC_E, KC_R, KC_T, KC_Y, KC_U, KC_I, KC_O, KC_P, KC_LBRC, KC_RBRC, KC_BSLS,
+ KC_CAPS, KC_A, KC_S, KC_D, KC_F, KC_G, KC_H, KC_J, KC_K, KC_L, KC_SCLN, KC_QUOT, KC_ENT,
+ KC_LSFT, KC_NUBS, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, MO(1),
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, KC_RGUI, KC_APP, MO(1)),
// basic function layer
[1] = LAYOUT_all(
@@ -33,16 +33,16 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
// extra layer for VIA
[2] = LAYOUT_all(
- KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
- KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
- KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
- KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
// extra layer for VIA
[3] = LAYOUT_all(
- KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
- KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
- KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
- KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
+ KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS,
KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS)
-}; \ No newline at end of file
+};
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"
diff --git a/keyboards/4pplet/waffling60/rev_c/rev_c.c b/keyboards/4pplet/waffling60/rev_c/rev_c.c
index f00cce06dc..fc7e99b601 100644
--- a/keyboards/4pplet/waffling60/rev_c/rev_c.c
+++ b/keyboards/4pplet/waffling60/rev_c/rev_c.c
@@ -19,12 +19,15 @@ 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 && res) {
- if (led_state.caps_lock){
- rgblight_enable();
- rgblight_mode(1);
- rgblight_sethsv_noeeprom(CAPS_LOCK_COLOR);
- } else {
- rgblight_disable_noeeprom();
+ 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_c/rev_c.h b/keyboards/4pplet/waffling60/rev_c/rev_c.h
index 3df9419eb9..701098df1f 100644
--- a/keyboards/4pplet/waffling60/rev_c/rev_c.h
+++ b/keyboards/4pplet/waffling60/rev_c/rev_c.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"