Closed zhjygit closed 2 months ago
I think the issue is in the LovyanGFX configuration. If you are using the MAKERF_ESP32S3 environment, you need to be aware that there are same GPIOs configured in the TFT. Are you using a TFT? If so, you should configure it in the file https://github.com/jgauchia/IceNav-v3/blob/master/lib/makefabs-esp32s3parallel/LGFX_MakerFabs_Parallel_S3.hpp
You can comment this too:
init_LVGL(); init_tft();
I don't know if you're using a TFT or what type it is.
I have no MAKERF_ESP32S3 board(I cannot buy it some reasons), here is my board: 4.3寸开发板原理图.pdf I thing the key difference is the sd card with sdmmc type; MAKERF_ESP32S3 board is the spicard, when the lvgl api draw pictures from sd card, the sdmmc type api is different from spi type, so, it failed with errors above.
When i changed the code from "xxx SD.xxx" to "xxx SD_MMC xxx", a lot of errors occur.
In file included from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/esp32/Light_PWM.hpp:20, from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/device.hpp:41, from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1_init.hpp:22, from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/LovyanGFX.hpp:31, from lib/makefabs-esp32s3parallel/LGFX_MakerFabs_Parallel_S3.hpp:11, from src/hardware/tft.h:18, from src/main.cpp:30: .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/esp32/../../Light.hpp:22:1: error: expected ',' or ';' before 'namespace' namespace lgfx ^~~~~~~~~ In file included from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/device.hpp:41, from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1_init.hpp:22, from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/LovyanGFX.hpp:31, from lib/makefabs-esp32s3parallel/LGFX_MakerFabs_Parallel_S3.hpp:11, from src/hardware/tft.h:18, from src/main.cpp:30: .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/esp32/Light_PWM.hpp:29:3: error: expected class-name before '{' token { ^ .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/esp32/Light_PWM.hpp:45:10: error: 'bool lgfx::v1::Light_PWM::init(uint8_t)' marked 'override', but does not override bool init(uint8_t brightness) override; ^~~~ .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/esp32/Light_PWM.hpp:46:10: error: 'void lgfx::v1::Light_PWM::setBrightness(uint8_t)' marked 'override', but does not override void setBrightness(uint8_t brightness) override; ^~~~~~~~~~~~~ .pio/libdeps/MAKERF_ESP32S3/lvgl/src/core/lv_obj.c: In function 'lv_init': Archiving .pio\build\MAKERF_ESP32S3\lib238\libTinyGPSPlus.a .pio/libdeps/MAKERF_ESP32S3/lvgl/src/core/lv_obj.c:152:18: warning: initialization discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers] char * txt = "Á"; ^~~~ Indexing .pio\build\MAKERF_ESP32S3\lib238\libTinyGPSPlus.a Compiling .pio\build\MAKERF_ESP32S3\lib93f\lvgl\core\lv_obj_pos.c.o Compiling .pio\build\MAKERF_ESP32S3\lib93f\lvgl\core\lv_obj_scroll.c.o Compiling .pio\build\MAKERF_ESP32S3\lib93f\lvgl\core\lv_obj_style.c.o Compiling .pio\build\MAKERF_ESP32S3\lib93f\lvgl\core\lv_obj_style_gen.c.o Compiling .pio\build\MAKERF_ESP32S3\lib93f\lvgl\core\lv_obj_tree.c.o Compiling .pio\build\MAKERF_ESP32S3\lib93f\lvgl\core\lv_refr.c.o Archiving .pio\build\MAKERF_ESP32S3\lib77c\libTime.a Indexing .pio\build\MAKERF_ESP32S3\lib77c\libTime.a In file included from src/gui/screens/Main/main_scr.h:44, from src/gui/lvgl.h:53, from src/main.cpp:47: src/gui/screens/Main/events/main_scr.h:40:34: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings] MapTile OldMapTile = {"", 0, 0, 0}; ^ Compiling .pio\build\MAKERF_ESP32S3\lib93f\lvgl\core\lv_theme.c.o In file included from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1_init.hpp:25, from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/LovyanGFX.hpp:31, from lib/makefabs-esp32s3parallel/LGFX_MakerFabs_Parallel_S3.hpp:11, from src/hardware/tft.h:18, from src/main.cpp:30: .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/LGFXBase.hpp: In instantiation of 'bool lgfx::v1::LGFXBase::drawPngFile(T&, const char*, int32_t, int32_t, int32_t, int32_t, int32_t, int32_t, float, float, lgfx::v1::datum::datum_t) [with T = fs::SDMMCFS; int32_t = int; lgfx::v1::datum::datum_t = lgfx::v1::textdatum::textdatum_t]': src/gui/screens/Main/events/map.h:157:74: required from here .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/LGFXBase.hpp:888:23: error: cannot declare variable 'file' to be of abstract type 'lgfx::v1::DataWrapperT<fs::SDMMCFS>' DataWrapperT<T> file ( &fs ); \ ^~~~ .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/LGFXBase.hpp:896:5: note: in expansion of macro 'LGFX_FUNCTION_GENERATOR' LGFX_FUNCTION_GENERATOR(drawPng, draw_png) ^~~~~~~~~~~~~~~~~~~~~~~ In file included from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/esp32/../esp32/common.hpp:20, from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/esp32/../common.hpp:22, from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/esp32/Bus_SPI.hpp:57, from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/device.hpp:42, from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1_init.hpp:22, from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/LovyanGFX.hpp:31, from lib/makefabs-esp32s3parallel/LGFX_MakerFabs_Parallel_S3.hpp:11, from src/hardware/tft.h:18, from src/main.cpp:30: .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/esp32/../esp32/../../misc/DataWrapper.hpp:91:10: note: because the following virtual functions are pure within 'lgfx::v1::DataWrapperT<fs::SDMMCFS>': struct DataWrapperT : public DataWrapper { ^~~~~~~~~~~~ .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/esp32/../esp32/../../misc/DataWrapper.hpp:72:17: note: 'virtual int lgfx::v1::DataWrapper::read(uint8_t*, uint32_t)' virtual int read(uint8_t *buf, uint32_t len) = 0; ^~~~ .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/esp32/../esp32/../../misc/DataWrapper.hpp:74:18: note: 'virtual void lgfx::v1::DataWrapper::skip(int32_t)' virtual void skip(int32_t offset) = 0; ^~~~ .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/esp32/../esp32/../../misc/DataWrapper.hpp:75:18: note: 'virtual bool lgfx::v1::DataWrapper::seek(uint32_t)' virtual bool seek(uint32_t offset) = 0; ^~~~ .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/esp32/../esp32/../../misc/DataWrapper.hpp:76:18: note: 'virtual void lgfx::v1::DataWrapper::close()' virtual void close(void) = 0; ^~~~~ .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/platforms/esp32/../esp32/../../misc/DataWrapper.hpp:77:21: note: 'virtual int32_t lgfx::v1::DataWrapper::tell()' virtual int32_t tell(void) = 0;
Here is my sdmmccard.h:
project.zip As I said above, I used the sdmmc card type, with 4.3 tft lcd screen, the data sheet is as above 4.3寸开发板原理图.pdf Waiting for you reply.
Not SDMMC supported, only listed boards and specs
Hi sir, i have no makerfabs esp32s3 board, my board is as the save, however the sd card is sdmmc type :![image](https://github.com/jgauchia/IceNav-v3/assets/44870751/a9b42f16-1b3f-4d69-9c70-130eafe21946)
I changed the main.cpp as follows:
_**
**_
When i compile the code, the errors is src/gui/screens/Main/events/main_scr.h:40:34: warning: ISO C++ forbids converting a string constant to 'char' [-Wwrite-strings] MapTile OldMapTile = {"", 0, 0, 0}; ^ In file included from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1_init.hpp:25, from .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/LovyanGFX.hpp:31, from lib/makefabs-esp32s3parallel/LGFX_MakerFabs_Parallel_S3.hpp:11, from src/hardware/tft.h:14, from src/main.cpp:32: .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/LGFXBase.hpp: In instantiation of 'bool lgfx::v1::LGFXBase::drawPngFile(T&, const char, int32_t, int32_t, int32_t, int32_t, int32_t, int32_t, float, float, lgfx::v1::datum::datum_t) [with T = fs::SDMMCFS; int32_t = int; lgfx::v1::datum::datum_t = lgfx::v1::textdatum::textdatum_t]': src/gui/screens/Main/events/map.h:158:74: required from here .pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/LGFXBase.hpp:888:23: error: cannot declare variable 'file' to be of abstract type 'lgfx::v1::DataWrapperT'
DataWrapperT file ( &fs ); \
^~~~
.pio/libdeps/MAKERF_ESP32S3/LovyanGFX/src/lgfx/v1/LGFXBase.hpp:896:5: note: in expansion of macro 'LGFX_FUNCTION_GENERATOR'
LGFX_FUNCTION_GENERATOR(drawPng, draw_png)
![image](https://github.com/jgauchia/IceNav-v3/assets/44870751/366d57c1-0302-46d3-be84-4a2123af3bc9)
Waiting for you reply.