diff --git a/WP_Steuerung/module.php b/WP_Steuerung/module.php index 4efb03a..50eeb2d 100644 --- a/WP_Steuerung/module.php +++ b/WP_Steuerung/module.php @@ -169,6 +169,35 @@ class WP_Steurung extends IPSModule { $this->SetValue("Zustand_WP", 1); } + $newState = $this->GetValue("Zustand_WP"); + + if($newState == 0){ + + SetValue($this->ReadPropertyInteger("Sperrkontakt"), false); + SetValue($this->ReadPropertyInteger("Kontakt_Erhoeung"), false); + + }elseif($newState == 1){ + + SetValue($this->ReadPropertyInteger("Sperrkontakt"), false); + SetValue($this->ReadPropertyInteger("Kontakt_Erhoeung"), false); + + }elseif($newState == 2){ + + SetValue($this->ReadPropertyInteger("Sperrkontakt"), true); + SetValue($this->ReadPropertyInteger("Kontakt_Erhoeung"), false); + + }elseif($newState == 3){ + + SetValue($this->ReadPropertyInteger("Sperrkontakt"), false); + SetValue($this->ReadPropertyInteger("Kontakt_Erhoeung"), true); + + }else{ + + SetValue($this->ReadPropertyInteger("Sperrkontakt"), false); + SetValue($this->ReadPropertyInteger("Kontakt_Erhoeung"), false); + + } + }else{ $newCount = $this->GetValue("WP_Laufzeit_Zahler"); diff --git a/library.json b/library.json index 6387bb5..0580388 100644 --- a/library.json +++ b/library.json @@ -6,7 +6,7 @@ "compatibility": { "version": "7.1" }, - "version": "0.104", + "version": "0.105", "build": 0, "date": 0 } \ No newline at end of file