2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-04-17 23:46:03 +00:00

09_CUL_FHTTK.pm: minimal bugfix (after Syncing, adapted Reading state to Closed)

git-svn-id: https://svn.fhem.de/fhem/trunk@7073 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
matscher 2014-11-27 20:12:20 +00:00
parent 5ca7169b8e
commit 4fc31c655e

View File

@ -168,21 +168,22 @@ CUL_FHTTK_Set($@)
return "Unknown argument $opt ($value), choose one of " . join(" ", @cList);
}
if($opt eq "Syncing" ) {
Log3 $name, 3, "CUL_FHTTK ($name) syncing with FHT80b.";
IOWrite($hash, "", sprintf("T%s0c", $hash->{CODE})); # 0x0c - sync
# window state switch to closed
} elsif ($opt eq "Open" ) {
Log3 $name, 3, "CUL_FHTTK ($name) send open window state. ($opt)";
if ($opt eq "Open" ) {
Log3 $name, 3, "CUL_FHTTK ($name) changed window state to open.";
IOWrite($hash, "", sprintf("T%s01", $hash->{CODE})); # 0x01 - open or 0x81
} elsif ($opt eq "Closed" ) {
Log3 $name, 3, "CUL_FHTTK ($name) send closed window state. ($opt)";
Log3 $name, 3, "CUL_FHTTK ($name) changed window state to open.";
IOWrite($hash, "", sprintf("T%s02", $hash->{CODE})); # 0x02 - closed or 0x82
} elsif($opt eq "Syncing" ) {
Log3 $name, 3, "CUL_FHTTK ($name) syncing with FHT80b.";
IOWrite($hash, "", sprintf("T%s0c", $hash->{CODE})); # 0x0c - sync
# window state switch to closed through cul FW implementation
$opt = "Closed";
} else {
return "Unknown argument $a[1], choose one of Syncing Open Closed"
}