From 32819bffc05fc8acbdbfeb2ee7e2ba0f8ae5b16b Mon Sep 17 00:00:00 2001 From: phenning Date: Wed, 26 Apr 2017 14:10:08 +0000 Subject: [PATCH] 70_DoorPi.pm: Neue Version mit Bugfixes git-svn-id: https://svn.fhem.de/fhem/trunk@14111 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/contrib/DoorPi/70_DoorPi.pm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/fhem/contrib/DoorPi/70_DoorPi.pm b/fhem/contrib/DoorPi/70_DoorPi.pm index 818717a59..ceec49bc6 100644 --- a/fhem/contrib/DoorPi/70_DoorPi.pm +++ b/fhem/contrib/DoorPi/70_DoorPi.pm @@ -41,7 +41,7 @@ use vars qw{%attr %defs}; sub Log($$); #-- globals on start -my $version = "2.0alpha8"; +my $version = "2.0alpha9"; #-- these we may get on request my %gets = ( @@ -597,9 +597,9 @@ sub DoorPi_GetLockstate($) { } } if( $ret =~ /^locked.*/){ - DoorPi_Cmd($hash,"locked"); + DoorPi_Cmd($hash,"doorlocked"); }elsif( $ret =~ /^unlocked.*/){ - DoorPi_Cmd($hash,"unlocked"); + DoorPi_Cmd($hash,"doorunlocked"); } readingsSingleUpdate($hash,"lockstate",$ret,1); return $ret; @@ -654,7 +654,8 @@ sub DoorPi_GetConfig { my $keyboards = $jhash0->{"config"}->{"keyboards"}; my $fskey; my $fscmds; - foreach my $key (sort(keys $keyboards)) { + + foreach my $key (sort(keys %{$keyboards})) { $fskey = $key if( $keyboards->{$key} eq "filesystem"); } @@ -673,8 +674,7 @@ sub DoorPi_GetConfig { #-- initialize command list @{$hash->{HELPER}->{CMDS}} = (); - foreach my $key (sort(keys $fscmds)) { - + foreach my $key (sort(keys %{$fscmds})) { #-- check for door buttons if($key =~ /dooropen/){ push(@{ $hash->{HELPER}->{CMDS}},"$door");