diff options
author | lalalademaxiya1 <2831039915@qq.com> | 2023-10-16 10:57:35 +0800 |
---|---|---|
committer | lalalademaxiya1 <2831039915@qq.com> | 2023-10-16 10:57:35 +0800 |
commit | 39503982d15af018f55b536f3d2671ae58e58df3 (patch) | |
tree | a5d9f8a9708a4c0fdc9f06dd9b2faf63f49b9cec /keyboards/keychron/k11_pro | |
parent | 156b2cf426f960cf4c6de0818dc5999f5d68903c (diff) | |
parent | 00af20f690b66b11c3c00826b5193a306b611ec4 (diff) |
Merge branch 'temp' into keychron_k5_pro
Diffstat (limited to 'keyboards/keychron/k11_pro')
5 files changed, 11 insertions, 15 deletions
diff --git a/keyboards/keychron/k11_pro/k11_pro.c b/keyboards/keychron/k11_pro/k11_pro.c index 9189ef8586..6ad7649bab 100755 --- a/keyboards/keychron/k11_pro/k11_pro.c +++ b/keyboards/keychron/k11_pro/k11_pro.c @@ -135,8 +135,8 @@ bool process_record_kb(uint16_t keycode, keyrecord_t *record) { return true; } -#if defined(KC_BLUETOOTH_ENABLE) && defined(ENCODER_ENBALE) -static void encoder0_pad_cb(void *param) { +#if defined(ENCODER_ENABLE) +static void encoder_pad_cb(void *param) { encoder_inerrupt_read((uint32_t)param & 0xFF); } #endif @@ -156,16 +156,16 @@ void keyboard_post_init_kb(void) { ckbt51_init(false); bluetooth_init(); - #endif -#ifdef ENCODER_ENBALE + +#ifdef ENCODER_ENABLE pin_t encoders_pad_a[NUM_ENCODERS] = ENCODERS_PAD_A; pin_t encoders_pad_b[NUM_ENCODERS] = ENCODERS_PAD_B; - for (uint8_t i = 0; i < NUM_ENCODERS; i++) { + for (uint32_t i = 0; i < NUM_ENCODERS; i++) { palEnableLineEvent(encoders_pad_a[i], PAL_EVENT_MODE_BOTH_EDGES); palEnableLineEvent(encoders_pad_b[i], PAL_EVENT_MODE_BOTH_EDGES); - palSetLineCallback(encoders_pad_a[i], encoder_pad_cb, &i); - palSetLineCallback(encoders_pad_b[i], encoder_pad_cb, &i); + palSetLineCallback(encoders_pad_a[i], encoder_pad_cb, (void *)i); + palSetLineCallback(encoders_pad_b[i], encoder_pad_cb, (void *)i); } #endif diff --git a/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_encoder_rgb.json b/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_encoder_rgb.json index 5c6acd35ba..e0e3a10a84 100755 --- a/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_encoder_rgb.json +++ b/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_encoder_rgb.json @@ -290,8 +290,7 @@ }, "4,3", { - "c": "#aaaaaa", - "w": 1.25 + "c": "#aaaaaa" }, "4,6" ], diff --git a/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_encoder_white.json b/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_encoder_white.json index a0288b2601..49279b4765 100755 --- a/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_encoder_white.json +++ b/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_encoder_white.json @@ -229,8 +229,7 @@ }, "4,3", { - "c": "#aaaaaa", - "w": 1.25 + "c": "#aaaaaa" }, "4,6" ], diff --git a/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_rgb.json b/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_rgb.json index 2e181484c6..55a3d2153c 100755 --- a/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_rgb.json +++ b/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_rgb.json @@ -290,8 +290,7 @@ }, "4,3", { - "c": "#aaaaaa", - "w": 1.25 + "c": "#aaaaaa" }, "4,6" ], diff --git a/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_white.json b/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_white.json index 5d856f4f1f..c1ad185bee 100755 --- a/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_white.json +++ b/keyboards/keychron/k11_pro/via_json/k11_pro_ansi_white.json @@ -229,8 +229,7 @@ }, "4,3", { - "c": "#aaaaaa", - "w": 1.25 + "c": "#aaaaaa" }, "4,6" ], |