Thanks, @Marian_M for your reply.
I tried your suggestion and I copied the animation definition and code from ui.c
file :
void PacmanRotation_Animation(lv_obj_t * TargetObject, int delay);
lv_obj_t * ui_ImgPacman;
and
void PacmanRotation_Animation(lv_obj_t * TargetObject, int delay)
{
ui_anim_user_data_t * PropertyAnimation_0_user_data = lv_malloc(sizeof(ui_anim_user_data_t));
PropertyAnimation_0_user_data->target = TargetObject;
PropertyAnimation_0_user_data->val = -1;
lv_anim_t PropertyAnimation_0;
lv_anim_init(&PropertyAnimation_0);
lv_anim_set_time(&PropertyAnimation_0, 30000);
lv_anim_set_user_data(&PropertyAnimation_0, PropertyAnimation_0_user_data);
lv_anim_set_custom_exec_cb(&PropertyAnimation_0, _ui_anim_callback_set_image_angle);
lv_anim_set_values(&PropertyAnimation_0, 0, 3600);
lv_anim_set_path_cb(&PropertyAnimation_0, lv_anim_path_linear);
lv_anim_set_delay(&PropertyAnimation_0, delay + 0);
lv_anim_set_deleted_cb(&PropertyAnimation_0, _ui_anim_callback_free_user_data);
lv_anim_set_playback_time(&PropertyAnimation_0, 0);
lv_anim_set_playback_delay(&PropertyAnimation_0, 0);
lv_anim_set_repeat_count(&PropertyAnimation_0, LV_ANIM_REPEAT_INFINITE);
lv_anim_set_repeat_delay(&PropertyAnimation_0, 0);
lv_anim_set_early_apply(&PropertyAnimation_0, false);
lv_anim_set_get_value_cb(&PropertyAnimation_0, &_ui_anim_callback_get_image_angle);
lv_anim_start(&PropertyAnimation_0);
}
with this function call before end of the setup()
function
PacmanRotation_Animation(ui_ImgPacman, 0);
but I get the following error:
I also tried to add extern
to the ui.h
file
extern void PacmanRotation_Animation(lv_obj_t * TargetObject, int delay);
but with this, I get this error:
Is it possible to fix my issue?
Many thanks for any help!