How can I manage communication between tasks using queues in FreeRTOS?
How can I manage communication between tasks using queues in FreeRTOS? My queue data seems to be getting lost, and I'm encountering the error: "Queue send failed". Here's my queue creation and send code:
@Middleware & OS @Helper
Solution:Jump to solution
@ZacckOsiemo
It's been resolved and my code works better now after adding the function that confirms if the queue was actually created, regarding d syntax error seems I didn't add a
;
were it was required, this little error caused me almost a day of headache, thanks for the help guys, @everyone
This is my code now 👇...10 Replies
Are you checking that the queue is created successfully, Is there enough space on the heap? Are you calling
xQueueSend
in an ISR?@ZacckOsiemo Am checking if it's created successfully, cause I keep getting the error queue send failed
start by checking that its actually created, then ensure you are calling xQueueSend in the correct context
First check that your queue has been created correctly, and before sending check that you have anough/available space in your queue
I tried adding a function to check if the queue is successfully created but now having a syntax error
This my code
whats the error?
Syntax error
yeah what syntax error
Solution
@ZacckOsiemo
It's been resolved and my code works better now after adding the function that confirms if the queue was actually created, regarding d syntax error seems I didn't add a
;
were it was required, this little error caused me almost a day of headache, thanks for the help guys, @everyone
This is my code now 👇