mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-01-31 06:39:11 +00:00
FULLY: Motion detection
git-svn-id: https://svn.fhem.de/fhem/trunk@15416 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
696a2fdcf6
commit
1b1d39ee42
@ -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.
|
||||
- feature: 89_FULLY: Turn motion detection on or off
|
||||
- new: 89_FULLY: Control Fully Browser
|
||||
- bugfix: 72_FB_CALLMONITOR: replace all unicode placeholders correctly
|
||||
in reverse search results
|
||||
|
@ -1,6 +1,6 @@
|
||||
##############################################################################
|
||||
#
|
||||
# 89_FULLY.pm 0.3
|
||||
# 89_FULLY.pm 0.4
|
||||
#
|
||||
# $Id$
|
||||
#
|
||||
@ -32,7 +32,7 @@ sub FULLY_GotDeviceInfo ($);
|
||||
sub FULLY_Abort ($);
|
||||
sub FULLY_UpdateReadings ($$);
|
||||
|
||||
my $FULLY_VERSION = "0.3";
|
||||
my $FULLY_VERSION = "0.4";
|
||||
my $FULLY_TIMEOUT = 4;
|
||||
my $FULLY_POLL_INTERVAL = 3600;
|
||||
|
||||
@ -173,7 +173,8 @@ sub FULLY_Set ($@)
|
||||
my ($hash, $a, $h) = @_;
|
||||
my $name = shift @$a;
|
||||
my $opt = shift @$a;
|
||||
my $options = "clearCache:noArg exit:noArg lock:noArg off:noArg on:noArg restart:noArg unlock:noArg speak url";
|
||||
my $options = "clearCache:noArg exit:noArg lock:noArg motionDetection:on,off off:noArg ".
|
||||
"on:noArg restart:noArg unlock:noArg speak url";
|
||||
my $response;
|
||||
|
||||
# Fully commands without argument
|
||||
@ -187,6 +188,13 @@ sub FULLY_Set ($@)
|
||||
if (exists ($cmds{$opt})) {
|
||||
$response = FULLY_Execute ($hash, $cmds{$opt}, undef);
|
||||
}
|
||||
elsif ($opt eq 'motionDetection') {
|
||||
my $state = shift @$a;
|
||||
return "Usage: set $name motionDetection {on|off}" if (!defined ($state));
|
||||
my $value = $state eq 'on' ? 'true' : 'false';
|
||||
$response = FULLY_Execute ($hash, "setBooleanSetting",
|
||||
{ "key" => "motionDetection", "value" => "$value" });
|
||||
}
|
||||
elsif ($opt eq 'speak') {
|
||||
my $text = shift @$a;
|
||||
return "Usage: set $name speak {Text}" if (!defined ($text));
|
||||
@ -480,6 +488,9 @@ sub FULLY_UpdateReadings ($$)
|
||||
<li><b>set <name> exit</b><br/>
|
||||
Terminate Fully.
|
||||
</li><br/>
|
||||
<li><b>set <name> motionDetection { on | off }</b><br/>
|
||||
Turn motion detection by camera on or off.
|
||||
</li><br/>
|
||||
<li><b>set <name> { lock | unlock }</b><br/>
|
||||
Lock or unlock display.
|
||||
</li><br/>
|
||||
|
Loading…
Reference in New Issue
Block a user