Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Keyboard] Add Erdnuss 65 #20202

Merged
merged 20 commits into from
Apr 2, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
update
  • Loading branch information
ctt-t committed Mar 21, 2023
commit 8fb411877df465cc5dd24273ccb7262be2457d1c
5 changes: 1 addition & 4 deletions keyboards/citrus/erdnuss65/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,9 @@
*/
#pragma once

#include "config_common.h"

// The pin connected to the data pin of the LEDs
#define RGBLIGHT_LAYERS//允许您定义可打开或关闭的照明层。非常适合显示当前键盘层或大写锁定状态。
#define RGBLIGHT_LAYERS_OVERRIDE_RGB_OFF//如果已定义,则即使 RGB 光源处于关闭状态,也会显示照明图层。

#define LOCKING_SUPPORT_ENABLE
#define LOCKING_RESYNC_ENABLE//尝试使开关状态与键盘指示灯状态保持一致

#define LOCKING_RESYNC_ENABLE//尝试使开关状态与键盘指示灯状态保持一致
12 changes: 1 addition & 11 deletions keyboards/citrus/erdnuss65/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@

"diode_direction": "COL2ROW",

"debounce": 5,

"features": {
"bootmagic": true,
"mousekey": true,
Expand All @@ -34,15 +32,7 @@
},
"rgblight": {
"pin": "A15",
"led_count": 1,
"hue_steps": 8,
"saturation_steps": 8,
"brightness_steps": 8,
"max_brightness": 200,
"sleep": true,
"animations": {
"all": false
}
"led_count": 1
},
"layouts": {
"LAYOUT": {
Expand Down
12 changes: 2 additions & 10 deletions keyboards/citrus/erdnuss65/keymaps/default/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,21 +39,13 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
),

};
//Initialize all RGB indicators to 'off'初始化rgb
__attribute__((weak))
void keyboard_post_inti_user(void) {
rgblight_setrgb_at(0, 0, 0, 0);
}

//Indicator light function
bool led_update_kb(led_t led_state) {
bool res = led_update_user(led_state);
if (res) {
bool led_update_user(led_t led_state) {
ctt-t marked this conversation as resolved.
Show resolved Hide resolved
if (led_state.caps_lock) {
rgblight_setrgb_at(255, 255, 255, 0); //white
} else {
rgblight_setrgb_at(0, 0, 0, 0);
}
}
return res;
return true;
}
13 changes: 2 additions & 11 deletions keyboards/citrus/erdnuss65/keymaps/via/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,21 +39,12 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
),

};
//Initialize all RGB indicators to 'off'初始化rgb
__attribute__((weak))
void keyboard_post_inti_user(void) {
rgblight_setrgb_at(0, 0, 0, 0);
}

//Indicator light function
bool led_update_kb(led_t led_state) {
bool res = led_update_user(led_state);
if (res) {
bool led_update_user(led_t led_state) {
ctt-t marked this conversation as resolved.
Show resolved Hide resolved
if (led_state.caps_lock) {
rgblight_setrgb_at(255, 255, 255, 0); //white
} else {
rgblight_setrgb_at(0, 0, 0, 0);
}
}
return res;
return true;
}