FreeRTOS C++ Wrappers
1.6.0
C++ interface to FreeRTOS
|
#include <mutex.hpp>
Public Member Functions | |
MutexRecursive () | |
virtual bool | Lock (TickType_t Timeout=portMAX_DELAY) |
virtual bool | Unlock () |
Public Member Functions inherited from cpp_freertos::Mutex | |
virtual | ~Mutex () |
Additional Inherited Members | |
Protected Member Functions inherited from cpp_freertos::Mutex | |
Mutex () | |
Protected Attributes inherited from cpp_freertos::Mutex | |
SemaphoreHandle_t | handle |
Recursive usage Mutex.
By default calls to Lock these objects block forever, but this can be changed by simply passing in a argument to the Lock() method. These objects are recursively acquirable. Calling Lock() twice from the same Thread (i.e. task) works fine. The caller just needs to be sure to call Unlock() as many times as Lock().
MutexRecursive::MutexRecursive | ( | ) |
Create a recursize Mutex.
ThreadMutexException | on failure. |
Definition at line 87 of file cmutex.cpp.
|
virtual |
Lock the Mutex.
Timeout | How long to wait to get the Lock until giving up. |
Implements cpp_freertos::Mutex.
Definition at line 101 of file cmutex.cpp.
|
virtual |
Unlock the Mutex.
Implements cpp_freertos::Mutex.
Definition at line 108 of file cmutex.cpp.