Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Software rotation with esp_lvgl_port on ESP32-P4 with ILI9881C display #400

Open
1 task done
dmartauz opened this issue Sep 27, 2024 · 2 comments
Open
1 task done
Labels
Area: LVGL related to LVGL and LVGL port Type: Bug Something isn't working

Comments

@dmartauz
Copy link

dmartauz commented Sep 27, 2024

Board

ESP32-P4-Function-EV-Board

Hardware Description

ILI9881C touchscreen display (8" 800 x 1280 pixels)

IDE Name

esp-idf/master

Operating System

Windows 10

Description

The display natively works in portrait orientation and it is displaying simple tabview. In this orientation it works well.

IMG_20240927_201910708

Because I want to use it in landscape orientation and it seems that ILI9881C does not support hardware rotation I am attempting to use .sw_rotate = true and after uncommenting last line of the code it seems that first rotated frame is drawn correctly but following frames have some offset (shifted LVGL FPS tracker).

IMG_20240927_202104171

After clicking on the tabview also tabview buttons get shifted.

IMG_20240927_202144160

Is master branch of esp_lvgl_port already using PPA in case of ESP32-P4?

Sketch

    const lvgl_port_display_cfg_t disp_cfg = {
        .io_handle = mipi_dbi_io,
        .panel_handle = mipi_dpi_panel,
        .buffer_size = EXAMPLE_MIPI_DSI_LCD_V_RES * EXAMPLE_MIPI_DSI_LCD_H_RES, //EXAMPLE_LVGL_DRAW_BUF_LINES
        .double_buffer = true,
        .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 = false,
            .buff_spiram = true,
            .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_270);

Other Steps to Reproduce

No response

I have checked existing issues, README.md and ESP32 Forum

  • I confirm I have checked existing issues, online documentation and Troubleshooting guide.
@dmartauz dmartauz added Status: Awaiting triage Type: Bug Something isn't working labels Sep 27, 2024
@github-actions github-actions bot changed the title esp_lvgl_port on ESP32-P4 with ILI9881C display esp_lvgl_port on ESP32-P4 with ILI9881C display (BSP-557) Sep 27, 2024
@dmartauz dmartauz changed the title esp_lvgl_port on ESP32-P4 with ILI9881C display (BSP-557) Software rotation with esp_lvgl_port on ESP32-P4 with ILI9881C display Sep 27, 2024
@espzav
Copy link
Collaborator

espzav commented Sep 30, 2024

Hi @dmartauz thank you for reporting this issue. I will check it soon and fix it. The master branch is not using PPA yet, because after performance measurement, the SW rotation was faster than PPA because we are rotationg only small pieces of the whole screen. We are still working on improving performance and looking for the best solution. The PPA rotation is used in this PR: #352

@espzav espzav added Area: LVGL related to LVGL and LVGL port and removed Status: Awaiting triage labels Sep 30, 2024
@dmartauz
Copy link
Author

dmartauz commented Oct 6, 2024

@espzav any update on the fix? In the meantime I am porting my application from S3 with 800x480 parallel display.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: LVGL related to LVGL and LVGL port Type: Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants