Check out my first novel, midnight's simulacra!

FreeRTOS: Difference between revisions

From dankwiki
(Created page with "FreeRTOS is an open source real time operating system commonly used in embedded development. ==Task notifications== Rather than using semaphores for wakeup, task notifications are faster and less heavyweight. ==Mutexes== FreeRTOS mutexes are a special class of semaphores. Note that they cannot be taken in interrupt handlers (i.e. <tt>xSemaphoreTakeFromISR()</tt> should only be used on semaphores created using <tt>xSemaphoreCreateBinary()</tt>). Using <tt>xSemaphoreTake...")
 
 
Line 5: Line 5:


==Mutexes==
==Mutexes==
FreeRTOS mutexes are a special class of semaphores. Note that they cannot be taken in interrupt handlers (i.e. <tt>xSemaphoreTakeFromISR()</tt> should only be used on semaphores created using <tt>xSemaphoreCreateBinary()</tt>). Using <tt>xSemaphoreTakeFromISR()</tt> on a mutex-type semaphore will generally fail if the lock is already held.
FreeRTOS mutexes are a special class of semaphores. Note that they cannot be taken in interrupt handlers (i.e. <tt>xSemaphoreTakeFromISR()</tt> should only be used on semaphores created using <tt>xSemaphoreCreateBinary()</tt>). Using <tt>xSemaphoreTakeFromISR()</tt> on a mutex-type semaphore will generally fail if the lock is already held. Relative to a binary semaphore, mutexes have a priority inheritance mechanism.

Latest revision as of 18:52, 19 May 2024

FreeRTOS is an open source real time operating system commonly used in embedded development.

Task notifications

Rather than using semaphores for wakeup, task notifications are faster and less heavyweight.

Mutexes

FreeRTOS mutexes are a special class of semaphores. Note that they cannot be taken in interrupt handlers (i.e. xSemaphoreTakeFromISR() should only be used on semaphores created using xSemaphoreCreateBinary()). Using xSemaphoreTakeFromISR() on a mutex-type semaphore will generally fail if the lock is already held. Relative to a binary semaphore, mutexes have a priority inheritance mechanism.