Hello Team,
I am seeing an issue, where the USART interrupt handler is invoking only once when I use the free rtos API inside usart interrupt handler, even though there is a new data arrived.
This is the API called from usart interrupt handler,
BaseType_t xHigherPriorityTaskWoken = pdFALSE;
xSemaphoreGiveFromISR(RcvSemaphore(), &xHigherPriorityTaskWoken);
portYIELD_FROM_ISR(xHigherPriorityTaskWoken);
When I comment the free RTOS api everything works fine.
Did anyone see similar type of issue?
The reason why I am using freertos api inside the interrupt handler is, I have created free task and in the task handler where I am waiting for a semaphore, which is released from usart interrupt handler when all the data is received, so in the free rtos task handler the data will be processed.
Regards,
San
Hi @Harry_Zhang ,
I am using LPC55S69.
Finally I found the root cause of the issue.
As part of the processing the received message, in one of the function I am mistakenly using a global array index, the same was used in interrupt handler, due to this there was an array out of bound issue happening.
After using a local variable for index, there is no more issue seen.
Regards,
San