[script] ESP8266: Store log format strings in PROGMEM (saves 240 bytes RAM)

This commit is contained in:
J. Nick Koston
2025-09-05 10:11:11 -05:00
parent b8ed7ec145
commit d2d0f06be3
2 changed files with 25 additions and 5 deletions

View File

@@ -6,9 +6,15 @@ namespace script {
static const char *const TAG = "script";
#ifdef USE_STORE_LOG_STR_IN_FLASH
void ScriptLogger::esp_log_(int level, int line, const __FlashStringHelper *format, const char *param) {
esp_log_printf_(level, TAG, line, format, param);
}
#else
void ScriptLogger::esp_log_(int level, int line, const char *format, const char *param) {
esp_log_printf_(level, TAG, line, format, param);
}
#endif
} // namespace script
} // namespace esphome