Align touch and draw in one 320x240 space like CYD LVGL9.

Drop LVGL ROTATION_270 double-transform; SoftSPI rot3 maps directly to screen pixels.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-10-17 18:14:26 +08:00
parent 3768e545c0
commit 1381c221d9
7 changed files with 72 additions and 45 deletions

View File

@@ -21,10 +21,8 @@
#define CYD_TOUCH_CLK 25
#define CYD_TOUCH_CS 33
// 物理竖屏分辨率(TFT 驱动)
#define SCREEN_WIDTH 240
#define SCREEN_HEIGHT 320
// 横屏逻辑分辨率(LV_DISPLAY_ROTATION_270)
#define UI_HOR_RES 320
#define UI_VER_RES 240
// 横屏 UI(与 witnessmenow CYD LVGL9 官方例程一致:直接 320x240,不用 LVGL 二次旋转)
#define SCREEN_WIDTH 320
#define SCREEN_HEIGHT 240
#define UI_HOR_RES SCREEN_WIDTH
#define UI_VER_RES SCREEN_HEIGHT