Skip to content

esp_lvgl_port: 90/270 degree software rotation issue (BSP-732) #665

@dmartauz

Description

@dmartauz

Board

custom board with ESP32-P4 with ILI9881C MIPI display

Hardware Description

  • custom board with ESP32-P4 (revision 1.3)
  • ILI9881C-based LCD

IDE Name

No IDE, just idf.py

Operating System

Windows 10

Description

I am using 800x1280 ILI9881C-based LCD in landscape orientation. Because the controller does not support hardware rotation I am using software implementation.

IDF version: esp-idf-master branch, commit ab149384e12ace1b8e8f7858d52ae47ab8af4563 (latest as of today October 24)
esp_lvgl_port version: 2.6.2
lvgl version: 9.4.0

Simple Hello world screen is rendered correctly with LV_DISPLAY_ROTATION_0 or LV_DISPLAY_ROTATION_180.

However with LV_DISPLAY_ROTATION_90 or LV_DISPLAY_ROTATION_270 I am encountering this issue:

I (3156) LVGL: Starting LVGL task
I (3156) example: Add LCD screen
Guru Meditation Error: Core  0 panic'ed (Load access fault). Exception was unhandled.

--- Stack dump detected
Core  0 register dump:
MEPC    : 0x4fc19f54  RA      : 0x4009c8ae  SP      : 0x4ff3dfd0  GP      : 0x4ff16400
--- 0x4009c8ae: dpi_panel_draw_bitmap at C:/Espressif/frameworks/esp-idf-master/components/esp_lcd/dsi/esp_lcd_panel_dpi.c:542

Sketch

        .io_handle = mipi_dbi_io,
        .panel_handle = mipi_dpi_panel,
        .buffer_size =  EXAMPLE_MIPI_DSI_LCD_V_RES * EXAMPLE_MIPI_DSI_LCD_H_RES / 20,
        .double_buffer = false,
        .hres = EXAMPLE_MIPI_DSI_LCD_H_RES,
        .vres = EXAMPLE_MIPI_DSI_LCD_V_RES,
        .monochrome = false,
        .color_format = LV_COLOR_FORMAT_RGB565,
        .rotation = {
            .swap_xy = false,
            .mirror_x = false,
            .mirror_y = false,
        },
        .flags = {
            .buff_dma = true,
            .buff_spiram = false,
            .sw_rotate = true,
            .swap_bytes = false,
            .full_refresh = false,
            .direct_mode = false,
        }
    };

    const lvgl_port_display_dsi_cfg_t disp_dsi_cfg;

    lvgl_display = lvgl_port_add_disp_dsi(&disp_cfg, &disp_dsi_cfg);
    lv_display_set_rotation(lvgl_display, LV_DISPLAY_ROTATION_90);

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions