FreeRTOS Support Archive
The FreeRTOS support forum is used to obtain active support directly from Real
Time Engineers Ltd. In return for using our top quality software and services for
free, we request you play fair and do your bit to help others too! Sign up
to receive notifications of new support topics then help where you can.
This is a read only archive of threads posted to the FreeRTOS support forum.
The archive is updated every week, so will not always contain the very latest posts.
Use these archive pages to search previous posts. Use the Live FreeRTOS Forum
link to reply to a post, or start a new support thread.
[FreeRTOS Home] [Live FreeRTOS Forum] [FAQ] [Archive Top] [November 2015 Threads]
Hello,
I would like some help to find out how use the FreeRTOS resources:
I need lock a task execution until an event (interrupt) happen, but i need unlock the task only if this event happened after the task has been locked, interrupts that happened before the lock does not care, the first feature that came in mind was the task Notify events, but I figured out that if any event happened before the xTaskNotifyWait it will not lock (because the state will be eNotified) even if I set all bits in ulBitsToClearOnEntry
( is there a way to clean the eNotified state before calling xTaskNotifyWait() ?)
Stopping the interrupt until the locking moment is not an option, any suggestions?
(I am new to the RTOS world, still learning how to model my solutions using RTOS, sorry if this is a trivial problem)
Thanks for your time!
Gustavo
You can call xTaskNotifyWait() with a block time of 0 to clear the notification state before you call it again to wait for the interrupt. In 8.2.3 there is also a function xTaskNotifyStateClear().
Thank you!
Exactly what I needed!
I'm using 8.2.1 atm, I can just update my Freertos source to the latest? no need any adittional changes, right?
Thanks again
Yes - it should be just a drop in replacement.
Regards.
Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.