mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-03-04 11:26:55 +00:00
98_Twilight: patch to alow negativ weather horizons from joe99 added
git-svn-id: https://svn.fhem.de/fhem/trunk@11964 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
f6fbdba08b
commit
05cab5ecd7
@ -108,7 +108,8 @@ sub Twilight_Define($$)
|
|||||||
if(int(@a)>4) { if ($a[4] =~ /^[\+-]*[0-9]*\.*[0-9]*$/ && $a[4] !~ /^[\. ]*$/ ) {
|
if(int(@a)>4) { if ($a[4] =~ /^[\+-]*[0-9]*\.*[0-9]*$/ && $a[4] !~ /^[\. ]*$/ ) {
|
||||||
$indoor_horizon = $a[4];
|
$indoor_horizon = $a[4];
|
||||||
if($indoor_horizon > 20) { $indoor_horizon=20;}
|
if($indoor_horizon > 20) { $indoor_horizon=20;}
|
||||||
if($indoor_horizon < 0) { $indoor_horizon= 0;}
|
# minimal indoor_horizon makes values like civil_sunset and civil_sunrise
|
||||||
|
if($indoor_horizon < -6) { $indoor_horizon= -6;}
|
||||||
}else{
|
}else{
|
||||||
return "Argument Indoor_Horizon is not a valid number";}
|
return "Argument Indoor_Horizon is not a valid number";}
|
||||||
}
|
}
|
||||||
@ -752,7 +753,8 @@ sub twilight($$$$) {
|
|||||||
<br><br>
|
<br><br>
|
||||||
<b>indoor_horizon</b>
|
<b>indoor_horizon</b>
|
||||||
<br>
|
<br>
|
||||||
The parameter <b>indoor_horizon</b> gives a virtual horizon higher than 0, that shall be used for calculation of indoor twilight (typical values are between 0 and 6)
|
The parameter <b>indoor_horizon</b> gives a virtual horizon, that shall be used for calculation of indoor twilight. Minimal value -6 means indoor values are the same like civil values.
|
||||||
|
indoor_horizon 0 means indoor values are the same as real values. indoor_horizon > 0 means earlier indoor sunset resp. later indoor sunrise.
|
||||||
<br><br>
|
<br><br>
|
||||||
<b>Weather_Position</b>
|
<b>Weather_Position</b>
|
||||||
<br>
|
<br>
|
||||||
@ -861,6 +863,11 @@ sub twilight($$$$) {
|
|||||||
</table>
|
</table>
|
||||||
</ul>
|
</ul>
|
||||||
<br>
|
<br>
|
||||||
|
Example:
|
||||||
|
<pre>
|
||||||
|
define BlindDown at *{twilight("myTwilight","sr_indoor","7:30","9:00")} set xxxx position 100
|
||||||
|
# xxxx is a defined blind
|
||||||
|
</pre>
|
||||||
|
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
@ -886,7 +893,8 @@ sub twilight($$$$) {
|
|||||||
<br><br>
|
<br><br>
|
||||||
<b>indoor_horizon</b>
|
<b>indoor_horizon</b>
|
||||||
<br>
|
<br>
|
||||||
Der Parameter <b>indoor_horizon</b> bestimmt einen virtuellen Horizont größer 0, der für die Berechnung der Dämmerung innerhalb von Rämen genutzt werden kann (Typische Werte sind zwischen 0 und 6).
|
Der Parameter <b>indoor_horizon</b> bestimmt einen virtuellen Horizont, der für die Berechnung der Dämmerung innerhalb von Rämen genutzt werden kann. Minimalwert ist -6 (ergibt gleichen Wert wie Zivile Dämmerung). Bei 0 fallen
|
||||||
|
indoor- und realer Dämmerungswert zusammen. Werte grösser 0 ergeben frühere Werte für den Abend bzw. spätere für den Morgen.
|
||||||
<br><br>
|
<br><br>
|
||||||
<b>Weather_Position</b>
|
<b>Weather_Position</b>
|
||||||
<br>
|
<br>
|
||||||
@ -992,6 +1000,11 @@ Wissenswert dazu ist, dass die Sonne, abhägnig vom Breitengrad, bestimmte E
|
|||||||
</table>
|
</table>
|
||||||
</ul>
|
</ul>
|
||||||
<br>
|
<br>
|
||||||
|
Anwendungsbeispiel:
|
||||||
|
<pre>
|
||||||
|
define BlindDown at *{twilight("myTwilight","sr_indoor","7:30","9:00")} set xxxx position 100
|
||||||
|
# xxxx ist ein definiertes Rollo
|
||||||
|
</pre>
|
||||||
|
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user