Replaces usage of String with const char* in heap debug function

Replaces String with const char* in printHeapDebugData to reduce heap fragmentation.
This commit is contained in:
Jan Philipp Ecker
2025-08-02 22:53:38 +02:00
parent 722ef421cb
commit c450df59aa

View File

@@ -7,6 +7,6 @@
#define HEAP_DEBUG_MESSAGE(location)
#endif
inline void printHeapDebugData(String location){
inline void printHeapDebugData(const char *location){
Serial.println("Heap: " + String(ESP.getMinFreeHeap()/1024) + "\t" + String(ESP.getFreeHeap()/1024) + "\t" + String(ESP.getMaxAllocHeap()/1024) + "\t" + location);
}