ddeyo wrote on Tuesday, August 27, 2019:
Thanks Gaurav,
I figured the task was not getting un-blocked by making the timeout 5 seconds.
Under normal operation, if no message was received in 5, I would hit the breakpoint again.
After a few gpio interrupts(? 3-4), the task stops hitting the breakpoint, even when I induce a gpio interrupt with a pulse generator.
When I see the problem, the only interrupt I see firing is the systick.
I have inadvertently found the problem, not the root cause though.
I had a second task to buffer messages; if I received new interrupts before I had time to respond to the old ones.
In that second task, I again had a ‘wait until ready condition’ that used an osDelay and a re-transmission of that message to itself.
With only a few messages, it broke some component of the messaging/scheduler task. What I had read (in one of the task.c comments) said that an interrupt while
the scheduler is paused could cause a task to be removed from one of the lists, either the ready or pending.
For now, I’m buffering the messages and processing that buffer, once the time is right.
Sounds like I found a bad way to use messaging.
-dwd
From: Gaurav Aggarwal aggarg-aws@users.sourceforge.net
Sent: Monday, August 26, 2019 5:09:37 PM
To: [freertos:discussion] 382005@discussion.freertos.p.re.sourceforge.net
Subject: [freertos:discussion] Re: Task, blocked waiting for message, stops getting serviced.
How are you determining that the task is not unblocked? Is it possible that ISRs are firing too quickly and the task is not getting a chance to run? Would you be able to share your code?
You can read more about the setting interrupt priorities in Cortex-M while running FreeRTOS here: https://www.freertos.org/RTOS-Cortex-M3-M4.html
Thanks.
Task, blocked waiting for message, stops getting serviced.https://sourceforge.net/p/freertos/discussion/382005/thread/d8d37dafc2/?limit=25#ff23/b09e/c057
Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/freertos/discussion/382005/
To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/