summaryrefslogtreecommitdiff
path: root/keyboards/keychron
diff options
context:
space:
mode:
authorfauxpark <fauxpark@gmail.com>2022-09-30 05:19:53 +1000
committerfauxpark <fauxpark@gmail.com>2022-09-30 05:19:53 +1000
commitdbb70871fcb98b98dd5544b53f4083dfc2aeefff (patch)
tree75839f796a26c2f2908b584e3ca0a35457f83fe2 /keyboards/keychron
parentdbe214c3268d9a316a137471a7679f7e45046e49 (diff)
parent45b5ed5c6e1ecdf95e9ce0523a8ff49d45b8822f (diff)
Merge remote-tracking branch 'upstream/master' into develop
Diffstat (limited to 'keyboards/keychron')
-rw-r--r--keyboards/keychron/q0/config.h10
-rw-r--r--keyboards/keychron/q0/q0.c8
-rw-r--r--keyboards/keychron/q0/rev_0130/rev_0130.c14
-rw-r--r--keyboards/keychron/q2/rev_0112/keymaps/default/keymap.c2
-rw-r--r--keyboards/keychron/q2/rev_0112/keymaps/via/keymap.c2
-rw-r--r--keyboards/keychron/q2/rev_0113/keymaps/default/keymap.c2
-rw-r--r--keyboards/keychron/q2/rev_0113/keymaps/via/keymap.c2
7 files changed, 21 insertions, 19 deletions
diff --git a/keyboards/keychron/q0/config.h b/keyboards/keychron/q0/config.h
index 40f506fe80..a04d31d3a2 100644
--- a/keyboards/keychron/q0/config.h
+++ b/keyboards/keychron/q0/config.h
@@ -34,18 +34,18 @@
#define DRIVER_COUNT 1
#define DRIVER_ADDR_1 0b1110100
-#define CONSTANT_CURRENT_STEP \
+#define CKLED2001_CURRENT_TUNE \
{ 0xFF, 0xFF, 0x70, 0xFF, 0xFF, 0x70, 0xFF, 0xFF, 0x70, 0xFF, 0xFF, 0x70 }
+#define RGB_MATRIX_CENTER \
+ { 56, 16 }
+
/* NKRO */
#define FORCE_NKRO
/* turn off effects when suspended */
#define RGB_DISABLE_WHEN_USB_SUSPENDED
-/* We have 2KB EEPROM size on STM32L432 */
-#define DYNAMIC_KEYMAP_EEPROM_MAX_ADDR 2047
-
/* EEPROM Driver Configuration */
#define WEAR_LEVELING_LOGICAL_SIZE 2048
#define WEAR_LEVELING_BACKING_SIZE (WEAR_LEVELING_LOGICAL_SIZE * 2)
@@ -98,4 +98,4 @@
#define ENABLE_RGB_MATRIX_MULTISPLASH
#define ENABLE_RGB_MATRIX_SOLID_SPLASH
#define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH
-// #define RGB_MATRIX_KEYPRESSES \ No newline at end of file
+// #define RGB_MATRIX_KEYPRESSES
diff --git a/keyboards/keychron/q0/q0.c b/keyboards/keychron/q0/q0.c
index c43157ac68..d17ab77f47 100644
--- a/keyboards/keychron/q0/q0.c
+++ b/keyboards/keychron/q0/q0.c
@@ -16,7 +16,7 @@
#include "q0.h"
-#if defined(RGB_MATRIX_ENABLE) && defined(CAPS_LOCK_LED_INDEX)
+#if defined(RGB_MATRIX_ENABLE) && defined(NUM_LOCK_LED_INDEX)
bool process_record_kb(uint16_t keycode, keyrecord_t *record) {
if (!process_record_user(keycode, record)) {
@@ -45,11 +45,11 @@ bool process_record_kb(uint16_t keycode, keyrecord_t *record) {
__attribute__((weak)) void rgb_matrix_indicators_advanced_user(uint8_t led_min, uint8_t led_max) {
// RGB_MATRIX_INDICATOR_SET_COLOR(index, red, green, blue);
- if (host_keyboard_led_state().caps_lock) {
- RGB_MATRIX_INDICATOR_SET_COLOR(CAPS_LOCK_LED_INDEX, 255, 255, 255);
+ if (host_keyboard_led_state().num_lock) {
+ RGB_MATRIX_INDICATOR_SET_COLOR(NUM_LOCK_LED_INDEX, 255, 255, 255);
} else {
if (!rgb_matrix_get_flags()) {
- RGB_MATRIX_INDICATOR_SET_COLOR(CAPS_LOCK_LED_INDEX, 0, 0, 0);
+ RGB_MATRIX_INDICATOR_SET_COLOR(NUM_LOCK_LED_INDEX, 0, 0, 0);
}
}
}
diff --git a/keyboards/keychron/q0/rev_0130/rev_0130.c b/keyboards/keychron/q0/rev_0130/rev_0130.c
index 2803239b53..b968361c7e 100644
--- a/keyboards/keychron/q0/rev_0130/rev_0130.c
+++ b/keyboards/keychron/q0/rev_0130/rev_0130.c
@@ -18,6 +18,8 @@
#ifdef RGB_MATRIX_ENABLE
+// clang-format off
+
const ckled2001_led PROGMEM g_ckled2001_leds[RGB_MATRIX_LED_COUNT] = {
/* Refer to CKLED manual for these locations
* driver
@@ -67,12 +69,12 @@ led_config_t g_led_config = {
},
{
// LED Index to Physical Position
- {0,0}, {74,0}, {150,0}, {224,0},
- {0,13}, {74,13}, {150,13}, {224,13},
- {0,26}, {74,26}, {150,26},
- {0,38}, {74,38}, {150,38}, {224,32},
- {0,51}, {74,51}, {150,51},
- {36,64}, {150,64}, {224,58},
+ {0,0}, {37,0}, {75,0}, {112,0},
+ {0,6}, {37,6}, {75,6}, {112,6},
+ {0,13}, {37,13}, {75,13},
+ {0,19}, {37,19}, {75,19}, {112,16},
+ {0,25}, {37,25}, {75,25},
+ {18,32}, {75,32}, {112,29},
},
{
// LED Index to Flag
diff --git a/keyboards/keychron/q2/rev_0112/keymaps/default/keymap.c b/keyboards/keychron/q2/rev_0112/keymaps/default/keymap.c
index 75667b44c8..21a837c1a0 100644
--- a/keyboards/keychron/q2/rev_0112/keymaps/default/keymap.c
+++ b/keyboards/keychron/q2/rev_0112/keymaps/default/keymap.c
@@ -37,7 +37,7 @@ enum custom_keycodes {
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[MAC_BASE] = LAYOUT_iso_68(
- KC_ESC, KC_1, KC_2, KC_F3, KC_F4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS,
+ 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_INS,
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_DEL,
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_NUHS, KC_ENT, KC_HOME,
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, KC_UP,
diff --git a/keyboards/keychron/q2/rev_0112/keymaps/via/keymap.c b/keyboards/keychron/q2/rev_0112/keymaps/via/keymap.c
index 0a91857f1e..9eb7288dc1 100644
--- a/keyboards/keychron/q2/rev_0112/keymaps/via/keymap.c
+++ b/keyboards/keychron/q2/rev_0112/keymaps/via/keymap.c
@@ -37,7 +37,7 @@ enum custom_keycodes {
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[MAC_BASE] = LAYOUT_iso_68(
- KC_ESC, KC_1, KC_2, KC_F3, KC_F4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_INS,
+ 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_INS,
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_DEL,
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_NUHS, KC_ENT, KC_HOME,
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, KC_UP,
diff --git a/keyboards/keychron/q2/rev_0113/keymaps/default/keymap.c b/keyboards/keychron/q2/rev_0113/keymaps/default/keymap.c
index e3e6cf7376..a44e7e4cc9 100644
--- a/keyboards/keychron/q2/rev_0113/keymaps/default/keymap.c
+++ b/keyboards/keychron/q2/rev_0113/keymaps/default/keymap.c
@@ -37,7 +37,7 @@ enum custom_keycodes {
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[MAC_BASE] = LAYOUT_iso_68(
- KC_ESC, KC_1, KC_2, KC_F3, KC_F4, KC_5, KC_6, KC_7, KC_8, KC_9, KC_0, KC_MINS, KC_EQL, KC_BSPC, KC_MUTE,
+ 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_DEL,
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_NUHS, KC_ENT, KC_HOME,
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, KC_UP,
diff --git a/keyboards/keychron/q2/rev_0113/keymaps/via/keymap.c b/keyboards/keychron/q2/rev_0113/keymaps/via/keymap.c
index 4e3b431bdf..268173b060 100644
--- a/keyboards/keychron/q2/rev_0113/keymaps/via/keymap.c
+++ b/keyboards/keychron/q2/rev_0113/keymaps/via/keymap.c
@@ -37,7 +37,7 @@ enum custom_keycodes {
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
[MAC_BASE] = LAYOUT_all(
- KC_ESC, KC_1, KC_2, KC_F3, KC_F4, 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_VOLD, KC_MUTE, KC_VOLU,
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_DEL,
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_NUHS, KC_ENT, KC_HOME,
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, KC_UP,