From a44dc21d1a8cac71b12c966372cbc78963313bdc Mon Sep 17 00:00:00 2001 From: rudolfkoenig Date: Sat, 15 Jan 2011 11:51:16 +0000 Subject: [PATCH] threestatesensor changes git-svn-id: https://fhem.svn.sourceforge.net/svnroot/fhem/trunk/fhem@803 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- FHEM/10_CUL_HM.pm | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/FHEM/10_CUL_HM.pm b/FHEM/10_CUL_HM.pm index 106c25bd9..5ece89e43 100755 --- a/FHEM/10_CUL_HM.pm +++ b/FHEM/10_CUL_HM.pm @@ -268,20 +268,25 @@ CUL_HM_Parse($$) } elsif($st eq "threeStateSensor") { ##################################### + push @event, "cover:closed" if($p =~ m/^0601..00$/); + push @event, "cover:open" if($p =~ m/^0601..0E$/); + push @event, "state:alive" if($p =~ m/^0601000E$/); + if($p =~ m/^....C8/) { - push @event, "state:open"; + push @event, "contact:open"; if($id eq $dst) { CUL_HM_SendCmd($shash, "++8002".$id.$src."0101". # Send Ack. "C8"."0028", 1, 0); } } elsif($p =~ m/^....00/) { - push @event, "state:closed"; + push @event, "contact:closed"; if($id eq $dst) { CUL_HM_SendCmd($shash, "++8002".$id.$src."0101". # Send Ack. "00"."0028", 1, 0); } + } push @event, "unknownMsg:$p" if(!@event); } elsif($st eq "THSensor") { ##########################################