mirror of
https://github.com/esphome/esphome.git
synced 2025-07-28 06:06:33 +00:00
Fix psram below idf 5 (#8584)
This commit is contained in:
parent
31ed1eb6f0
commit
e5b7e3039a
@ -1,7 +1,8 @@
|
|||||||
|
|
||||||
#ifdef USE_ESP32
|
#ifdef USE_ESP32
|
||||||
#include "psram.h"
|
#include "psram.h"
|
||||||
#ifdef USE_ESP_IDF
|
#include <esp_idf_version.h>
|
||||||
|
#if defined(USE_ESP_IDF) && ESP_IDF_VERSION_MAJOR >= 5
|
||||||
#include <esp_psram.h>
|
#include <esp_psram.h>
|
||||||
#endif // USE_ESP_IDF
|
#endif // USE_ESP_IDF
|
||||||
|
|
||||||
@ -15,7 +16,7 @@ static const char *const TAG = "psram";
|
|||||||
|
|
||||||
void PsramComponent::dump_config() {
|
void PsramComponent::dump_config() {
|
||||||
ESP_LOGCONFIG(TAG, "PSRAM:");
|
ESP_LOGCONFIG(TAG, "PSRAM:");
|
||||||
#ifdef USE_ESP_IDF
|
#if defined(USE_ESP_IDF) && ESP_IDF_VERSION_MAJOR >= 5
|
||||||
bool available = esp_psram_is_initialized();
|
bool available = esp_psram_is_initialized();
|
||||||
|
|
||||||
ESP_LOGCONFIG(TAG, " Available: %s", YESNO(available));
|
ESP_LOGCONFIG(TAG, " Available: %s", YESNO(available));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user