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] [February 2007 Threads] xTaskRemoveFromEventList usagePosted by Nobody/Anonymous on February 1, 2007 Im trying to implement a counting semaphore.
typedef struct SemaphoreDefinition { int count; xListxTasksWaitingToTake; }xSEMAPHORE ;
in my SemaphoreGive() , i need to extract highest priority task from xTasksWaitingToTake list
does xTaskRemoveFromEventList(xTasksWaitingToTake) really remove highest priority task from my semaphore event list, remove it from delayed/overflow delayed list and put it in ready list?
I just cant find an example of it in FreeRTOS itself. xQueueSend/Receive doesnt seem to be using this function.
RE: xTaskRemoveFromEventList usagePosted by embeddedc on February 1, 2007 xTaskRemoveFromEventList is used from queue.c. The normal way to implement a counting semaphore is to use a queue in the same way that the binary semaphore does, but with more than one space on the queue. No data is actually queued as the data size is set to zero.
RE: xTaskRemoveFromEventList usagePosted by Nobody/Anonymous on February 1, 2007 yeah, but I am supposed to do some study of difference between semaphore with dedicated structure, and semaphore using queue structure like FreeRTOS's.
does FreeRTOS provide facility to extract highest priority task from event list?
RE: xTaskRemoveFromEventList usagePosted by embeddedc on February 1, 2007 This is done automatically within xTaskRemoveFromEventList.
Copyright (C) Amazon Web Services, Inc. or its affiliates. All rights reserved.
|