diff --git a/Ladestation_v2/module.php b/Ladestation_v2/module.php index 0330571..becf46d 100644 --- a/Ladestation_v2/module.php +++ b/Ladestation_v2/module.php @@ -699,7 +699,7 @@ class Ladestation_v2 extends IPSModule $powerSteps = []; // Konfiguration des powerSteps-Arrays basierend auf den Properties - if (!$ladebereit) { + if (!$ladebereit || $this->GetValue("Car_is_full")) { $powerSteps = [0]; } elseif (!$Peak && !$solarladen) { $powerSteps = [max($this->Get_Array_From_Current($this->GetValue("Is_1_ph"),$this->GetValue("Max_Current"), $this->GetValue("Aktuelle_Leistung"), $this->GetValue("IsTimerActive_Null_Timer")))]; diff --git a/Manager/module.php b/Manager/module.php index e024f55..878c9a7 100644 --- a/Manager/module.php +++ b/Manager/module.php @@ -172,6 +172,13 @@ class Manager extends IPSModule $Peakleistung = $this->ReadPropertyInteger("Peakleistung"); $Ueberschussleistung = $this->ReadPropertyInteger("Ueberschussleistung"); + if($this->GetValue("Is_Peak_Shaving")){ + $Netzbezug += $totalAktuelle_Leistung; + }else{ + $Netzbezug -= $totalAktuelle_Leistung; + + } + // Fallunterscheidung ob auf Solarladen oder Peakshaving gerregelt wird. if ($Netzbezug < ($Peakleistung + $Ueberschussleistung) / 2) { $remainingPower = -1 * (-1 * $Ueberschussleistung + $Netzbezug);