2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-04-21 14:04:15 +00:00

74_AMAD: statusRequest every Time

git-svn-id: https://svn.fhem.de/fhem/trunk@12731 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
markooldenburg 2016-12-09 20:37:53 +00:00
parent 358fd981d1
commit 1cfde3005d
2 changed files with 6 additions and 4 deletions

View File

@ -1,5 +1,6 @@
# Add changes at the top of the list. Keep it in ASCII, and 80-char wide.
# Do not insert empty lines here, update check depends on it.
- update: 74_AMAD: statusRequest every Time
- change: 93_DbRep: code reviewed, no functional changes
- change: 93_DbRep: DbRep version as INTERNAL, check if DBI module is
installed

View File

@ -37,7 +37,7 @@ use TcpServerUtils;
use Encode qw(encode);
my $modulversion = "2.6.6";
my $modulversion = "2.6.7";
my $flowsetversion = "2.6.7";
@ -589,14 +589,15 @@ sub AMAD_Set($$@) {
|| lc $cmd eq 'vibrate') {
Log3 $name, 5, "AMAD ($name) - set $name $cmd ".join(" ", @val);
return AMAD_SelectSetCmd( $hash, $cmd, @val ) if( lc $cmd eq 'statusrequest' );
return "set command only works if state not equal initialized" if( ReadingsVal( $hash->{NAME}, "state", 0 ) eq "initialized");
return "Cannot set command, FHEM Device is disabled" if( AttrVal( $name, "disable", "0" ) eq "1" );
return "Cannot set command, FHEM Device is unknown" if( ReadingsVal( $name, "deviceState", "online" ) eq "unknown" );
return "Cannot set command, FHEM Device is offline" if( ReadingsVal( $name, "deviceState", "online" ) eq "offline" );
return AMAD_SelectSetCmd( $hash, $cmd, @val ) if( @val ) || ( lc $cmd eq 'statusrequest' ) || ( lc $cmd eq 'activatevoiceinput' ) || ( lc $cmd eq 'vibrate' ) || ( lc $cmd eq 'currentflowsetupdate' );
return AMAD_SelectSetCmd( $hash, $cmd, @val ) if( @val ) || ( lc $cmd eq 'activatevoiceinput' ) || ( lc $cmd eq 'vibrate' ) || ( lc $cmd eq 'currentflowsetupdate' );
}
return "Unknown argument $cmd, bearword as argument or wrong parameter(s), choose one of $list";
@ -1716,4 +1717,4 @@ sub AMAD_decrypt($) {
</ul>
=end html_DE
=cut
=cut