This repository has been archived by the owner on Aug 2, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Module thc_RandomLight
Drolla edited this page Mar 1, 2015
·
14 revisions
Defines the random control settings for one device
Parameters | Description |
---|---|
Device | Device identifier |
-time <OnOffTimeExpressionList> - List of 4 time values
{On1, Off1, On2, Off2} that corresponds to the light enable and disable times in the morning and the evening. The time is specified in hours and it can be an expressions (e.g. $SunriseT-0.3)
Parameters | Description |
---|---|
[-min_intervall <MinIntervall> | Minimum interval time in hours. Default is 0.5 (=30'). |
[-probability_on <ProbabilityOn> | Value between 0 and 1 that specifies the probability that the light is on. Default: 0.5 |
[-default 0|1 | If set to '1' the device is considered to be switched on if no other devices is on. |
Define LightSalon,state -time {7.2 $SunriseT-0.3 $SunsetT+0.0 21.5} \
-min_intervall 0.30 -probability_on 0.2
<thc_RandomLight::Control>
Applies random settings to the lights
Parameters | Description |
---|---|
[Force] | If define the lights are set to this value (needs to be 0 or 1). |
DefineJob -tag RdmLight -repeat 1m -description "Random light" {
thc_RandomLight::Control}
thc_RandomLight::Control 0
<thc_RandomLight::Define>
Evaluates sun rise and set time. These two times are stored respectively inside the variables SunriseT and SunsetT. The
Longitude - Geographical longitude
Latitude - Geographical latitude
Zone - Time zone
namespace eval thc_RandomLight {
set Longitude 6.8250
set Latitude 47.1013
set Zone 2 }
DefineJob -tag EvalSun -time 01h -repeat 24h -init_time +0 \
-description "Evaluate the sun shine time" {
thc_RandomLight::EvaluateSunRiseSunSet}
<thc_RandomLight::Define>
THC, Tight Home Control - See THC index register - THC repository on github.com/Drolla/thc_v1