summaryrefslogtreecommitdiff
path: root/keyboards/wuque
diff options
context:
space:
mode:
Diffstat (limited to 'keyboards/wuque')
-rw-r--r--keyboards/wuque/creek70/config.h5
-rw-r--r--keyboards/wuque/creek70/info.json6
-rw-r--r--keyboards/wuque/ikki68/config.h5
-rw-r--r--keyboards/wuque/ikki68/info.json6
-rw-r--r--keyboards/wuque/ikki68_aurora/config.h5
-rw-r--r--keyboards/wuque/ikki68_aurora/info.json6
-rw-r--r--keyboards/wuque/mammoth20x/config.h4
-rw-r--r--keyboards/wuque/mammoth20x/info.json2
-rw-r--r--keyboards/wuque/mammoth20x/keymaps/default/keymap.c4
-rw-r--r--keyboards/wuque/mammoth20x/keymaps/via/keymap.c17
-rw-r--r--keyboards/wuque/mammoth20x/keymaps/via/rules.mk1
-rw-r--r--keyboards/wuque/mammoth20x/mammoth20x.c62
-rw-r--r--keyboards/wuque/mammoth75x/config.h4
-rw-r--r--keyboards/wuque/mammoth75x/info.json3
-rw-r--r--keyboards/wuque/mammoth75x/keymaps/default/keymap.c4
-rw-r--r--keyboards/wuque/mammoth75x/keymaps/via/keymap.c17
-rw-r--r--keyboards/wuque/mammoth75x/keymaps/via/rules.mk1
-rw-r--r--keyboards/wuque/mammoth75x/mammoth75x.c64
-rw-r--r--keyboards/wuque/promise87/ansi/config.h5
-rw-r--r--keyboards/wuque/promise87/ansi/info.json6
-rw-r--r--keyboards/wuque/promise87/wkl/config.h5
-rw-r--r--keyboards/wuque/promise87/wkl/info.json6
-rw-r--r--keyboards/wuque/serneity65/config.h21
-rw-r--r--keyboards/wuque/serneity65/info.json2
-rw-r--r--keyboards/wuque/serneity65/keymaps/default/keymap.c8
-rw-r--r--keyboards/wuque/serneity65/keymaps/via/keymap.c17
-rw-r--r--keyboards/wuque/serneity65/keymaps/via/rules.mk3
-rw-r--r--keyboards/wuque/serneity65/serneity65.c64
28 files changed, 76 insertions, 277 deletions
diff --git a/keyboards/wuque/creek70/config.h b/keyboards/wuque/creek70/config.h
index d33ee006aa..59b7a1b79a 100644
--- a/keyboards/wuque/creek70/config.h
+++ b/keyboards/wuque/creek70/config.h
@@ -16,11 +16,6 @@
#pragma once
-# define RGBLED_NUM 7
-# define RGBLIGHT_HUE_STEP 8
-# define RGBLIGHT_SAT_STEP 8
-# define RGBLIGHT_VAL_STEP 8
-# define RGBLIGHT_SLEEP
# define RGBLIGHT_EFFECT_BREATHING
# define RGBLIGHT_EFFECT_RAINBOW_MOOD
# define RGBLIGHT_EFFECT_RAINBOW_SWIRL
diff --git a/keyboards/wuque/creek70/info.json b/keyboards/wuque/creek70/info.json
index 10e43b340d..7f55fa28d2 100644
--- a/keyboards/wuque/creek70/info.json
+++ b/keyboards/wuque/creek70/info.json
@@ -30,7 +30,11 @@
"pin": "D0"
},
"rgblight": {
- "max_brightness": 200
+ "saturation_steps": 8,
+ "brightness_steps": 8,
+ "led_count": 7,
+ "max_brightness": 200,
+ "sleep": true
},
"layout_aliases": {
"LAYOUT": "LAYOUT_all"
diff --git a/keyboards/wuque/ikki68/config.h b/keyboards/wuque/ikki68/config.h
index 80ecfb420d..2adc1bc9cf 100644
--- a/keyboards/wuque/ikki68/config.h
+++ b/keyboards/wuque/ikki68/config.h
@@ -23,11 +23,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
/* Locking resynchronize hack */
#define LOCKING_RESYNC_ENABLE
- #define RGBLED_NUM 8
- #define RGBLIGHT_HUE_STEP 8
- #define RGBLIGHT_SAT_STEP 8
- #define RGBLIGHT_VAL_STEP 8
- #define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */
/*======= RGB function=======*/
#define RGBLIGHT_EFFECT_BREATHING
#define RGBLIGHT_EFFECT_RAINBOW_MOOD
diff --git a/keyboards/wuque/ikki68/info.json b/keyboards/wuque/ikki68/info.json
index e450f95dbf..9558b72f1c 100644
--- a/keyboards/wuque/ikki68/info.json
+++ b/keyboards/wuque/ikki68/info.json
@@ -12,7 +12,11 @@
"pin": "E2"
},
"rgblight": {
- "max_brightness": 200
+ "saturation_steps": 8,
+ "brightness_steps": 8,
+ "led_count": 8,
+ "max_brightness": 200,
+ "sleep": true
},
"matrix_pins": {
"cols": ["D1", "D0", "D2", "D3", "D5", "D4", "D6", "D7", "B4", "B5", "F0", "F1", "B6", "F4", "F5", "F6", "F7"],
diff --git a/keyboards/wuque/ikki68_aurora/config.h b/keyboards/wuque/ikki68_aurora/config.h
index c5726c333e..ae13273f23 100644
--- a/keyboards/wuque/ikki68_aurora/config.h
+++ b/keyboards/wuque/ikki68_aurora/config.h
@@ -23,11 +23,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
/* Locking resynchronize hack */
#define LOCKING_RESYNC_ENABLE
- #define RGBLED_NUM 20
- #define RGBLIGHT_HUE_STEP 8
- #define RGBLIGHT_SAT_STEP 8
- #define RGBLIGHT_VAL_STEP 8
- #define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */
/*======= RGB function=======*/
#define RGBLIGHT_EFFECT_BREATHING
#define RGBLIGHT_EFFECT_RAINBOW_MOOD
diff --git a/keyboards/wuque/ikki68_aurora/info.json b/keyboards/wuque/ikki68_aurora/info.json
index 2e93f0efc7..974170287d 100644
--- a/keyboards/wuque/ikki68_aurora/info.json
+++ b/keyboards/wuque/ikki68_aurora/info.json
@@ -21,7 +21,11 @@
"pin": "E2"
},
"rgblight": {
- "max_brightness": 200
+ "saturation_steps": 8,
+ "brightness_steps": 8,
+ "led_count": 20,
+ "max_brightness": 200,
+ "sleep": true
},
"processor": "atmega32u4",
"bootloader": "atmel-dfu",
diff --git a/keyboards/wuque/mammoth20x/config.h b/keyboards/wuque/mammoth20x/config.h
index c35fac65d6..db5a8d534e 100644
--- a/keyboards/wuque/mammoth20x/config.h
+++ b/keyboards/wuque/mammoth20x/config.h
@@ -22,7 +22,3 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
/* Locking resynchronize hack */
#define LOCKING_RESYNC_ENABLE
-
-// Note: array is { col, row )
-#define ENCODERS_CW_KEY { { 3, 2 } }
-#define ENCODERS_CCW_KEY { { 3, 4 } }
diff --git a/keyboards/wuque/mammoth20x/info.json b/keyboards/wuque/mammoth20x/info.json
index 3c0c0e29b8..f7917ae26d 100644
--- a/keyboards/wuque/mammoth20x/info.json
+++ b/keyboards/wuque/mammoth20x/info.json
@@ -29,9 +29,7 @@
{"matrix": [0, 0], "x": 0, "y": 0},
{"matrix": [0, 1], "x": 1, "y": 0},
{"matrix": [0, 2], "x": 2, "y": 0},
- {"matrix": [2, 3], "x": 3, "y": 0, "w": 0.5},
{"matrix": [0, 3], "x": 3.5, "y": 0},
- {"matrix": [4, 3], "x": 4.5, "y": 0, "w": 0.5},
{"matrix": [1, 0], "x": 0, "y": 1},
{"matrix": [1, 1], "x": 1, "y": 1},
diff --git a/keyboards/wuque/mammoth20x/keymaps/default/keymap.c b/keyboards/wuque/mammoth20x/keymaps/default/keymap.c
index e19b3bc172..5f444bbff3 100644
--- a/keyboards/wuque/mammoth20x/keymaps/default/keymap.c
+++ b/keyboards/wuque/mammoth20x/keymaps/default/keymap.c
@@ -18,7 +18,7 @@
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[0] = LAYOUT(
- KC_ESC, KC_PAUS, KC_DEL, KC_VOLU, KC_MUTE, KC_VOLD,
+ KC_ESC, KC_PAUS, KC_DEL, KC_MUTE,
KC_LNUM, KC_PSLS, KC_PAST, KC_PMNS,
KC_P7, KC_P8, KC_P9,
KC_P4, KC_P5, KC_P6, KC_PPLS,
@@ -26,7 +26,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_P0, KC_PDOT, KC_PENT
),
[1] = LAYOUT(
- _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______,
_______, _______, _______, _______,
_______, _______, _______,
_______, _______, _______, _______,
diff --git a/keyboards/wuque/mammoth20x/keymaps/via/keymap.c b/keyboards/wuque/mammoth20x/keymaps/via/keymap.c
index e5fe34fd7b..e48b8b50d1 100644
--- a/keyboards/wuque/mammoth20x/keymaps/via/keymap.c
+++ b/keyboards/wuque/mammoth20x/keymaps/via/keymap.c
@@ -18,7 +18,7 @@
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[0] = LAYOUT(
- KC_ESC, KC_PAUS, KC_DEL, KC_VOLD, KC_MUTE, KC_VOLU,
+ KC_ESC, KC_PAUS, KC_DEL, KC_MUTE,
KC_NUM, KC_PSLS, KC_PAST, KC_PMNS,
KC_P7, KC_P8, KC_P9,
KC_P4, KC_P5, KC_P6, KC_PPLS,
@@ -26,7 +26,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_P0, KC_PDOT, KC_PENT
),
[1] = LAYOUT(
- _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______,
_______, _______, _______, _______,
_______, _______, _______,
_______, _______, _______, _______,
@@ -34,7 +34,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
_______, _______, _______
),
[2] = LAYOUT(
- _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______,
_______, _______, _______, _______,
_______, _______, _______,
_______, _______, _______, _______,
@@ -42,7 +42,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
_______, _______, _______
),
[3] = LAYOUT(
- _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______,
_______, _______, _______, _______,
_______, _______, _______,
_______, _______, _______, _______,
@@ -50,3 +50,12 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
_______, _______, _______
),
};
+
+#ifdef ENCODER_MAP_ENABLE
+const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][NUM_DIRECTIONS] = {
+ [0] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
+ [1] = { ENCODER_CCW_CW(_______, _______) },
+ [2] = { ENCODER_CCW_CW(_______, _______) },
+ [3] = { ENCODER_CCW_CW(_______, _______) },
+};
+#endif
diff --git a/keyboards/wuque/mammoth20x/keymaps/via/rules.mk b/keyboards/wuque/mammoth20x/keymaps/via/rules.mk
index 36b7ba9cbc..1189f4ad19 100644
--- a/keyboards/wuque/mammoth20x/keymaps/via/rules.mk
+++ b/keyboards/wuque/mammoth20x/keymaps/via/rules.mk
@@ -1,2 +1,3 @@
VIA_ENABLE = yes
LTO_ENABLE = yes
+ENCODER_MAP_ENABLE = yes
diff --git a/keyboards/wuque/mammoth20x/mammoth20x.c b/keyboards/wuque/mammoth20x/mammoth20x.c
deleted file mode 100644
index eeaea79c71..0000000000
--- a/keyboards/wuque/mammoth20x/mammoth20x.c
+++ /dev/null
@@ -1,62 +0,0 @@
-/* Copyright 2021 wuquestudio
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
- */
-
-#include "quantum.h"
-
-static uint8_t encoder_state[NUM_ENCODERS] = {0};
-static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY;
-static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY;
-
-void encoder_action_unregister(void)
-{
- for (int index = 0; index < NUM_ENCODERS; ++index)
- {
- if (encoder_state[index])
- {
- keyevent_t encoder_event = (keyevent_t){
- .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index],
- .pressed = false,
- .time = timer_read(),
- .type = KEY_EVENT
- };
- encoder_state[index] = 0;
- action_exec(encoder_event);
- }
- }
-}
-void encoder_action_register(uint8_t index, bool clockwise)
-{
- keyevent_t encoder_event = (keyevent_t){
- .key = clockwise ? encoder_cw[index] : encoder_ccw[index],
- .pressed = true,
- .time = timer_read(),
- .type = KEY_EVENT
- };
- encoder_state[index] = (clockwise ^ 1) | (clockwise << 1);
- action_exec(encoder_event);
-}
-
-void matrix_scan_kb(void)
-{
- encoder_action_unregister();
- matrix_scan_user();
-}
-
-bool encoder_update_kb(uint8_t index, bool clockwise)
-{
- encoder_action_register(index, clockwise);
- return true;
-};
diff --git a/keyboards/wuque/mammoth75x/config.h b/keyboards/wuque/mammoth75x/config.h
index 6b0d17be5c..db5a8d534e 100644
--- a/keyboards/wuque/mammoth75x/config.h
+++ b/keyboards/wuque/mammoth75x/config.h
@@ -22,7 +22,3 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
/* Locking resynchronize hack */
#define LOCKING_RESYNC_ENABLE
-
-// Note: array is { col, row )
-#define ENCODERS_CW_KEY { { 3, 5 } }
-#define ENCODERS_CCW_KEY { { 5, 5 } }
diff --git a/keyboards/wuque/mammoth75x/info.json b/keyboards/wuque/mammoth75x/info.json
index ef48587375..9b9bc1abb6 100644
--- a/keyboards/wuque/mammoth75x/info.json
+++ b/keyboards/wuque/mammoth75x/info.json
@@ -41,10 +41,7 @@
{"matrix": [0, 11], "x": 11.75, "y": 0},
{"matrix": [0, 12], "x": 12.75, "y": 0},
{"matrix": [0, 13], "x": 14, "y": 0},
-
- {"matrix": [5, 3], "x": 15.65, "y": 0.125, "w": 0.6, "h": 0.5},
{"matrix": [0, 14], "x": 15.75, "y": 0.625},
- {"matrix": [5, 5], "x": 16.25, "y": 0.125, "w": 0.6, "h": 0.5},
{"matrix": [1, 0], "x": 0, "y": 1.25},
{"matrix": [1, 1], "x": 1, "y": 1.25},
diff --git a/keyboards/wuque/mammoth75x/keymaps/default/keymap.c b/keyboards/wuque/mammoth75x/keymaps/default/keymap.c
index b0273298dc..0ed2bdfebe 100644
--- a/keyboards/wuque/mammoth75x/keymaps/default/keymap.c
+++ b/keyboards/wuque/mammoth75x/keymaps/default/keymap.c
@@ -18,7 +18,7 @@
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[0] = LAYOUT_all(
- KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_DEL, KC_VOLD, KC_MUTE,KC_VOLU,
+ KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_DEL, KC_MUTE,
KC_GRV, 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_BSPC, 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_INS, KC_PGUP,
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_END, KC_PGDN,
@@ -26,7 +26,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT
),
[1] = LAYOUT_all(
- _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_MPRV, KC_MPLY, KC_MNXT,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_MPLY,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
diff --git a/keyboards/wuque/mammoth75x/keymaps/via/keymap.c b/keyboards/wuque/mammoth75x/keymaps/via/keymap.c
index 13d5d4fa7a..57f7a13cbd 100644
--- a/keyboards/wuque/mammoth75x/keymaps/via/keymap.c
+++ b/keyboards/wuque/mammoth75x/keymaps/via/keymap.c
@@ -18,7 +18,7 @@
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[0] = LAYOUT_all(
- KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_DEL, KC_VOLD, KC_MUTE,KC_VOLU,
+ KC_ESC, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, KC_DEL, KC_MUTE,
KC_GRV, 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_BSPC, 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_INS, KC_PGUP,
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_END, KC_PGDN,
@@ -26,7 +26,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, MO(1), KC_RCTL, KC_LEFT, KC_DOWN, KC_RGHT
),
[1] = LAYOUT_all(
- _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_MPRV, KC_MPLY, KC_MNXT,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, KC_MPLY,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
@@ -34,7 +34,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
[2] = LAYOUT_all(
- _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
@@ -42,7 +42,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
[3] = LAYOUT_all(
- _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
@@ -50,3 +50,12 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
};
+
+#ifdef ENCODER_MAP_ENABLE
+const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][NUM_DIRECTIONS] = {
+ [0] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
+ [1] = { ENCODER_CCW_CW(KC_MPRV, KC_MNXT) },
+ [2] = { ENCODER_CCW_CW(_______, _______) },
+ [3] = { ENCODER_CCW_CW(_______, _______) },
+};
+#endif
diff --git a/keyboards/wuque/mammoth75x/keymaps/via/rules.mk b/keyboards/wuque/mammoth75x/keymaps/via/rules.mk
index 36b7ba9cbc..1189f4ad19 100644
--- a/keyboards/wuque/mammoth75x/keymaps/via/rules.mk
+++ b/keyboards/wuque/mammoth75x/keymaps/via/rules.mk
@@ -1,2 +1,3 @@
VIA_ENABLE = yes
LTO_ENABLE = yes
+ENCODER_MAP_ENABLE = yes
diff --git a/keyboards/wuque/mammoth75x/mammoth75x.c b/keyboards/wuque/mammoth75x/mammoth75x.c
deleted file mode 100644
index 3b2d995b7e..0000000000
--- a/keyboards/wuque/mammoth75x/mammoth75x.c
+++ /dev/null
@@ -1,64 +0,0 @@
-/* Copyright 2021 wuquestudio
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
- */
-
-#include "quantum.h"
-
-#ifdef VIA_ENABLE
-static uint8_t encoder_state[NUM_ENCODERS] = {0};
-static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY;
-static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY;
-
-void encoder_action_unregister(void)
-{
- for (int index = 0; index < NUM_ENCODERS; ++index)
- {
- if (encoder_state[index])
- {
- keyevent_t encoder_event = (keyevent_t){
- .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index],
- .pressed = false,
- .time = timer_read(),
- .type = KEY_EVENT
- };
- encoder_state[index] = 0;
- action_exec(encoder_event);
- }
- }
-}
-void encoder_action_register(uint8_t index, bool clockwise)
-{
- keyevent_t encoder_event = (keyevent_t){
- .key = clockwise ? encoder_cw[index] : encoder_ccw[index],
- .pressed = true,
- .time = timer_read(),
- .type = KEY_EVENT
- };
- encoder_state[index] = (clockwise ^ 1) | (clockwise << 1);
- action_exec(encoder_event);
-}
-
-void matrix_scan_kb(void)
-{
- encoder_action_unregister();
- matrix_scan_user();
-}
-
-bool encoder_update_kb(uint8_t index, bool clockwise)
-{
- encoder_action_register(index, clockwise);
- return true;
-};
-#endif
diff --git a/keyboards/wuque/promise87/ansi/config.h b/keyboards/wuque/promise87/ansi/config.h
index b0e79e97c7..73de06450a 100644
--- a/keyboards/wuque/promise87/ansi/config.h
+++ b/keyboards/wuque/promise87/ansi/config.h
@@ -16,11 +16,6 @@
#pragma once
- #define RGBLED_NUM 1
- #define RGBLIGHT_HUE_STEP 8
- #define RGBLIGHT_SAT_STEP 8
- #define RGBLIGHT_VAL_STEP 8
- #define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */
/*======= RGB function=======*/
#define RGBLIGHT_EFFECT_BREATHING
#define RGBLIGHT_EFFECT_RAINBOW_MOOD
diff --git a/keyboards/wuque/promise87/ansi/info.json b/keyboards/wuque/promise87/ansi/info.json
index d49b4aaa79..6e77220f13 100644
--- a/keyboards/wuque/promise87/ansi/info.json
+++ b/keyboards/wuque/promise87/ansi/info.json
@@ -21,7 +21,11 @@
"pin": "D2"
},
"rgblight": {
- "max_brightness": 200
+ "saturation_steps": 8,
+ "brightness_steps": 8,
+ "led_count": 1,
+ "max_brightness": 200,
+ "sleep": true
},
"processor": "atmega32u4",
"bootloader": "atmel-dfu",
diff --git a/keyboards/wuque/promise87/wkl/config.h b/keyboards/wuque/promise87/wkl/config.h
index b0e79e97c7..73de06450a 100644
--- a/keyboards/wuque/promise87/wkl/config.h
+++ b/keyboards/wuque/promise87/wkl/config.h
@@ -16,11 +16,6 @@
#pragma once
- #define RGBLED_NUM 1
- #define RGBLIGHT_HUE_STEP 8
- #define RGBLIGHT_SAT_STEP 8
- #define RGBLIGHT_VAL_STEP 8
- #define RGBLIGHT_SLEEP /* If defined, the RGB lighting will be switched off when the host goes to sleep */
/*======= RGB function=======*/
#define RGBLIGHT_EFFECT_BREATHING
#define RGBLIGHT_EFFECT_RAINBOW_MOOD
diff --git a/keyboards/wuque/promise87/wkl/info.json b/keyboards/wuque/promise87/wkl/info.json
index 7e0d7cfdcb..500c1bd9db 100644
--- a/keyboards/wuque/promise87/wkl/info.json
+++ b/keyboards/wuque/promise87/wkl/info.json
@@ -21,7 +21,11 @@
"pin": "D2"
},
"rgblight": {
- "max_brightness": 200
+ "saturation_steps": 8,
+ "brightness_steps": 8,
+ "led_count": 1,
+ "max_brightness": 200,
+ "sleep": true
},
"processor": "atmega32u4",
"bootloader": "atmel-dfu",
diff --git a/keyboards/wuque/serneity65/config.h b/keyboards/wuque/serneity65/config.h
deleted file mode 100644
index 134605fcab..0000000000
--- a/keyboards/wuque/serneity65/config.h
+++ /dev/null
@@ -1,21 +0,0 @@
-/* Copyright 2021 wuque
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
- */
-
-#pragma once
-
-// Note: array is { col, row )
-#define ENCODERS_CW_KEY { { 3, 4 } }
-#define ENCODERS_CCW_KEY { { 5, 4 } }
diff --git a/keyboards/wuque/serneity65/info.json b/keyboards/wuque/serneity65/info.json
index 9ebc9af843..f27073b285 100644
--- a/keyboards/wuque/serneity65/info.json
+++ b/keyboards/wuque/serneity65/info.json
@@ -41,9 +41,7 @@
{"matrix": [0, 11], "x": 11, "y": 0},
{"matrix": [0, 12], "x": 12, "y": 0},
{"matrix": [0, 13], "x": 13, "y": 0},
- {"matrix": [4, 3], "x": 15, "y": 0, "w": 0.5},
{"matrix": [0, 14], "x": 15.5, "y": 0},
- {"matrix": [4, 5], "x": 16.5, "y": 0, "w": 0.5},
{"matrix": [1, 0], "x": 0, "y": 1, "w": 1.5},
{"matrix": [1, 1], "x": 1.5, "y": 1},
diff --git a/keyboards/wuque/serneity65/keymaps/default/keymap.c b/keyboards/wuque/serneity65/keymaps/default/keymap.c
index 2acca2f0c0..23ddfced88 100644
--- a/keyboards/wuque/serneity65/keymaps/default/keymap.c
+++ b/keyboards/wuque/serneity65/keymaps/default/keymap.c
@@ -18,17 +18,17 @@
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[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_BSPC, KC_VOLD, KC_MUTE, KC_VOLU,
+ 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_BSPC, KC_MUTE,
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_BSPC, KC_PGUP,
KC_LSFT, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_END,
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, MO(1), KC_LEFT, KC_DOWN, KC_RGHT
),
[1] = LAYOUT_all(
- KC_GRV, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, KC_MPRV, KC_MPLY, KC_MNXT,
+ KC_GRV, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, KC_MPLY,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
- ),
-};
+ )
+ };
diff --git a/keyboards/wuque/serneity65/keymaps/via/keymap.c b/keyboards/wuque/serneity65/keymaps/via/keymap.c
index 8e820022fe..05abb620da 100644
--- a/keyboards/wuque/serneity65/keymaps/via/keymap.c
+++ b/keyboards/wuque/serneity65/keymaps/via/keymap.c
@@ -18,31 +18,40 @@
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[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_BSPC, KC_VOLD, KC_MUTE, KC_VOLU,
+ 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_BSPC, KC_MUTE,
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_BSPC, KC_PGUP,
KC_LSFT, KC_LSFT, KC_Z, KC_X, KC_C, KC_V, KC_B, KC_N, KC_M, KC_COMM, KC_DOT, KC_SLSH, KC_RSFT, KC_UP, KC_END,
KC_LCTL, KC_LGUI, KC_LALT, KC_SPC, KC_SPC, KC_SPC, KC_RALT, MO(1), KC_LEFT, KC_DOWN, KC_RGHT
),
[1] = LAYOUT_all(
- KC_GRV, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, KC_MPRV, KC_MPLY, KC_MNXT,
+ KC_GRV, KC_F1, KC_F2, KC_F3, KC_F4, KC_F5, KC_F6, KC_F7, KC_F8, KC_F9, KC_F10, KC_F11, KC_F12, _______, KC_MPLY,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, QK_BOOT,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
[2] = LAYOUT_all(
- _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
[3] = LAYOUT_all(
- _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
+ _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______,
_______, _______, _______, _______, _______, _______, _______, _______, _______, _______, _______
),
};
+
+#ifdef ENCODER_MAP_ENABLE
+const uint16_t PROGMEM encoder_map[][NUM_ENCODERS][NUM_DIRECTIONS] = {
+ [0] = { ENCODER_CCW_CW(KC_VOLD, KC_VOLU) },
+ [1] = { ENCODER_CCW_CW(KC_MPRV, KC_MNXT) },
+ [2] = { ENCODER_CCW_CW(_______, _______) },
+ [3] = { ENCODER_CCW_CW(_______, _______) },
+};
+#endif
diff --git a/keyboards/wuque/serneity65/keymaps/via/rules.mk b/keyboards/wuque/serneity65/keymaps/via/rules.mk
index 43061db1dd..1189f4ad19 100644
--- a/keyboards/wuque/serneity65/keymaps/via/rules.mk
+++ b/keyboards/wuque/serneity65/keymaps/via/rules.mk
@@ -1,2 +1,3 @@
VIA_ENABLE = yes
-LTO_ENABLE = yes \ No newline at end of file
+LTO_ENABLE = yes
+ENCODER_MAP_ENABLE = yes
diff --git a/keyboards/wuque/serneity65/serneity65.c b/keyboards/wuque/serneity65/serneity65.c
deleted file mode 100644
index 58e0663467..0000000000
--- a/keyboards/wuque/serneity65/serneity65.c
+++ /dev/null
@@ -1,64 +0,0 @@
-/* Copyright 2021 wuque
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
- */
-
-#include "quantum.h"
-
-#ifdef VIA_ENABLE
-static uint8_t encoder_state[NUM_ENCODERS] = {0};
-static keypos_t encoder_cw[NUM_ENCODERS] = ENCODERS_CW_KEY;
-static keypos_t encoder_ccw[NUM_ENCODERS] = ENCODERS_CCW_KEY;
-
-void encoder_action_unregister(void)
-{
- for (int index = 0; index < NUM_ENCODERS; ++index)
- {
- if (encoder_state[index])
- {
- keyevent_t encoder_event = (keyevent_t){
- .key = encoder_state[index] >> 1 ? encoder_cw[index] : encoder_ccw[index],
- .pressed = false,
- .time = timer_read(),
- .type = KEY_EVENT
- };
- encoder_state[index] = 0;
- action_exec(encoder_event);
- }
- }
-}
-void encoder_action_register(uint8_t index, bool clockwise)
-{
- keyevent_t encoder_event = (keyevent_t){
- .key = clockwise ? encoder_cw[index] : encoder_ccw[index],
- .pressed = true,
- .time = timer_read(),
- .type = KEY_EVENT
- };
- encoder_state[index] = (clockwise ^ 1) | (clockwise << 1);
- action_exec(encoder_event);
-}
-
-void matrix_scan_kb(void)
-{
- encoder_action_unregister();
- matrix_scan_user();
-}
-
-bool encoder_update_kb(uint8_t index, bool clockwise)
-{
- encoder_action_register(index, clockwise);
- return true;
-};
-#endif