ESPHome
2024.9.2
|
An STL allocator that uses SPI RAM. More...
#include <helpers.h>
Public Types | |
enum | Flags { NONE = 0, REFUSE_INTERNAL = 1 << 0, ALLOW_FAILURE = 1 << 1 } |
using | value_type = T |
Public Member Functions | |
ExternalRAMAllocator ()=default | |
ExternalRAMAllocator (Flags flags) | |
template<class U > | |
constexpr | ExternalRAMAllocator (const ExternalRAMAllocator< U > &other) |
T * | allocate (size_t n) |
void | deallocate (T *p, size_t n) |
An STL allocator that uses SPI RAM.
By setting flags, it can be configured to don't try main memory if SPI RAM is full or unavailable, and to return nulllptr
instead of aborting when no memory is available.
using esphome::ExternalRAMAllocator< T >::value_type = T |
enum esphome::ExternalRAMAllocator::Flags |
|
default |
|
inline |
|
inline |
|
inline |
|
inline |