mirror of
https://github.com/esphome/esphome.git
synced 2025-09-12 08:12:22 +01:00
let make new platform implementation in external components (#7615)
Co-authored-by: Tomasz Duda <tomaszduda23@gmai.com>
This commit is contained in:
@@ -7,6 +7,7 @@
|
||||
#include <string>
|
||||
#include <type_traits>
|
||||
#include <vector>
|
||||
#include <limits>
|
||||
|
||||
#include "esphome/core/optional.h"
|
||||
|
||||
@@ -545,6 +546,7 @@ class Mutex {
|
||||
public:
|
||||
Mutex();
|
||||
Mutex(const Mutex &) = delete;
|
||||
~Mutex();
|
||||
void lock();
|
||||
bool try_lock();
|
||||
void unlock();
|
||||
@@ -554,6 +556,8 @@ class Mutex {
|
||||
private:
|
||||
#if defined(USE_ESP32) || defined(USE_LIBRETINY)
|
||||
SemaphoreHandle_t handle_;
|
||||
#else
|
||||
void *handle_; // d-pointer to store private data on new platforms
|
||||
#endif
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user