I’m new to the LVGL world. I tried to use STM’s TouchGFX but it’s way too complicated plus it’s written in C++ and I’d like to stay in the C universe. The STM32 page (STM32 — LVGL documentation) isn’t the most beginner friendly help page. I’m working on the STM32F769I-Disco board.
I understand the first two lines of the help screen:
Create or open a project in STM32CubeIDE. <— Did this
Copy the entire LVGL folder to [project_folder]/Drivers/lvgl. ← Did this
I downloaded the LVGL-master files from Github.
I copied the whole LVGL-master directory to the Project/Drivers/LVGL directory.
I added the following two lines to the include paths:
…/Drivers/LVGL/core
…/Drivers/LVGL
But when I try and compile an initial project I get the following error:
…/Drivers/LVGL/widgets/win/lv_win.h:16:10: fatal error: …/…/…/lvgl.h: No such file or directory
What do I need to do to fix this?
Is there a simple Hello World example using the STM32CubeIDE out there somewhere?
I’m still clueless on how I’m supposed to set up the project in STM32CubeIDE.
First, am I supposed to use version 9.0 or 8.3? When I click on the “download” link on the “Get the library” it defaults to the dev level 9.0. Is this stable enough to use even for a beginner like me?
All I want to do is manage a “Hello World” type of example.
Basic example to create a “Hello world” label
*/
void lv_example_get_started_1(void)
{
/Change the active screen’s background color/
lv_obj_set_style_bg_color(lv_scr_act(), lv_color_hex(0x003a57), LV_PART_MAIN);
/Create a white label, set its text and align it to the center/
lv_obj_t * label = lv_label_create(lv_scr_act());
lv_label_set_text(label, “Hello world”);
lv_obj_set_style_text_color(lv_scr_act(), lv_color_hex(0xffffff), LV_PART_MAIN);
lv_obj_align(label, LV_ALIGN_CENTER, 0, 0);
}
#endif
What files or directories do I need in my project to run this example?
This repository also uses the STM32F769I-DISCO board and has examples for STM32CubeIDE and IAR Compilers.
Here LVGL is added as a submodule, inside the ThirdParty folder, and you can still use CubeMX to generate the code related to other peripherals.
I have spent way too many hours trying to get the code to compile. I have tried LVGL_Sample2 but I’m getting 426 errors. What version of LVGL did you use?
All I want to do is a simple “Hello World” program using STMCubeIDE and the STM32F769-Discovery board.
Are there any examples out there? I need to be able to use the setup .IOC file.