2020-12-14 21:15:41 +01:00
|
|
|
#ifndef FSFW_OSAL_RTEMS_MUTEX_H_
|
|
|
|
#define FSFW_OSAL_RTEMS_MUTEX_H_
|
2020-08-28 18:33:29 +02:00
|
|
|
|
|
|
|
#include "../../ipc/MutexIF.h"
|
|
|
|
#include "RtemsBasic.h"
|
|
|
|
|
|
|
|
class Mutex : public MutexIF {
|
|
|
|
public:
|
|
|
|
Mutex();
|
|
|
|
~Mutex();
|
2020-12-03 18:57:50 +01:00
|
|
|
ReturnValue_t lockMutex(TimeoutType timeoutType, uint32_t timeoutMs = 0);
|
2020-08-28 18:33:29 +02:00
|
|
|
ReturnValue_t unlockMutex();
|
|
|
|
private:
|
|
|
|
rtems_id mutexId;
|
|
|
|
static uint8_t count;
|
|
|
|
};
|
|
|
|
|
2020-12-14 21:15:41 +01:00
|
|
|
#endif /* FSFW_OSAL_RTEMS_MUTEX_H_ */
|