nagarajukarre wrote on Wednesday, November 13, 2013:
I am using FreeRTOS V6.0.0
i am understanding, How the tasks are getting scheduled?
Here i got struck every time time slice expires only the same task getting called and never another task getting scheduled.
The other task getting a chence in two cases:
- When the task itself gone into blocked state, another task getting scheduled and this task itself enter into blocked state during this time another task gets scheduled.
In above case we are enabling the PendSVHandler interrupt when task enter into blocked state, and here saving context of the task, context switch and restoring happening in PendSVHandler.
2.When we enable the configUSE_PREMPTION flag under this, if the condition is true, we are enabling the PendSVHandler interrupt.
My question is we are not enabling configUSE_PREMPTION flag and we are not using any api in side the task to block.
How the scheduler giving a chence to execute the task contineously, at this moment which handler gets calling and how the only one task gets calling for every time slice.
If the SVCHandler called only once, How my task gets executing for each time slice expiry?
Please let me know the which part of the FreeRTOS code handling this.