no message
This commit is contained in:
@@ -101,7 +101,7 @@ class Bat_EV_SDL_V4 extends IPSModule
|
|||||||
$semKey = 'BatEVSDL_Update_' . $this->InstanceID;
|
$semKey = 'BatEVSDL_Update_' . $this->InstanceID;
|
||||||
|
|
||||||
if (!IPS_SemaphoreEnter($semKey, 5000)) {
|
if (!IPS_SemaphoreEnter($semKey, 5000)) {
|
||||||
$this->SendDebug("Update", "SKIP - Semaphore locked", 0);
|
//$this->SendDebug("Update", "SKIP - Semaphore locked", 0);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -216,7 +216,7 @@ class Bat_EV_SDL_V4 extends IPSModule
|
|||||||
if ($sumBatPowerW <= 0.0) {
|
if ($sumBatPowerW <= 0.0) {
|
||||||
$this->SetBuffer("BatPlanHash", $hash);
|
$this->SetBuffer("BatPlanHash", $hash);
|
||||||
$this->SetBuffer("BatPlanJSON", json_encode($plan));
|
$this->SetBuffer("BatPlanJSON", json_encode($plan));
|
||||||
$this->SendDebug("Plan", "sumBatPowerW=0 -> empty plan", 0);
|
//$this->SendDebug("Plan", "sumBatPowerW=0 -> empty plan", 0);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -340,7 +340,7 @@ class Bat_EV_SDL_V4 extends IPSModule
|
|||||||
$this->SetIdentValue("SDL_Start_Pos", round((float)$this->ReadPropertyFloat("SDL_Start_Pos_Config"), 3));
|
$this->SetIdentValue("SDL_Start_Pos", round((float)$this->ReadPropertyFloat("SDL_Start_Pos_Config"), 3));
|
||||||
$this->SetIdentValue("EV_Start_Pos", round((float)$this->ReadPropertyFloat("EV_Start_Pos_Config"), 3));
|
$this->SetIdentValue("EV_Start_Pos", round((float)$this->ReadPropertyFloat("EV_Start_Pos_Config"), 3));
|
||||||
|
|
||||||
$this->SendDebug("Plan", "Battery plan rebuilt (" . count($plan["bats"]) . " bats)", 0);
|
//$this->SendDebug("Plan", "Battery plan rebuilt (" . count($plan["bats"]) . " bats)", 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
private function InitVirtualAccountsIfNeeded(): void
|
private function InitVirtualAccountsIfNeeded(): void
|
||||||
@@ -709,13 +709,13 @@ class Bat_EV_SDL_V4 extends IPSModule
|
|||||||
$dischargeW = max(0.0, (float)($d["dischargeW"] ?? 0.0));
|
$dischargeW = max(0.0, (float)($d["dischargeW"] ?? 0.0));
|
||||||
|
|
||||||
if ($chargeW > 0.0 && $dischargeW > 0.0) {
|
if ($chargeW > 0.0 && $dischargeW > 0.0) {
|
||||||
$this->SendDebug("WriteBatteryPowerSetpoints", "WARN both >0 for $typ idx=$idx", 0);
|
//$this->SendDebug("WriteBatteryPowerSetpoints", "WARN both >0 for $typ idx=$idx", 0);
|
||||||
$chargeW = 0.0;
|
$chargeW = 0.0;
|
||||||
$dischargeW = 0.0;
|
$dischargeW = 0.0;
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->WriteByVendorRegistersSingleMode($typ, $cfg, $chargeW, $dischargeW);
|
$this->WriteByVendorRegistersSingleMode($typ, $cfg, $chargeW, $dischargeW);
|
||||||
$this->SendDebug("Setpoints", "$typ idx=$idx charge={$chargeW}W discharge={$dischargeW}W", 0);
|
//$this->SendDebug("Setpoints", "$typ idx=$idx charge={$chargeW}W discharge={$dischargeW}W", 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -967,7 +967,7 @@ class Bat_EV_SDL_V4 extends IPSModule
|
|||||||
{
|
{
|
||||||
$id = @$this->GetIDForIdent($ident);
|
$id = @$this->GetIDForIdent($ident);
|
||||||
if ($id <= 0) {
|
if ($id <= 0) {
|
||||||
$this->SendDebug(__FUNCTION__, "Ident nicht gefunden: $ident", 0);
|
//$this->SendDebug(__FUNCTION__, "Ident nicht gefunden: $ident", 0);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
SetValue($id, $value);
|
SetValue($id, $value);
|
||||||
|
|||||||
Reference in New Issue
Block a user