From a897271a035e0a18d0645ae4dd410bd9783268c7 Mon Sep 17 00:00:00 2001 From: Copilot <198982749+Copilot@users.noreply.github.com> Date: Fri, 28 Nov 2025 18:15:58 +0000 Subject: [PATCH] Convert PSRAM to MB in usage reporting (#5130) * Initial plan * Convert PSRAM from bytes to MB in usage reporting JavaScript Co-authored-by: netmindz <442066+netmindz@users.noreply.github.com> * Use 1024*1024 instead of magic number for bytes to MB conversion Co-authored-by: netmindz <442066+netmindz@users.noreply.github.com> --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: netmindz <442066+netmindz@users.noreply.github.com> --- wled00/data/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wled00/data/index.js b/wled00/data/index.js index fe011dce..84b25618 100644 --- a/wled00/data/index.js +++ b/wled00/data/index.js @@ -3443,7 +3443,7 @@ function reportUpgradeEvent(info, oldVersion) { }; // Add optional fields if available - if (infoData.psram !== undefined) upgradeData.psramSize = infoData.psram; + if (infoData.psram !== undefined) upgradeData.psramSize = Math.round(infoData.psram / (1024 * 1024)); // convert bytes to MB // Note: partitionSizes not currently available in /json/info endpoint // Make AJAX call to postUpgradeEvent API