Description
I’ve just downloaded the getting started code from the Waveshare Wiki, and am running into compilation errors… is there issues with the code or with my setup?
What MCU/Processor/Board and compiler are you using?
Waveshare ESP32-S3-Touch-LCD-2.8C
What have you tried so far?
I traced the rabbit hole of trying to fix the include errors thrown but kept getting new errors so wondering if there is something fundamentally wrong with my setup. I redownloaded a clean version and am back at square one…
Screenshot and/or video
Thanks!
Hi. Welcome to the community!
I also have a similar round display from Waveshare and had to made some changes to the example so it would be compatible with LVGL v9.
You can check it here: GitHub - giobauermeister/waveshare-round-esp32-lvgl: Template project for Waveshare 2.1 round display with support for LVGL v9 and ESP-IDF v5
Thanks! Good to know the example doesn’t work out of the box and it isn’t just me.
I’m having some issues with the include statements at the top of the main script. I’m compiling it through the Arduino IDE if that makes any difference. For example,
#include “TCA9554PWR.h” as well as
#include “PCF85063.h”
I see here that all the header files are alongside the main .ino file in the example. That should usually work.
LVGL_Arduino $ ls
BAT_Driver.cpp Display_ST7701.cpp Gyro_QMI8658.cpp I2C_Driver.cpp LVGL_Arduino.ino LVGL_Driver.h LVGL_Example.h RTC_PCF85063.h SD_Card.h TCA9554PWR.h Touch_GT911.h Wireless.h
BAT_Driver.h Display_ST7701.h Gyro_QMI8658.h I2C_Driver.h LVGL_Driver.cpp LVGL_Example.cpp RTC_PCF85063.cpp SD_Card.cpp TCA9554PWR.cpp Touch_GT911.cpp Wireless.cpp
Is Arduino IDE not able to find those files?
Perhaps you could get a better answer in the Arduino forum about Arduino IDE project structure
Thanks! I needed to move the files into a libraries folder which is all sorted now. Unfortunately I’m getting a veeerrry long list of errors now:
Blockquote
In file included from c:\Users.…\Downloads\waveshare-round-esp32-lvgl-main\main\libraries\LCD_Driver/ST7701S.h:13,
from C:\Users.…\Downloads\waveshare-round-esp32-lvgl-main\main\main.ino:9:
c:\Users.…\Downloads\waveshare-round-esp32-lvgl-main\main\libraries\LVGL_Driver/LVGL_Driver.h:20:8: error: ‘lv_display_t’ does not name a type; did you mean ‘lv_disp_t’?
20 | extern lv_display_t *disp;
| ^~~~~~~~~~~~
| lv_disp_t
c:\Users.…\Downloads\waveshare-round-esp32-lvgl-main\main\libraries\LVGL_Driver/LVGL_Driver.h:22:6: error: variable or field ‘example_lvgl_flush_cb’ declared void
22 | void example_lvgl_flush_cb(lv_display_t *disp, const lv_area_t *area, uint8_t *px_map);
| ^~~~~~~~~~~~~~~~~~~~~
c:\Users.…\Downloads\waveshare-round-esp32-lvgl-main\main\libraries\LVGL_Driver/LVGL_Driver.h:22:28: error: ‘lv_display_t’ was not declared in this scope; did you mean ‘lv_disp_t’?
22 | void example_lvgl_flush_cb(lv_display_t *disp, const lv_area_t *area, uint8_t *px_map);
| ^~~~~~~~~~~~
| lv_disp_t
c:\Users.…\Downloads\waveshare-round-esp32-lvgl-main\main\libraries\LVGL_Driver/LVGL_Driver.h:22:42: error: ‘disp’ was not declared in this scope
22 | void example_lvgl_flush_cb(lv_display_t *disp, const lv_area_t *area, uint8_t *px_map);
| ^~~~
c:\Users.…\Downloads\waveshare-round-esp32-lvgl-main\main\libraries\LVGL_Driver/LVGL_Driver.h:22:48: error: expected primary-expression before ‘const’
22 | void example_lvgl_flush_cb(lv_display_t *disp, const lv_area_t *area, uint8_t px_map);
| ^~~~~
c:\Users.…\Downloads\waveshare-round-esp32-lvgl-main\main\libraries\LVGL_Driver/LVGL_Driver.h:22:79: error: expected primary-expression before '’ token
22 | void example_lvgl_flush_cb(lv_display_t *disp, const lv_area_t *area, uint8_t *px_map);
| ^
c:\Users.…\Downloads\waveshare-round-esp32-lvgl-main\main\libraries\LVGL_Driver/LVGL_Driver.h:22:80: error: ‘px_map’ was not declared in this scope; did you mean ‘lv_map’?
22 | void example_lvgl_flush_cb(lv_display_t *disp, const lv_area_t *area, uint8_t *px_map);
| ^~~~~~
| lv_map
C:\Users.…\Downloads\waveshare-round-esp32-lvgl-main\main\main.ino: In function ‘void Driver_Init()’:
C:\Users.…\Downloads\waveshare-round-esp32-lvgl-main\main\main.ino:32:5: error: ‘Flash_Searching’ was not declared in this scope
32 | Flash_Searching();
| ^~~~~~~~~~~~~~~
C:\Users.…\Downloads\waveshare-round-esp32-lvgl-main\main\main.ino: In function ‘void app_main()’:
C:\Users.…\Downloads\waveshare-round-esp32-lvgl-main\main\main.ino:52:5: error: ‘SD_Init’ was not declared in this scope; did you mean ‘LCD_Init’?
52 | SD_Init();
| ^~~~~~~
| LCD_Init
Multiple libraries were found for “SD_MMC.h”
Used: C:\Users.…\AppData\Local\Arduino15\packages\esp32-XIP-3.0.2\hardware\esp32\3.0.2\libraries\SD_MMC
Not used: C:\Users.…\Downloads\waveshare-round-esp32-lvgl-main\main\Libraries\SD_Card
exit status 1
Compilation error: ‘Flash_Searching’ was not declared in this scope