PROPLANTA: INTERVAL

git-svn-id: svn://svn.code.sf.net/p/fhem/code/trunk@7064 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
tpoitzsch
2014-11-25 21:13:14 +00:00
parent 0fdd5da034
commit b8d360dcf8

View File

@@ -394,7 +394,7 @@ sub PROPLANTA_Define($$)
} }
$hash->{STATE} = "Initializing"; $hash->{STATE} = "Initializing";
$hash->{LOCAL} = 0; $hash->{fhem}{LOCAL} = 0;
$hash->{INTERVAL} = 3600; $hash->{INTERVAL} = 3600;
$hash->{fhem}{modulVersion} = '$Date$'; $hash->{fhem}{modulVersion} = '$Date$';
@@ -436,9 +436,9 @@ sub PROPLANTA_Set($@)
when ("update") when ("update")
{ {
PROPLANTA_Log $hash, 3, "set command: " . $a[1]; PROPLANTA_Log $hash, 3, "set command: " . $a[1];
$hash->{LOCAL} = 1; $hash->{fhem}{LOCAL} = 1;
PROPLANTA_Start($hash); PROPLANTA_Start($hash);
$hash->{LOCAL} = 0; $hash->{fhem}{LOCAL} = 0;
} }
default default
{ {
@@ -487,7 +487,7 @@ sub PROPLANTA_Start($)
$hash->{INTERVAL} = AttrVal( $name, "INTERVAL", $hash->{INTERVAL} ); $hash->{INTERVAL} = AttrVal( $name, "INTERVAL", $hash->{INTERVAL} );
if(!$hash->{LOCAL} && $hash->{INTERVAL} > 0) { if(!$hash->{fhem}{LOCAL} && $hash->{INTERVAL} > 0) {
# set up timer if automatically call # set up timer if automatically call
RemoveInternalTimer( $hash ); RemoveInternalTimer( $hash );
InternalTimer(gettimeofday() + $hash->{INTERVAL}, "PROPLANTA_Start", $hash, 1 ); InternalTimer(gettimeofday() + $hash->{INTERVAL}, "PROPLANTA_Start", $hash, 1 );
@@ -730,7 +730,7 @@ PROPLANTA_Html($)
<b>Attributes</b> <b>Attributes</b>
<ul> <ul>
<br> <br>
<li><code>Interval &lt;seconds&gt;</code> <li><code>INTERVAL &lt;seconds&gt;</code>
<br> <br>
Poll interval for weather data in seconds (default 3600 = 1 hour) Poll interval for weather data in seconds (default 3600 = 1 hour)
</li><br> </li><br>