LVGL implementation into STM32 project - multiple errors - have I done the conf correctly?

This is what i usually do, to use LVGL in an STM32 project (not using STM32CubeIDE but is using vanilla Eclipse with https://eclipse-embed-cdt.github.io/. Transitioning to VsCode “CMake” at the moment…

  • Create a Folder named lvgl and a subfolder named lvgl.

  • Copy the lv_conf_template.h to the root of the first lvgl folder and rename to lv_conf.h

    • lv_conf.h needs to be on subfolder where lvgl source is located…
  • Change the #if in line 15 to 1 to enable the configuration, and adjust the rest as needed based on hardware / Display

  • Inside the Subdirectory lvgl, for my uses cases i just use the src folder and the *.h files on LVGL source root, but you can have the rest, just delete the tests and docs folders to reduce “garbage” not required and avoid extra c files to be parsed/compiled by the compiler, or exclude those extra folders from the IDE directly.

  • No “prepocessors” directives are required to be added

  • Just need to add two include directories to compiler
    image

  • After that just use #include "lvgl.h" in the source code where we want to use.
    My folder structure on the PC looks like this:

1 Like