first commit
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
set(LV_DEMO_DIR ../managed_components/lvgl__lvgl/demos)
|
||||
file(GLOB_RECURSE LV_DEMOS_SOURCES ${LV_DEMO_DIR}/*.c)
|
||||
|
||||
idf_component_register(
|
||||
SRCS main.c ${LV_DEMOS_SOURCES}
|
||||
INCLUDE_DIRS . ${LV_DEMO_DIR})
|
||||
|
||||
idf_component_get_property(LVGL_LIB lvgl__lvgl COMPONENT_LIB)
|
||||
target_compile_options(
|
||||
${LVGL_LIB}
|
||||
PRIVATE
|
||||
-DLV_LVGL_H_INCLUDE_SIMPLE
|
||||
-DLV_USE_DEMO_MUSIC
|
||||
)
|
||||
@@ -0,0 +1,5 @@
|
||||
#
|
||||
# "main" pseudo-component makefile.
|
||||
#
|
||||
# (Uses default behaviour of compiling all source files in directory, adding 'include' to include path.)
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
## IDF Component Manager Manifest File
|
||||
dependencies:
|
||||
lvgl/lvgl:
|
||||
version: 9.2.*
|
||||
public: true
|
||||
espressif/esp_lcd_st7701: ^1.1.3
|
||||
espressif/esp_h264: ^1.1.2
|
||||
@@ -0,0 +1,45 @@
|
||||
/*
|
||||
* SPDX-FileCopyrightText: 2025 Espressif Systems (Shanghai) CO LTD
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
#include "nvs_flash.h"
|
||||
#include "nvs.h"
|
||||
#include "esp_log.h"
|
||||
#include "esp_err.h"
|
||||
#include "esp_check.h"
|
||||
#include "esp_event.h"
|
||||
#include "esp_system.h"
|
||||
#include "driver/uart.h"
|
||||
#include "esp_memory_utils.h"
|
||||
#include "lvgl.h"
|
||||
#include "bsp/esp-bsp.h"
|
||||
#include "bsp/display.h"
|
||||
#include "bsp_board_extra.h"
|
||||
#include "lv_demos.h"
|
||||
|
||||
void app_main(void)
|
||||
{
|
||||
bsp_display_cfg_t cfg = {
|
||||
.lvgl_port_cfg = ESP_LVGL_PORT_INIT_CONFIG(),
|
||||
.buffer_size = BSP_LCD_DRAW_BUFF_SIZE,
|
||||
.double_buffer = BSP_LCD_DRAW_BUFF_DOUBLE,
|
||||
.flags = {
|
||||
.buff_dma = true,
|
||||
.buff_spiram = false,
|
||||
.sw_rotate = true,
|
||||
}
|
||||
};
|
||||
bsp_display_start_with_config(&cfg);
|
||||
bsp_display_backlight_on();
|
||||
|
||||
bsp_display_lock(0);
|
||||
|
||||
|
||||
// lv_demo_music();
|
||||
// lv_demo_benchmark();
|
||||
lv_demo_widgets();
|
||||
|
||||
bsp_display_unlock();
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user