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

Move backlight config to data driven #19910

Merged
merged 6 commits into from
Feb 25, 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
Add backlight as caps lock to schema
  • Loading branch information
fauxpark committed Feb 22, 2023
commit 44a0f488b78aab8613edb983014e7b2cab40bd30
1 change: 1 addition & 0 deletions data/mappings/info_config.hjson
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"AUDIO_VOICES": {"info_key": "audio.voices", "value_type": "bool"},
"BACKLIGHT_BREATHING": {"info_key": "backlight.breathing", "value_type": "bool"},
"BREATHING_PERIOD": {"info_key": "backlight.breathing_period", "value_type": "int"},
"BACKLIGHT_CAPS_LOCK": {"info_key": "backlight.as_caps_lock", "value_type": "bool"},
"BACKLIGHT_LEVELS": {"info_key": "backlight.levels", "value_type": "int"},
"BACKLIGHT_LIMIT_VAL": {"info_key": "backlight.max_brightness", "value_type": "int"},
"BACKLIGHT_ON_STATE": {"info_key": "backlight.on_state", "value_type": "int"},
Expand Down
3 changes: 2 additions & 1 deletion data/schemas/keyboard.jsonschema
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,8 @@
"max_brightness": {"$ref": "qmk.definitions.v1#/unsigned_int_8"},
"pin": {"$ref": "qmk.definitions.v1#/mcu_pin"},
"pins": {"$ref": "qmk.definitions.v1#/mcu_pin_array"},
"on_state": {"$ref": "qmk.definitions.v1#/bit"}
"on_state": {"$ref": "qmk.definitions.v1#/bit"},
"as_caps_lock": {"type": "boolean"}
}
},
"bluetooth": {
Expand Down
1 change: 0 additions & 1 deletion keyboards/mode/m75s/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
/* Locking resynchronize hack */
#define LOCKING_RESYNC_ENABLE

#define BACKLIGHT_CAPS_LOCK
#define BACKLIGHT_DEFAULT_LEVEL 20
#define BACKLIGHT_PWM_DRIVER PWMD3
#define BACKLIGHT_PWM_CHANNEL 1
Expand Down
3 changes: 2 additions & 1 deletion keyboards/mode/m75s/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
},
"backlight": {
"pin": "C6",
"levels": 20
"levels": 20,
"as_caps_lock": true
},
"processor": "STM32F401",
"bootloader": "stm32-dfu",
Expand Down
5 changes: 0 additions & 5 deletions keyboards/mokey/ginkgo65/config.h

This file was deleted.

3 changes: 2 additions & 1 deletion keyboards/mokey/ginkgo65/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
"backlight": {
"pin": "B6",
"levels": 6,
"breathing": true
"breathing": true,
"as_caps_lock": true
},
"layout_aliases": {
"LAYOUT": "LAYOUT_65_ansi_blocker"
Expand Down
2 changes: 0 additions & 2 deletions keyboards/mokey/ginkgo65hot/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,3 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define MATRIX_ROW_PINS { B0, B1, B2, B3, F7 }
#define MATRIX_COL_PINS { C7, F6, F5, F4, F1, E6, D0, D1, D2, D3, D5, D4, D6, D7, B4 }
#define DIODE_DIRECTION COL2ROW

#define BACKLIGHT_CAPS_LOCK
3 changes: 2 additions & 1 deletion keyboards/mokey/ginkgo65hot/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"backlight": {
"pin": "B6",
"levels": 6,
"breathing": true
"breathing": true,
"as_caps_lock": true
},
"processor": "atmega32u4",
"bootloader": "atmel-dfu",
Expand Down
2 changes: 0 additions & 2 deletions keyboards/sentraq/s65_x/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@
#define MATRIX_ROW_PINS { C7, C6, B6, B5, B4 }
#define MATRIX_COL_PINS { F4, F1, F0, E6, B0, B1, D5, B2, B3, D0, D1, D2, D4, D6, D7, F7 }

#define BACKLIGHT_CAPS_LOCK

#define RGB_DI_PIN D3
#define RGBLIGHT_EFFECT_BREATHING
#define RGBLIGHT_EFFECT_RAINBOW_MOOD
Expand Down
3 changes: 2 additions & 1 deletion keyboards/sentraq/s65_x/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
},
"backlight": {
"pin": "B7",
"levels": 5
"levels": 5,
"as_caps_lock": true
},
"processor": "atmega32u4",
"bootloader": "atmel-dfu",
Expand Down