mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2026-03-15 22:26:31 +03:00
support s3
This commit is contained in:
@@ -12,7 +12,9 @@
|
|||||||
// Include all library components
|
// Include all library components
|
||||||
#include "esp32-psram/AllocatorPSRAM.h" // PSRAM-backed vector
|
#include "esp32-psram/AllocatorPSRAM.h" // PSRAM-backed vector
|
||||||
#include "esp32-psram/VectorPSRAM.h" // PSRAM-backed vector
|
#include "esp32-psram/VectorPSRAM.h" // PSRAM-backed vector
|
||||||
#include "esp32-psram/VectorHIMEM.h" // HIMEM-backed vector
|
#if CONFIG_IDF_TARGET_ESP32
|
||||||
|
#include "esp32-psram/VectorHIMEM.h" // HIMEM-backed vector (ESP32 only)
|
||||||
|
#endif
|
||||||
// #include "esp32-psram/InMemoryFile.h" // File interface using vectors
|
// #include "esp32-psram/InMemoryFile.h" // File interface using vectors
|
||||||
// #include "esp32-psram/PSRAM.h" // PSRAM file system
|
// #include "esp32-psram/PSRAM.h" // PSRAM file system
|
||||||
// #include "esp32-psram/HIMEM.h" // HIMEM file system
|
// #include "esp32-psram/HIMEM.h" // HIMEM file system
|
||||||
|
|||||||
@@ -1,5 +1,8 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
// HIMEM is only available on original ESP32
|
||||||
|
#if CONFIG_IDF_TARGET_ESP32
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <limits>
|
#include <limits>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
@@ -360,3 +363,5 @@ class HimemBlock {
|
|||||||
};
|
};
|
||||||
|
|
||||||
} // namespace esp32_psram
|
} // namespace esp32_psram
|
||||||
|
|
||||||
|
#endif // CONFIG_IDF_TARGET_ESP32
|
||||||
|
|||||||
@@ -238,7 +238,9 @@ using RingBufferStreamPSRAM = RingBufferStream<VectorPSRAM<uint8_t>>;
|
|||||||
/**
|
/**
|
||||||
* @brief Type alias for a RingBufferStream that uses HIMEM-backed vector storage
|
* @brief Type alias for a RingBufferStream that uses HIMEM-backed vector storage
|
||||||
*/
|
*/
|
||||||
|
#if CONFIG_IDF_TARGET_ESP32
|
||||||
using RingBufferStreamHIMEM = RingBufferStream<VectorHIMEM<uint8_t>>;
|
using RingBufferStreamHIMEM = RingBufferStream<VectorHIMEM<uint8_t>>;
|
||||||
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Type alias for a RingBufferStream that uses std::vector storage
|
* @brief Type alias for a RingBufferStream that uses std::vector storage
|
||||||
|
|||||||
@@ -209,8 +209,10 @@ using TypedRingBufferRAM = TypedRingBuffer<T, std::vector<T>>;
|
|||||||
/**
|
/**
|
||||||
* @brief Type alias for a typed ring buffer that uses HIMEM-backed vector storage
|
* @brief Type alias for a typed ring buffer that uses HIMEM-backed vector storage
|
||||||
*/
|
*/
|
||||||
|
#if CONFIG_IDF_TARGET_ESP32
|
||||||
template<typename T>
|
template<typename T>
|
||||||
using TypedRingBufferHIMEM = TypedRingBuffer<T, VectorHIMEM<T>>;
|
using TypedRingBufferHIMEM = TypedRingBuffer<T, VectorHIMEM<T>>;
|
||||||
|
#endif
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Type alias for a typed ring buffer that uses PSRAM-backed vector storage
|
* @brief Type alias for a typed ring buffer that uses PSRAM-backed vector storage
|
||||||
|
|||||||
@@ -1,5 +1,8 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
// HIMEM is only available on original ESP32
|
||||||
|
#if CONFIG_IDF_TARGET_ESP32
|
||||||
|
|
||||||
#include "HimemBlock.h"
|
#include "HimemBlock.h"
|
||||||
|
|
||||||
namespace esp32_psram {
|
namespace esp32_psram {
|
||||||
@@ -526,4 +529,6 @@ void swap(VectorHIMEM<T>& lhs, VectorHIMEM<T>& rhs) noexcept {
|
|||||||
lhs.swap(rhs);
|
lhs.swap(rhs);
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace esp32_psram
|
} // namespace esp32_psram
|
||||||
|
|
||||||
|
#endif // CONFIG_IDF_TARGET_ESP32
|
||||||
Reference in New Issue
Block a user