I am learning FreeRTOS and SystemView. I have a very simple project with two tasks, both with the same priority. My SysTick period is 1ms. Every 1ms I see a SysTick event followed by a Scheduler event. My two tasks transmit a few bytes out a UART and then call taskYield. What I see on SystemView are sequences like this....
Scenario 1
SysTick, Scheduler, Task1, SysTick, Scheduler, Task2, SysTick, Scheduler
and I often see this....
Scenario 2
SysTick, Scheduler, Task1, Task2, SysTick, Scheduler
Here is a screenshot that shows both scenarios...
(Ignore the red comments on this screenshot)
I understand the 1st scenario but not the 2nd. In the 2nd scenario, I understand that the taskYield in Task1 caused the scheduler to perform a context switch. But in SystemView I don't see any scheduler event. Or in other words, where the comment says "Did not work like your system", an arrow points to the end of a Task. Why was there no scheduler event at that point?
Scenario 1
SysTick, Scheduler, Task1, SysTick, Scheduler, Task2, SysTick, Scheduler
and I often see this....
Scenario 2
SysTick, Scheduler, Task1, Task2, SysTick, Scheduler
Here is a screenshot that shows both scenarios...
(Ignore the red comments on this screenshot)
I understand the 1st scenario but not the 2nd. In the 2nd scenario, I understand that the taskYield in Task1 caused the scheduler to perform a context switch. But in SystemView I don't see any scheduler event. Or in other words, where the comment says "Did not work like your system", an arrow points to the end of a Task. Why was there no scheduler event at that point?