[Logo] TCC discussion forum
  [Search] Search   [Recent Topics] Recent Topics   [Hottest Topics] Hottest Topics   [Top Downloads] Top Downloads   [Groups] Back to home page 
[Register] Register /  [Login] Login 

Pause task RSS feed
Forum Index » IoAbstraction & TaskManagerIO
Author Message
loczi1


Joined: Mar 3, 2022
Messages: 6
Offline
I have several tasks shceduled running fine, thanks for the TaskManager.
I have to execute once a long time consuming task (syncing large amount af data from the web).
Other task should wait until this is not done.
Can I somehow set the already sheduled task to do not execute at the scheduled time based the taskid_t?
Other solution would be cancelling the tasks of course..

Thanks!
davetcc


Joined: Jan 19, 2019
Messages: 606
Offline
Only one task will ever run at once anyway, once the long running task starts, unless you called yieldForMicros(..) nothing else would run.

However, you can suspend tasks using the following on the task manager object:

void setTaskEnabled(taskid_t task, bool ena);
loczi1


Joined: Mar 3, 2022
Messages: 6
Offline
Cheers Dave!
 
Forum Index » IoAbstraction & TaskManagerIO
Go to:   
Mobile view
Powered by JForum 2.7.0 © 2020 JForum Team • Maintained by Andowson Chang and Ulf Dittmer

This site uses cookies to analyse traffic, serve ads by Google AdSense (non-personalized in EEA/UK), and to record consent. We also embed Twitter, Youtube and Disqus content on some pages, these companies have their own privacy policies.

Our privacy policy applies to all pages on our site

Should you need further guidance on how to proceed: External link for information about cookie management.