chore: add an option to "LV_TICK_CUSTOM" (#3870)

This commit is contained in:
Forairaaaaa
2022-12-19 23:24:54 +08:00
committed by GitHub
parent 740eaa128f
commit ecafa88d2c
3 changed files with 8 additions and 1 deletions

View File

@@ -82,6 +82,9 @@
#if LV_TICK_CUSTOM
#define LV_TICK_CUSTOM_INCLUDE "Arduino.h" /*Header for the system time function*/
#define LV_TICK_CUSTOM_SYS_TIME_EXPR (millis()) /*Expression evaluating to current system time in ms*/
/*If using lvgl as ESP32 component*/
// #define LV_TICK_CUSTOM_INCLUDE "esp_timer.h"
// #define LV_TICK_CUSTOM_SYS_TIME_EXPR ((esp_timer_get_time() / 1000LL))
#endif /*LV_TICK_CUSTOM*/
/*Default Dot Per Inch. Used to initialize default sizes such as widgets sized, style paddings.