zephyr/dts/bindings/input/zephyr,lvgl-encoder-input.yaml
Fabian Blatz 094342866f modules: lvgl: input: add zephyr,lvgl-encoder-input device binding
Add a pseudo device which can be used to hook into qdec events and
optionally a button and relay the input_event to lvgl.

Signed-off-by: Fabian Blatz <fabianblatz@gmail.com>
2023-09-13 11:35:04 +02:00

33 lines
824 B
YAML

# Copyright 2023 Fabian Blatz <fabianblatz@gmail.com>
# SPDX-License-Identifier: Apache-2.0
description: |
LVGL encoder indev pseudo-device
Listens for button/encoder input events and routes the
lv_indev_data_t to the underlying encoder lv_indev_t managed by LVGL.
Example configuration:
encoder {
compatible = "zephyr,lvgl-encoder-input";
rotation-input-code = <INPUT_REL_Y>;
button-input-code = <INPUT_KEY_0>;
};
compatible: "zephyr,lvgl-encoder-input"
include: zephyr,lvgl-common-input.yaml
properties:
rotation-input-code:
type: int
required: true
description: |
Input event code associated with rotation (INPUT_REL_*).
button-input-code:
type: int
description: |
Input event key code for encoder button (INPUT_KEY_* or INPUT_BTN_*).