With respect to: vTaskDelay() - FreeRTOS™, which currently states:
Delay a task for a given number of ticks. The actual time that the task remains blocked depends on the tick rate. The constant portTICK_PERIOD_MS can be used to calculate real time from the tick rate - with the resolution of one tick period.
After reviewing how vTaskDelay() works, the documentation doesn’t conflict with what it does, but I think documenting a few specific cases may help people familiar with different RTOSs quickly understand the specifics of vTaskDelay().
vTaskDelay(0);
From the documentation it sounds like this might do nothing. It yields to other tasks of the same priority.
Documenting vTaskDelay(1);
blocks until the next timer tick, <= portTICK_PERIOD_MS of realtime, helps make the distinction between tick-intervals and tick-events. If I understand it, ‘ticks’ means ‘tick-events’, and not ‘tick-intervals’, it’s understandable from the existing text, but if you don’t know that, you might assume vTaskDelay(1);
blocks for up to two ticks, so that at least one whole interval has been delayed. If applications you need to guarantee a minimum interval, they need to add the +1 themselves for FreeRTOS.(not a criticism, just a detail I had to search for).
There’s a longer explanation here from 2012: vTaskDelay(0) vs vTaskDelay(1)