Remove psram code when psram is not included
This commit is contained in:
@@ -3277,8 +3277,6 @@ script:
|
||||
// Report memory
|
||||
const size_t internal_heap_size = heap_caps_get_total_size(MALLOC_CAP_INTERNAL);
|
||||
const size_t internal_heap_size_free = heap_caps_get_free_size(MALLOC_CAP_INTERNAL);
|
||||
const size_t psram_heap_size = heap_caps_get_total_size(MALLOC_CAP_SPIRAM);
|
||||
const size_t psram_heap_size_free = heap_caps_get_free_size(MALLOC_CAP_SPIRAM);
|
||||
ESP_LOGI(TAG, " Free heap:");
|
||||
|
||||
if (internal_heap_size != 0) {
|
||||
@@ -3288,12 +3286,17 @@ script:
|
||||
ESP_LOGI(TAG, " Internal: %7d bytes", internal_heap_size_free);
|
||||
}
|
||||
|
||||
#ifdef USE_PSRAM
|
||||
const size_t psram_heap_size = heap_caps_get_total_size(MALLOC_CAP_SPIRAM);
|
||||
const size_t psram_heap_size_free = heap_caps_get_free_size(MALLOC_CAP_SPIRAM);
|
||||
if (psram_heap_size != 0) {
|
||||
ESP_LOGI(TAG, " PSRAM: %7d bytes (%0.1f%%)", psram_heap_size_free,
|
||||
((float)psram_heap_size_free / psram_heap_size) * 100.0f);
|
||||
} else {
|
||||
ESP_LOGI(TAG, " PSRAM: %7d bytes", psram_heap_size_free);
|
||||
}
|
||||
#endif
|
||||
|
||||
// Report UART
|
||||
ESP_LOGI(TAG, "UART:");
|
||||
ESP_LOGI(TAG, " Baud rate: %" PRIu32 " bps", tf_uart->get_baud_rate());
|
||||
|
||||
Reference in New Issue
Block a user