From f7dfa7db72e089ce919d4bbf3dacab7f10a4aa6e Mon Sep 17 00:00:00 2001 From: fvanroie Date: Thu, 22 Jul 2021 18:50:58 +0200 Subject: [PATCH] Use LV_TICK_CUSTOM only on Arduino --- include/lv_conf_v8.h | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/include/lv_conf_v8.h b/include/lv_conf_v8.h index ab8c9071..084d6eb0 100644 --- a/include/lv_conf_v8.h +++ b/include/lv_conf_v8.h @@ -79,10 +79,15 @@ /*Use a custom tick source that tells the elapsed time in milliseconds. *It removes the need to manually update the tick with `lv_tick_inc()`)*/ +#ifdef ARDUINO #define LV_TICK_CUSTOM 1 +#else +#define LV_TICK_CUSTOM 0 +#endif + #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*/ +#define LV_TICK_CUSTOM_INCLUDE "Arduino.h" /*Header for the sys time function*/ +#define LV_TICK_CUSTOM_SYS_TIME_EXPR (millis()) /*Expression evaluating to current systime in ms*/ #endif /*LV_TICK_CUSTOM*/ /*Default Dot Per Inch. Used to initialize default sizes such as widgets sized, style paddings.