diff --git a/Bat_EV_SDL _V2/module.php b/Bat_EV_SDL _V2/module.php index 80fab97..b92c69b 100644 --- a/Bat_EV_SDL _V2/module.php +++ b/Bat_EV_SDL _V2/module.php @@ -614,6 +614,16 @@ private function CalculateBatteryDistribution(float $pEvW, float $pSdlW): array ]; } + $totalPower_ist = 0; + + foreach ($batteries as $bat) { + $totalPower_ist += GetValue($bat['register_bat_power']); + } + + + $this->SetValue("Aktuelle_Leistung_EV", $totalPower_ist/($pEvW + $pSdlW)*$pEvW); + $this->SetValue("Aktuelle_Leistung_SDL",, $totalPower_ist/($pEvW + $pSdlW)*$pSdlW); + return $finalOutput; }