Reduce static JSON buffer size on -S2/-C3

Reduce static buffer allocation, hoping to improve overall stability.
This commit is contained in:
Frank
2023-08-30 01:04:13 +02:00
committed by GitHub
parent c4ec968654
commit d065e3332f

View File

@@ -423,9 +423,9 @@
#if defined(BOARD_HAS_PSRAM) && (defined(WLED_USE_PSRAM) || defined(WLED_USE_PSRAM_JSON))
#if defined(ARDUINO_ARCH_ESP32S2) || defined(ARDUINO_ARCH_ESP32C3)
#if defined(ARDUINO_ARCH_ESP32C3)
#define JSON_BUFFER_SIZE 48000 // WLEDMM - max 48KB on -C3 with PSRAM
#define JSON_BUFFER_SIZE 46000 // WLEDMM - max 46KB on -C3 with PSRAM (chip has 400kb RAM)
#else
#define JSON_BUFFER_SIZE 42000 // WLEDMM - max 42KB on -S2 with PSRAM
#define JSON_BUFFER_SIZE 36000 // WLEDMM - max 36KB on -S2 with PSRAM (chip has 320kb RAM)
#endif
#else
#define JSON_BUFFER_SIZE 56000 // WLEDMM (was 60000) slightly reduced to avoid build error "region dram0_0_seg overflowed"