我设备树中查看到了,然后我昨天测试的时候发现这些按键,只有确认和返回,没有home按键,和音量+和音量-?这个做进去应该不难吧?
hlm@Server:/users/hlm/9_Edge$ grep -rn "khadas-matrix-keypad" kernel/drivers/
kernel/drivers/input/keyboard/khadas-matrix-keypad.c:452: { .compatible = "khadas-matrix-keypad" },
kernel/drivers/input/keyboard/khadas-matrix-keypad.c:462: .name = "khadas-matrix-keypad",
上面是Captain板子才有的按键矩阵
rk3399-android.dtsi
rk_key: rockchip-key {
compatible = "rockchip,key";
status = "okay";
io-channels = <&saradc 1>;
power-key {
gpios = <&gpio0 5 GPIO_ACTIVE_LOW>;
linux,code = <116>;
label = "power";
gpio-key,wakeup;
};
home-key {
linux,code = <102>;
label = "home";
rockchip,adc_value = <70>;
};
};
hlm@Server:/users/hlm/9_Edge$ grep -rn "rockchip,key" kernel/drivers/
Binary file kernel/drivers/input/keyboard/built-in.o matches
kernel/drivers/input/keyboard/rk_keys.c:192: { .compatible = "rockchip,key", .data = NULL},
这是Edge和edge-v的按键驱动