I am using FreeRTOS to run some tasks in my software on S32K144 board . Currently my init task is getting stuck on xQueueSemaphoreTake() function in Queue.c
When I start my program the program runs for a while and then resets and starts with init again. When I see the call stack it shows its stuck on the function i mentioned above. The xQueueSemaphore is invoked while trying to do a blocking receive data from UART peripheral.
In the xQueueSemaphoreTake() function its stuck on portYIELD_WITHIN_API();
I have checked several posts with similiar behavior. I followed their solutions such as stack overflow, or priority setting. I have them all in order.
The configMAX_SYSCALL_INTERRUPT_PRIORITY(5) is number is lower than my UART interrupt(6). I do not have stack issues.
Also when the init task is stuck on the xQueueSemaphore take, the IDLE task is parallely into vApplicationIdleHook() (which i expect is expected behaviour) and then into xPortGetFreeHeapSize() which returns free bytes remaining.
I am new to FreeRTOS and I have exhausted all the solutions online. Can anyone help me?! what could be other possible reasons for this behavior?
Below is the picture of my call stack.
Kindly let me know, if any other details are required.
Solved! Go to Solution.