mirror of
https://git.intern.spaceteamaachen.de/ALPAKA/rtos2-utils.git
synced 2025-12-16 18:08:04 +00:00
Change include paths
This commit is contained in:
34
include/sta/rtos2/mutex.hpp
Normal file
34
include/sta/rtos2/mutex.hpp
Normal file
@@ -0,0 +1,34 @@
|
||||
/**
|
||||
* @brief CMSIS RTOS2 mutex implementation.
|
||||
*/
|
||||
#ifndef STA_RTOS2_MUTEX_HPP
|
||||
#define STA_RTOS2_MUTEX_HPP
|
||||
|
||||
#include <sta/intf/mutex.hpp>
|
||||
|
||||
#include <cmsis_os2.h>
|
||||
|
||||
|
||||
namespace sta
|
||||
{
|
||||
/**
|
||||
* @brief Implementation of `Mutex` interface using CMSIS RTOS2.
|
||||
*/
|
||||
class Rtos2Mutex : public Mutex
|
||||
{
|
||||
public:
|
||||
/**
|
||||
* @param handle CMSIS RTOS2 mutex
|
||||
*/
|
||||
Rtos2Mutex(osMutexId_t * handle);
|
||||
|
||||
void acquire() override;
|
||||
void release() override;
|
||||
|
||||
private:
|
||||
osMutexId_t * handle_; /**< CMSIS RTOS2 mutex */
|
||||
};
|
||||
} // namespace sta
|
||||
|
||||
|
||||
#endif // STA_OS2_MUTEX_HPP
|
||||
Reference in New Issue
Block a user