Files
new_kbd/app.overlay
skiinder 7587df7553 feat(led): 添加键盘LED状态管理模块
- 新增keyboard_led_state_event事件用于处理USB/BLE HID输出报告中的LED状态
- 实现led_state_module模块,管理Num Lock指示灯和BLE状态指示灯
- 定义LED状态效果映射,包括熄灭、常亮、慢闪、快闪等效果
- 将hid_keymap_def.h从configuration目录移至inc目录
- 在BLE和USB HID模块中添加对输出报告LED掩码的解析和处理
- 配置DTS中的led_1为可用状态,更新CMakeLists.txt构建配置
2026-03-16 11:39:27 +08:00

77 lines
1.4 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#include <zephyr/dt-bindings/gpio/gpio.h>
/ {
zephyr,user {
vbat-en-gpios = <&gpio0 9 GPIO_ACTIVE_HIGH>;
io-channels = <&adc 5>, <&adc 7>;
};
hid_dev_0: hid_dev_0 {
compatible = "zephyr,hid-device";
label = "HID_BOOT";
protocol-code = "keyboard";
in-report-size = <8>;
in-polling-period-us = <1000>;
out-report-size = <8>;
out-polling-period-us = <1000>;
};
hid_dev_1: hid_dev_1 {
compatible = "zephyr,hid-device";
label = "HID_NKRO";
protocol-code = "none";
in-report-size = <31>;
in-polling-period-us = <1000>;
out-report-size = <8>;
out-polling-period-us = <1000>;
};
raw_hid: hid_dev_2 {
compatible = "zephyr,hid-device";
label = "HID_RAW";
protocol-code = "none";
in-report-size = <64>;
in-polling-period-us = <1000>;
out-report-size = <64>;
out-polling-period-us = <1000>;
};
};
&gpio0 {
status = "okay";
};
&gpio1 {
status = "okay";
};
&gpiote {
status = "okay";
};
&led_0 {
status = "okay";
};
&led_1 {
status = "okay";
};
/* 使能 SAADCmode_switch_module 使用 channel 7 采样模式拨码电压。 */
&adc {
status = "okay";
};
&i2c1 {
status = "okay";
ip5305: pmic@75 {
status = "okay";
keepalive-interval-ms = <10000>;
};
};
&usbd {
status = "okay";
};