You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Scope-based deltas and tag budgets: wrap a code path in `beginScope()` to measure DRAM/PSRAM consumed (or released), attribute it to a tag, and fire `onScope`/`onTagThreshold` callbacks when soft budgets are crossed.
16
-
- Leak suspicion helpers: mark checkpoints for steady-state phases; the monitor compares averages and flags downward free-memory drift or rising fragmentation via `onLeakCheck`.
16
+
- Leak suspicion helpers: mark checkpoints for steady-state phases; the monitor compares averages and flags downward free-memory drift or rising fragmentation via `onLeakCheck`, with bounded checkpoint/result retention.
17
17
- Derived insights: windowed min/avg/max, slope-based bytes/second, and time-to-warn/critical estimates per region.
18
18
- Task visibility: stack state transitions (`Safe/Warn/Critical`), optional new/vanished task detection, and per-task thresholds.
19
19
- Export/panic helpers: convert snapshots to ArduinoJson for telemetry and install a shutdown/panic hook that captures a final snapshot before abort/restart.
|`defaultTaskStackBytes` / `stackWarnFraction` / `stackCriticalFraction`|`4096` / `0.25` / `0.10`| Default stack headroom thresholds when per-task overrides are absent. |
174
174
|`leakNoiseBytes`|`1024`| Ignore free-byte changes smaller than this when flagging leak drift between checkpoints. |
175
+
|`maxLeakChecksInHistory`|`16`| Ring-buffer depth for leak checkpoint timestamps/results (minimum effective value is 1). |
175
176
|`usePSRAMBuffers`|`false`| Best-effort PSRAM preference for monitor-owned dynamic containers and internal storage models (history/scope/tag/task/leak internals plus transient threshold, scope/tag, window, and task-tracking scratch buffers); automatically falls back to normal heap when PSRAM is unavailable. |
176
177
177
178
`MemorySnapshot` holds `timestampUs` plus vectors of `RegionStats` (free bytes, low-water, largest block, fragmentation, slope/time estimates, window stats) and optional `TaskStackUsage` entries (task name, priority, state, free high-water bytes).
0 commit comments