HF Interface Wrapper 0.1.0-dev
Embedded C++ hardware abstraction layer
Loading...
Searching...
No Matches
PlatformMutex.h File Reference

Cross-platform RTOS mutex and synchronization primitives. More...

#include "McuSelect.h"
#include <atomic>
#include <cstdint>
Include dependency graph for PlatformMutex.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  PlatformTime
 
class  PlatformMutex
 
class  PlatformSharedMutex
 
class  PlatformUniqueLock< Mutex >
 
class  PlatformSharedLock< SharedMutex >
 

Typedefs

template<typename Mutex >
using PlatformLockGuard = PlatformUniqueLock<Mutex>
 Convenience alias for unique lock guard.
 
using PlatformMutexLockGuard = PlatformUniqueLock<PlatformMutex>
 Convenience alias for PlatformMutex lock guard.
 

Detailed Description

Cross-platform RTOS mutex and synchronization primitives.

This header provides platform-agnostic mutex, lock guard, and timing utilities that work across different RTOS implementations (FreeRTOS on ESP32, STM32, RP2040). The implementation includes standard mutexes, shared mutexes for reader-writer patterns, RAII lock guards, and high-resolution timing functions for synchronization.

Author
Nebiyu Tadesse
Date
2025
Note
Platform support includes ESP32 (FreeRTOS), STM32 (CMSIS-OS), and RP2040 (FreeRTOS).

Typedef Documentation

◆ PlatformLockGuard

template<typename Mutex >
using PlatformLockGuard = PlatformUniqueLock<Mutex>

Convenience alias for unique lock guard.

◆ PlatformMutexLockGuard

Convenience alias for PlatformMutex lock guard.