PIC32 - vApplicationTickHook

jbtredez wrote on Monday, August 09, 2010:

(I am a new user) vApplicationtickHook is executed from within an ISR. If i need to send a message to a task I can use a queue for that. I should call “xQueueSendToBackFromISR”.
If a context switch is needed after the ISR, what should I do ? Is is safe to call “portEND_SWITCHING_ISR”, even if I am “in the middle” of the timer ISR ?

Same question if I want to call xTaskResumeFromISR from vApplicationTickHook.

edwards3 wrote on Monday, August 09, 2010:

vApplicationTickHook is called before the tick interrupt chooses the next task to run, so it is not necessary to call portEND_SWITCHING_ISR. If vApplicationTickHook unblocks a task and that task has high priority then it will get chosen to run anyway.

jbtredez wrote on Monday, August 09, 2010:

Thanks