Hello,
I have a question regarding the scheduler in RTX5. If I recall correctly, the PendSV priority is higher than the SysTick exception in RTX5. However, in the example provided in the CMSIS-RTOS2 documentation (refer to the image), the PendSV handler is executed after the SysTick between time indices 4 and 5. Shouldn’t the PendSV execute before the SysTick after the ISR, especially since we set a PendSV flag in the ISR?
Thank you for your response!
PendSV and SysTick are the same priority and also the lowest priority. PendSV will not be interrupted by a SysTick once it is running. The SysTick will wait until the PendSV processing is complete. SVC is 1 priority level higher than PendSV and SysTick. SVC will always run to completion before SysTick or PendSV will run.