From d519a5c2d3d44f47163a3e964bd3886d0f4c9aef Mon Sep 17 00:00:00 2001
From: matscher <>
Date: Wed, 5 Oct 2016 20:33:59 +0000
Subject: [PATCH] 09_CUL_FHTTK.pm: add the possibility to resynchronize a
virtual sensor after an device (e.g.CUL) reset (only possible with the
corresponding firmware (prototype is available)
git-svn-id: https://svn.fhem.de/fhem/trunk/fhem@12284 2b470e98-0d58-463d-a4d8-8e2adae1ed80
---
FHEM/09_CUL_FHTTK.pm | 12 +++++++++++-
1 file changed, 11 insertions(+), 1 deletion(-)
diff --git a/FHEM/09_CUL_FHTTK.pm b/FHEM/09_CUL_FHTTK.pm
index 44ba3c434..c54b8a023 100644
--- a/FHEM/09_CUL_FHTTK.pm
+++ b/FHEM/09_CUL_FHTTK.pm
@@ -100,7 +100,8 @@ my %fhttfk_c2b; # command->button hash
my %canset = (
"01" => "Open",
"02" => "Closed",
- "0c" => "Syncing");
+ "0c" => "Syncing",
+ "ff" => "ReSync");
# -wusel, 2009-11-06
#
@@ -184,6 +185,11 @@ CUL_FHTTK_Set($@)
# window state switch to closed through cul FW implementation
$opt = "Closed";
+ } elsif($opt eq "ReSync" ) {
+ Log3 $name, 3, "CUL_FHTTK ($name) resyncing with FHT80b.";
+
+ IOWrite($hash, "", sprintf("T%s%s", $hash->{CODE}, $fhttfk_c2b{$opt})); # 0xff - ReSync
+
} else {
return "Unknown argument $a[1], choose one of Syncing Open Closed"
}
@@ -383,6 +389,8 @@ CUL_FHTTK_Parse($$)
Syncing # start the sync with FHT80B (activate FHT80B sync mode before) - state after syncing is Closed
Closed # set window state to Closed
Open # set window state to Open
+ ReSync # resync virtual sensor with FHT80b after a reset of CUL device. In other words, perform a virtual
+ battery exchange to synchronize the sensor with FHT80b device again.
@@ -456,6 +464,8 @@ CUL_FHTTK_Parse($$)
Syncing # startet die Synchronisation mit dem FHT80B (FHT80B muss sich im Sync mode befinden) - danach wird der state auf "Closed" gesetzt
Closed # setzt den Fensterstatus zu Closed
Open # setzt den Fensterstatus zu Open
+ ReSync # neu synchronisieren des virtuellen Sensor mit dem FHT80b Module. Damit wird ein virtueller Batteriewechsel symuliert und der angelernte
+ Sensor wieder aufsynchronisiert.