From d6a5d2c1f2f86ea91db1b292dbe2a1127918a88d Mon Sep 17 00:00:00 2001 From: DanielHaefliger Date: Thu, 5 Feb 2026 17:12:25 +0100 Subject: [PATCH] no message --- Bat_EV_SDL _V2/module.php | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/Bat_EV_SDL _V2/module.php b/Bat_EV_SDL _V2/module.php index 1035356..47cb416 100644 --- a/Bat_EV_SDL _V2/module.php +++ b/Bat_EV_SDL _V2/module.php @@ -614,12 +614,19 @@ private function CalculateBatteryDistribution(float $pEvW, float $pSdlW): array ]; } + + $batteriesRaw = json_decode($this->ReadPropertyString("Batteries")); + $totalPower_ist = 0; - print_r($batteries); - foreach ($batteries as $bat) { - $totalPower_ist += 0; // GetValue($bat['register_bat_power']); + print_r($batteriesRaw); + foreach ($batteriesRaw as $bat) { + $totalPower_ist += GetValue($bat['register_bat_power']); } + + + + if(($pEvW + $pSdlW) === 0){