Question
Please explain why I get errors here even after I have added include files?
Hi Folks,
I'm getting an error that is driving me crazy. The first occurrence of the variable is OK but the next one is flagged as "
"undefined reference to `lv_disp_get_default'"
static inline struct _lv_obj_t * lv_layer_top(void)
{
return lv_disp_get_layer_top(lv_disp_get_default());
}
static inline struct _lv_obj_t * lv_scr_act(void)
{
return lv_disp_get_scr_act(lv_disp_get_default()); <---- Error here
}
Why would the second "lv_disp_get_default()" cause an error when the first one doesn't?
This is in lv_disp.h file. the lv_disp_get_default() is defined in the lv_disp.c file.
lv_disp_t * lv_disp_get_default(void)
{
return disp_def;
}
Any ideas what I can try to resolve this issue?
Thanks,
Richard
