zephyr/dts/bindings/input/zephyr,lvgl-button-input.yaml
Fabian Blatz b296d1152f input: add zephyr,lvgl-button-input device binding
Add a pseudo device which can be used to hook into gpio-keys input_events
and relay the events to a lv_indev.

Signed-off-by: Fabian Blatz <fabianblatz@gmail.com>
2023-08-29 10:17:52 +02:00

37 lines
946 B
YAML

# Copyright 2023 Fabian Blatz <fabianblatz@gmail.com>
# SPDX-License-Identifier: Apache-2.0
description: |
LVGL button indev pseudo-device
Listens for button input events and routes the
lv_indev_data_t to the underlying button lv_indev_t managed by LVGL.
Example configuration:
pointer {
compatible = "zephyr,lvgl-button-input";
input = <&buttons>;
input-codes = <INPUT_KEY_0 INPUT_KEY_1>;
coordinates = <120 220>, <150 250>;
};
When the device receives an input_event with code INPUT_KEY_0
a click event will be performed at (120,220).
compatible: "zephyr,lvgl-button-input"
include: zephyr,lvgl-common-input.yaml
properties:
input-codes:
type: array
required: true
description: |
Array of input event key codes (INPUT_KEY_* or INPUT_BTN_*).
coordinates:
type: array
description: |
Array of points (x,y) the associated input-code is mapped to.