This commit is contained in:
dh
2024-11-28 15:03:16 +01:00
parent 14682b7ee5
commit 7aedce6a18
2 changed files with 48 additions and 11 deletions
+40 -3
View File
@@ -1,3 +1,34 @@
Logo
Issues
Pull-Requests
Meilensteine
Erkunden
dh
/
Energiemanager_Symconmodule_Demo
Code
Issues
Pull-Requests
Actions
Pakete
Projekte
Releases
Wiki
Aktivität
Einstellungen
Energiemanager_Symconmodule...
/
CC100_HW
/
module.php
Daniel Häfliger
Daniel Häfliger
432c295a24
Refactoring
vor 3 Stunden
206 Zeilen
7.1 KiB
PHP
<?php <?php
class CC100_HW extends IPSModule class CC100_HW extends IPSModule
@@ -12,8 +43,7 @@ class CC100_HW extends IPSModule
public function Create() public function Create()
{ {
parent::Create(); parent::Create();
$this->RegisterPropertyString("FilePath", $this->DigOutPID);
$this->RegisterVariableBoolean("Bit1", "DO 1", "~Switch", 1); $this->RegisterVariableBoolean("Bit1", "DO 1", "~Switch", 1);
$this->RegisterVariableBoolean("Bit2", "DO 2", "~Switch", 2); $this->RegisterVariableBoolean("Bit2", "DO 2", "~Switch", 2);
$this->RegisterVariableBoolean("Bit3", "DO 3", "~Switch", 3); $this->RegisterVariableBoolean("Bit3", "DO 3", "~Switch", 3);
@@ -119,7 +149,7 @@ class CC100_HW extends IPSModule
private function TryWriteFile($starttime) private function TryWriteFile($starttime)
{ {
$this->readAndConvertToBools($this->$DIN_FILE); $this->readAndConvertToBools($DIN_FILE);
$currentTime = microtime(true) * 1000; $currentTime = microtime(true) * 1000;
if ($currentTime - $starttime <= $this->maxTime) { if ($currentTime - $starttime <= $this->maxTime) {
@@ -204,3 +234,10 @@ class CC100_HW extends IPSModule
} }
?> ?>
Powered by Gitea
Version: 1.22.0 Seite:
167ms
Template:
7ms
Lizenzen
API
+1 -1
View File
@@ -6,7 +6,7 @@
"compatibility": { "compatibility": {
"version": "7.1" "version": "7.1"
}, },
"version": "0.162", "version": "0.163",
"build": 0, "build": 0,
"date": 0 "date": 0
} }