50 lines
1.3 KiB
C
50 lines
1.3 KiB
C
/*
|
||
lvgl Task
|
||
|
||
*/
|
||
|
||
/* Includes ----------------------------------------------------------------- */
|
||
#include "task/user_task.h"
|
||
/* USER INCLUDE BEGIN */
|
||
#include "lvgl/lvgl.h"
|
||
#include "lvgl/stress/lv_demo_stress.h"
|
||
#include "lvgl/examples/porting/lv_port_disp_template.h"
|
||
#include "LCD/lcd.h"
|
||
/* USER INCLUDE END */
|
||
|
||
/* Private typedef ---------------------------------------------------------- */
|
||
/* Private define ----------------------------------------------------------- */
|
||
/* Private macro ------------------------------------------------------------ */
|
||
/* Private variables -------------------------------------------------------- */
|
||
/* USER STRUCT BEGIN */
|
||
|
||
/* USER STRUCT END */
|
||
|
||
/* Private function --------------------------------------------------------- */
|
||
/* Exported functions ------------------------------------------------------- */
|
||
void Task_lvgl(void *argument) {
|
||
(void)argument; /* 未使用argument,消除警告 */
|
||
|
||
lcd_init();
|
||
lv_init();
|
||
|
||
lv_port_disp_init();
|
||
|
||
lv_demo_stress();
|
||
// osDelay(LVGL_INIT_DELAY); /* 延时一段时间再开启任务 */
|
||
|
||
/* USER CODE INIT BEGIN */
|
||
|
||
/* USER CODE INIT END */
|
||
|
||
while (1) {
|
||
// lcd_fill(100, 100,200,200,RED);
|
||
lv_task_handler();
|
||
// lv_timer_handler();
|
||
/* USER CODE BEGIN */
|
||
|
||
/* USER CODE END */
|
||
}
|
||
|
||
}
|