erweitert
This commit is contained in:
+11
-1
@@ -134,13 +134,23 @@ public function RequestAction($Ident, $Value)
|
||||
|
||||
public function GetCurrentData(bool $Peak)
|
||||
{
|
||||
IPS_LogMessage("Batterie", "peak: " . ($Peak ? "true" : "false"));
|
||||
|
||||
|
||||
$array_powersteps = $this->GeneratePowerSteps();
|
||||
$aufdasnachladen = $this->ReadPropertyInteger("AufdasNachladen");
|
||||
$minimumentladen = $this->ReadPropertyInteger("MinimumEntladen");
|
||||
$maxleistung = $this->ReadPropertyInteger("MaxBatterieleistung");
|
||||
$dummy_array = [];
|
||||
|
||||
|
||||
|
||||
$batterieManagement = $this->ReadPropertyInteger("Batteriemanagement");
|
||||
if ($batterieManagement == 1) {
|
||||
$dummy_array[] = $array_powersteps[0];
|
||||
return $this->SetValue("PowerSteps", json_encode($dummy_array));
|
||||
}
|
||||
|
||||
|
||||
$batterieladezustandID = $this->ReadPropertyInteger("Batterieladezustand");
|
||||
if ($batterieladezustandID > 0) {
|
||||
$batterieladezustand = GetValue($batterieladezustandID);
|
||||
|
||||
Reference in New Issue
Block a user