From 9c0ce80d7e7d266cfd2d8fb0d92889db06ea95ff Mon Sep 17 00:00:00 2001 From: Ryan Date: Tue, 21 Feb 2023 12:05:40 +1100 Subject: Move backlight config to data driven, part 1 (#19887) --- keyboards/ktec/staryu/backlight_staryu.h | 2 +- keyboards/ktec/staryu/config.h | 4 ---- keyboards/ktec/staryu/info.json | 3 +++ 3 files changed, 4 insertions(+), 5 deletions(-) (limited to 'keyboards/ktec/staryu') diff --git a/keyboards/ktec/staryu/backlight_staryu.h b/keyboards/ktec/staryu/backlight_staryu.h index b90350e28b..34511da5c1 100644 --- a/keyboards/ktec/staryu/backlight_staryu.h +++ b/keyboards/ktec/staryu/backlight_staryu.h @@ -18,7 +18,7 @@ along with this program. If not, see . // Add backwards compatibility for existing keymaps static inline void backlight_set_value(uint8_t index, uint8_t level) { - static const uint8_t backlight_pins[BACKLIGHT_LED_COUNT] = BACKLIGHT_PINS; + static const uint8_t backlight_pins[] = BACKLIGHT_PINS; if (level) { setPinOutput(backlight_pins[index]); } else { diff --git a/keyboards/ktec/staryu/config.h b/keyboards/ktec/staryu/config.h index e8e726364c..1a1b7372e6 100755 --- a/keyboards/ktec/staryu/config.h +++ b/keyboards/ktec/staryu/config.h @@ -30,8 +30,4 @@ along with this program. If not, see . #define RGBLIGHT_EFFECT_TWINKLE #define RGBLIGHT_LIMIT_VAL 200 - -#undef BACKLIGHT_PIN -#define BACKLIGHT_PINS { C2, C7, D5, D6, B0 } -#define BACKLIGHT_LED_COUNT 5 #define BACKLIGHT_LEVELS 10 diff --git a/keyboards/ktec/staryu/info.json b/keyboards/ktec/staryu/info.json index 0463c08ccc..21c4e04dd7 100644 --- a/keyboards/ktec/staryu/info.json +++ b/keyboards/ktec/staryu/info.json @@ -8,6 +8,9 @@ "pid": "0x2328", "device_version": "2.0.5" }, + "backlight": { + "pins": ["C2", "C7", "D5", "D6", "B0"] + }, "bootmagic": { "matrix": [0, 1] }, -- cgit v1.2.3