From 6a2ac4814ff88602d2f2dd999a383f49a5c7b639 Mon Sep 17 00:00:00 2001 From: "belevo\\mh" Date: Fri, 26 Sep 2025 08:42:45 +0200 Subject: [PATCH] no message --- Pufferspeicher/module.json | 2 +- Pufferspeicher/module.php | 16 ++++++++++++---- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/Pufferspeicher/module.json b/Pufferspeicher/module.json index cfa07a4..c85e295 100644 --- a/Pufferspeicher/module.json +++ b/Pufferspeicher/module.json @@ -1,5 +1,5 @@ { - "id": "{92E18FE8-489C-87A7-766B-2F06B7BD95E5}", + "id": "{1604D0D8-B142-132A-C6AC-9054C48BA497}", "name": "Pufferspeicher", "type": 3, "vendor": "Belevo AG", diff --git a/Pufferspeicher/module.php b/Pufferspeicher/module.php index fb6d031..dc34bb1 100644 --- a/Pufferspeicher/module.php +++ b/Pufferspeicher/module.php @@ -99,13 +99,21 @@ class Pufferspeicher extends IPSModule SetValue($this->ReadPropertyInteger("Heizkontakt_Puffer"), false); SetValue($this->ReadPropertyInteger("Heizkontakt_Puffer_Teillast"), false); } - } - + + // Prüfe auf Änderung der Power im Vergleich zur letzten Einstellung + $lastPower = GetValue($this->GetIDForIdent("Aktuelle_Leistung")); + if ($power != $lastPower) { + $this->SetValue("Idle", false); + $this->SetValue( + "IdleCounter", + $this->ReadPropertyInteger("IdleCounterMax") + ); + } - // Setze die neue Aktuelle_Leistung + // Setze die neue Aktuelle_Leistung $this->SetValue("Aktuelle_Leistung", $power); $this->SetValue("Bezogene_Energie", ($this->GetValue("Bezogene_Energie") + ($this->GetValue("Aktuelle_Leistung")*($this->ReadPropertyInteger("Interval")/3600)))); - // IdleCounter verarbeiten + // IdleCounter verarbeiten $this->ProcessIdleCounter(); }