• sales

    +86-0755-88291180

EMO_PIC/esp_bsp.c lv_port.h:47:5: error: unknown type name 'lv_disp_rot_t'

2025-02-25 03:50:35 Ask

1-Demo/Demo_Arduino/DEMO_PIC/esp_bsp.c:28:

lv_port.h:47:5: error: unknown type name 'lv_disp_rot_t'

  47 |     lv_disp_rot_t   sw_rotate;    /* Panel software rotate_mask */

     |     ^~~~~~~~~~~~~

In file included from /media/sf_SharedFolder/1-Demo/Demo_Arduino/DEMO_PIC/esp_bsp.c:30:

esp_bsp.h:59:5: error: unknown type name 'lv_disp_rot_t'

  59 |     lv_disp_rot_t rotate;           /*!< Rotation configuration for the display */

     |     ^~~~~~~~~~~~~

esp_bsp.c:79:5: error: unknown type name 'lv_disp_rot_t'

  79 |     lv_disp_rot_t rotate;               /*!< Rotation configuration for the display */

     |     ^~~~~~~~~~~~~

/media/sf_SharedFolder/1-Demo/Demo_Arduino/DEMO_PIC/esp_bsp.c: In function 'bsp_display_lcd_init':

esp_bsp.c:367:31: error: 'LV_DISP_ROT_180' undeclared (first use in this function); did you mean 'LV_DISP_ROTATION_180'?

 367 |     if (disp_cfg.sw_rotate == LV_DISP_ROT_180 || disp_cfg.sw_rotate == LV_DISP_ROT_NONE) {

     |                               ^~~~~~~~~~~~~~~

     |                               LV_DISP_ROTATION_180

/media/sf_SharedFolder/1-Demo/Demo_Arduino/DEMO_PIC/esp_bsp.c:367:31: note: each undeclared identifier is reported only once for each function it appears in

esp_bsp.c:367:72: error: 'LV_DISP_ROT_NONE' undeclared (first use in this function); did you mean 'LV_DIR_NONE'?

 367 |     if (disp_cfg.sw_rotate == LV_DISP_ROT_180 || disp_cfg.sw_rotate == LV_DISP_ROT_NONE) {

     |                                                                        ^~~~~~~~~~~~~~~~

     |                                                                        LV_DIR_NONE

/media/sf_SharedFolder/1-Demo/Demo_Arduino/DEMO_PIC/esp_bsp.c: In function 'bsp_touch_process_points_cb':

esp_bsp.c:413:13: error: 'LV_DISP_ROT_270' undeclared (first use in this function); did you mean 'LV_DISP_ROTATION_270'?

 413 |         if (LV_DISP_ROT_270 == touch_handle->rotate) {

     |             ^~~~~~~~~~~~~~~

     |             LV_DISP_ROTATION_270

esp_bsp.c:417:20: error: 'LV_DISP_ROT_180' undeclared (first use in this function); did you mean 'LV_DISP_ROTATION_180'?

 417 |         } else if (LV_DISP_ROT_180 == touch_handle->rotate) {

     |                    ^~~~~~~~~~~~~~~

     |                    LV_DISP_ROTATION_180

esp_bsp.c:421:20: error: 'LV_DISP_ROT_90' undeclared (first use in this function); did you mean 'LV_DISP_ROTATION_90'?

 421 |         } else if (LV_DISP_ROT_90 == touch_handle->rotate) {

     |                    ^~~~~~~~~~~~~~

     |                    LV_DISP_ROTATION_90

4answers
SpotPearGuest9a52c
Answer time:
2025-02-25 11:52:26

Did you copy and paste the library? What is the esp32 version? Did you replace the SD card files? How is the Arduino configured?

Like0

report

SpotPearGuestb2eb3
Answer time:
2025-02-26 01:09:37

Hello, thank you for your reply. I did forget them. Then I copied them. No more above errors, but still :

ResolveLibrary(process.h)

 -> candidates: []

/home/mt/Arduino/libraries/lvgl/src/osal/lv_windows.c:14:10: fatal error: process.h: No such file or directory

  14 | #include <process.h>

     |          ^~~~~~~~~~~

compilation terminated.

Like0

report

SpotPearGuest246b4
Answer time:
2025-02-26 16:28:08

http://pan.jczn1688.com/directlink/1/HMI%20display/JC3248W535EN.zip

Click the link to download the total information. It seems that you did not copy the library we provided to the library used by Arduino. In addition, what is the version of ESP32 in Arduino?

Like0

report

SpotPearGuest0502b
Answer time:
2025-02-27 00:03:12

Hello, thank you all for your replies. I finally fixed it with AI help. My environment is Arduino 1.8.18 on Ubuntu Mate.

The problem wasn't the specific libraries provided by the producer. It was a mismatch between the core ESP32 board version and LVGL library version. The good match in my case is :  esp32 3.1.3 (boards) and lvgl 8.3.11 (library)

Then I successfully compiled and run the DEMO_PIC.ino

Like0

report