This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Using a Timer Expiry Function error " expected declaration specifiers or '...' before '&' token"

I am trying to make a function execute every 1 second using the provided example on the zephyr documentation, but i am getting the following error: "expected declaration specifiers or '...' before '&' token"
This is mu code:
```

void my_work_handler(struct k_work *work)
{
update_screen_values();
}

K_WORK_DEFINE(my_work, my_work_handler);

void my_timer_handler(struct k_timer *dummy)
{
k_work_submit(&my_work);
}

K_TIMER_DEFINE(my_timer, my_timer_handler, NULL);


k_timer_start(&my_timer..., K_SECONDS(1), K_SECONDS(1));
```

Parents Reply Children
No Data
Related