mirror of
https://github.com/espressif/esp-idf.git
synced 2026-09-22 13:01:16 +03:00
- Remove the EXAMPLE_LCD_IMAGE_SOURCE Kconfig option (embedded binary vs
file system) and always load images from LittleFS.
- Convert the PNG images into LZ4-compressed LVGL binary images (.bin)
at
build time using LVGLImage.py, and flash them to a LittleFS partition.
- Upgrade lvgl to 9.6.0 and add the espressif/lz4 component; link the
external LZ4 library into lvgl.
- Split the example: main.c focuses on the esp_lcd i80 API, while the
LVGL
porting (lvgl_port.c) and the UI (lvgl_demo_ui.c) live in separate
files.
- Rework the demo animation to use the LVGL animation engine (lv_anim)
with
easing paths instead of a manual software timer for smoother
rendering.
- Remove the embedded C image arrays (esp_logo.c, esp_text.c) and the
obsolete sdkconfig.ci.image_in_{bin,fs} variants.
20 lines
730 B
CMake
20 lines
730 B
CMake
# LVGLImage.py needs pypng and lz4. Install them into the IDF Python env
|
|
# when this example is configured, instead of adding them to IDF requirements.
|
|
|
|
idf_build_get_property(python PYTHON)
|
|
execute_process(
|
|
COMMAND ${python} -c "import png, lz4.block"
|
|
RESULT_VARIABLE example_lvgl_image_py_ok
|
|
OUTPUT_QUIET
|
|
ERROR_QUIET)
|
|
|
|
if(NOT example_lvgl_image_py_ok EQUAL 0)
|
|
message(STATUS "Installing pypng and lz4 for LVGL image conversion")
|
|
execute_process(
|
|
COMMAND ${python} -m pip install pypng lz4
|
|
RESULT_VARIABLE example_lvgl_image_pip_ok)
|
|
if(NOT example_lvgl_image_pip_ok EQUAL 0)
|
|
message(FATAL_ERROR "Failed to install pypng and lz4 (required by LVGLImage.py)")
|
|
endif()
|
|
endif()
|