richard_damon wrote on Saturday, January 07, 2012:
First, a vTaskDelay(0) is, I believe, basically the same as a taskYield() which does NOT give time to lower priority tasks. The task needs to block on some condition saying it doesn’t have anything more to do now, and the block will end when it has something more to do. The block can be a vTasDelay() to indicate a time when it should restart, or a wait on a queue/semaphore of some sort to wait for that to become ready.
A vTskDelay(1) will block the task till the next timer tick, at which point it will be make back ready, and will be switched to UNLESS there is a task of higher priority that is also ready to run. If a given task is the highest priority, then it WILL run on the next timer tick, unless some other task is being unfriendly and does a long critical section or scheduler disable block.
If your delay is bigger than 1 tick, and you want a constant period, than look at vTaskDelayUntil as a possibly better option as it sets the delay based on the time this run started as opposed to the current time.
Also, you are describing that these tasks are getting new information to process on a time basis, is this really what is happening? I tend to find that I am actually processing the data from a divide (like an A/D converter) and it actually makes more sense to have (if possible) an interrupt be triggered when the data is available, and the interrupt signal the task with a queue or semaphore, and that starts up the processing task.