1
0
mirror of https://github.com/esphome/esphome.git synced 2025-09-01 19:02:18 +01:00

[lvgl] Fix compile error when using encoder with buttons only. (#7203)

This commit is contained in:
Clyde Stubbs
2024-08-07 05:15:28 +10:00
committed by GitHub
parent 8667f51cf0
commit eccc5a3ea3
9 changed files with 68 additions and 58 deletions

View File

@@ -24,6 +24,33 @@ display:
invert_colors: false
update_interval: never
binary_sensor:
- platform: gpio
internal: true
id: up_button
pin:
number: GPIO38
inverted: true
- platform: gpio
internal: true
id: down_button
pin:
number: GPIO37
inverted: true
- platform: gpio
internal: true
id: select_button
pin:
number: GPIO39
inverted: true
lvgl:
encoders:
group: switches
enter_button: select_button
sensor:
left_button: up_button
right_button: down_button
packages:
lvgl: !include lvgl-package.yaml

View File

@@ -67,7 +67,7 @@ lvgl:
displays:
- tft_display
- second_display
rotary_encoders:
encoders:
sensor: encoder
enter_button: pushbutton
group: general