Plugin has been unpublished by me. I don’t want to continue to work for such a company.
Description:
This plugin allows you to let lights be turned on and off automatically/randomly when you are in vacation or absent. It allows you to define in how many times in which phase it should turn on lights and how long they are supposed to be running on which level. Based on variables you define the plugin does all the calculations itself. These ghost a generated newly in every phase, so on each day the times when a light turns on and how long it stays on will vary.
As for the moment one plugin device is capable of controlling up to eight lights. But since you can create further devices the number of controlled lights is basically unlimited.
Tab “Lights & Times” => Settings/Variables:
LightID: Defines which light is controlled by the ghost.
Start: Defines when the on phase starts.
Stop: Defines when the on phase ends.
Cycles: Defines how many times a light will be turned on and off.
OnTime: Defines how long a light will stay on.
Variation: Defines the variation of the OnTime.
DimLevel: Defines the Dimlevel of a light (if it is sett to zero it will be choosen randomly)
Example:
LightID: 7
Start: 09:00
Stop: 10:00
Cycles: 5
OnTime: 5
Variation: 2
DimLevel: 0
The example above will turn the light with the id 10 on/off 5 times in between 09:00 and 10:00 for 3-7 Minutes with a random dimmer level.
The Tab “Ghosts” will then show something like (Note: The plugin only generated 7 ghosts, not ten. It realized itself that in one hour you cant fit 10 phases of up to seven minutes):
Name ID From To On
Ghost117 7 9:03 9:09 21.12.2012
Ghost127 7 9:20 9:24 21.12.2012
Ghost137 7 9:25 9:30 21.12.2012
Ghost147 7 9:31 9:35 21.12.2012
Ghost157 7 9:36 9:42 21.12.2012
Ghost167 7 9:43 9:48 21.12.2012
Ghost177 7 9:49 9:54 21.12.2012
Icon State:
Red: Vacation Ghost is disabled.
Orange: Vacation Ghost is enabled and ghost have been calculated. But no ghost ist active.
Green: Ghost is active (a light is actually turned on by a ghost).
Luup Code:
To enable Vacation Ghost:
luup.variable_set("urn:upnp-org:serviceId:VGhost1","OnOff","1",devID)
To disable Vacation Ghost:
luup.variable_set("urn:upnp-org:serviceId:VGhost1","OnOff","0",devID)
Replace “devID” with the devices id number from your vacation ghost device.
Step by Step Installation and example Setup:
Installation:
- Install the plugin from apps.mios.com.
- Reload the lua engine by clicking the “reload” button on your vera’s webinterface.
- Reload the Webinterface in your browser by reloading (usually F5) the page.
Setup:
- Open the device “Vacation Ghost” on your vera. Don’t enable it yet. The icon of the device should be red.
- Open the Tab “Lights & Times”
- In this example we will setup one light which will be controlled by the ghost. In the first row “LightID:” ind the first ligne, choose which light should be controlled.
- In the row “Start” choose when the OnPhase starts. For example 10:00 AM.
- In the row “Stop” choose when the OnPhase stops. For example 11:30 AM.
- In the row “Cycles” choose how many times the light should be turned on wihin the onPhase (from “Start:” to “Stop:”). For example 4.
- In the row “OnTime” choose how long the lights should be turned on. For example 10 Minutes.
- In the row “Variation” choose how much the length which you defined in “OnTime” should vary. For example 5 Minutes. (Since you have Setup “OnTime” to 10 in step 7, the ghost will now turn on the lights from 5 (OnTime-Variation) to 15 (OnTime+Variation) Minutes.
- In the row “DimLevel” choose to which level the light should be dimmed. If it is a switch this field may be ignored. If it is a dimmer and you set “DimLevel” to zero, the dimlevel will be randomized in between 0 and 100.
- Hit the “Save” Button on the bottom of the tab to save your settings.
- Go to the “Control” Tab and enable the ghost. Wait till the icon of the ghost device turns orange, meaning the ghost has calculated the ghost.
The ghost should now calculate 4 Ghost, which all have a length from 5 to 15 Minutes, which all run in between 10:00 AM and 11:30 PM. When you leave the ghost enabled these lights will be turned on and off according to the calculated ghost. If the ghost has calculated and turned on a light, the icon will be green. The calculated ghost can be seen in the tab “Ghosts”.
Once all lights have been turned on and off and all ghost have passed, the plugin will wait until the next day and then recalculate the ghost. This means the Vacation Ghost will recalculate the ghost every day within your parameters.
If you change the settings in the tab “Lights & Times”, disable the ghost, wait till the icon is red. Then enable it again after changing your settings, wait till the icons becomes orange or green again.
Versions:
Version 0.90:
http://forum.micasaverde.com/index.php/topic,12952.msg95549.html#msg95549
Version 0.91:
http://forum.micasaverde.com/index.php/topic,12952.msg124453.html#msg124453
Version 0.92:
http://forum.micasaverde.com/index.php/topic,12952.msg127475.html#msg127475
Version 0.94:
http://forum.micasaverde.com/index.php/topic,12952.msg129213.html#msg129213
Version 0.95:
http://forum.micasaverde.com/index.php/topic,12952.msg129364.html#msg129364