89_VCONTROL.pm: disable attrib now with function

git-svn-id: svn://svn.code.sf.net/p/fhem/code/trunk@7915 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
adamwit
2015-02-08 15:21:55 +00:00
parent ac856f906a
commit 3aa00c236c

View File

@@ -277,7 +277,13 @@ VCONTROL_Poll($)
my $hash = shift;
my $name = $hash->{NAME};
#global Module Trigger that Polling is started
$poll_now=POLL_ACTIVE;
if( AttrVal($name, "disable", 0 ) == 1 )
{
$poll_now = POLL_PAUSED;
Log3 $name, 5, "VCONTROL: Poll disabled!";
}
else
{$poll_now=POLL_ACTIVE;}
$poll_duration = gettimeofday();
Log3 $name, 4, "VCONTROL: Start of Poll !";
my $timer = gettimeofday()+$hash->{INTERVAL};