Fix: move Tab5 display rotation from display config to lvgl config - #106
Open
lboue wants to merge 2 commits into
Open
Fix: move Tab5 display rotation from display config to lvgl config#106lboue wants to merge 2 commits into
lboue wants to merge 2 commits into
Conversation
ESPHome now rejects `rotation` under the mipi_dsi display config when LVGL manages the display, failing config validation with: "use of 'rotation' in the display config is not compatible with LVGL, please set rotation in the LVGL config instead." Move the existing 270° rotation to `lvgl.rotation` to restore a working config.
LVGL now performs the 270° display rotation itself (since rotation moved from `display:` to `lvgl:`), and it already rotates touch input to match via LvglComponent::rotate_coordinates(). The touchscreen's own `transform: swap_xy + mirror_x` (combined with the 1280x720 calibration bounds) is mathematically the same 270° rotation, so touches were being rotated twice — net ~180° off, explaining touches registering on the wrong widget (e.g. bottom instead of left nav rail). Drop the touchscreen-level transform and calibrate to the panel's native (pre-rotation) portrait resolution (720x1280) instead, so LVGL performs the rotation exactly once.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
ESPHome now rejects
rotationunder themipi_dsidisplay config when LVGL manages the display, failingesphome configwith:#99
This currently breaks
common/tab5-ha-hmi.yamlon recent ESPHome releases (confirmed against 2026.7.4 and 2026.8.0-dev).Fix
Move the existing
rotation: 270°fromdisplay:tolvgl.rotation: 270.Testing
Validated with
esphome config(both a fresh 2026.7.4 install and a 2026.8.0-dev environment) — config now loads successfully instead of failing.