What do you want to achieve?
I created with SLS an event calling a function whose purpose is, at screen load, to change a widget’s color stored in deep-sleep memory. The function is declared in ui_events.c.
void ColorSaveScreen(lv_event_t * e)
Now I want to call that same function from my main .ino code to immediately update the widget’s color on the screen when the code changes it.
However if I call the function from my .ino sketch I get errors such as
“lv_event_t not defined in this scope”
“e not defined in this scope”
What have you tried so far?
I tried defining the function also in my .ino file whith the “extern” modifier
extern void ColorSaveScreen(lv_event_t * e);
It seems to work because the “go to definition” command shows the ui_event.c file correctly, but later in the code when I call the function I get the same error on compile and the “go to definition” command doesn’t work.
Others
- SquareLine Studio version: latest
- Operating system: windows 11
- Target hardware: ESP 32