Version 1.4
156 downloads
Initially it was supposed to be a simple Sleep Timer, similar to what we have in TV but later I added some new functions and now it is a simple Scheduler and Sleep Timer in one VD.
Features:
Sleep Timer - just set the time after which the device will be turned off or turned on
Scheduler - set the time when the the device should be turned on and the time when the the device should be turned off (or in the reverse order - first turn off and then turn on)
Filtering devices - you can choose only devices with turnOff action attribute
Filtering rooms - you can choose only rooms which have devices with turnOff action attribute
_ - change on/off setting time
✔ - add device to schedule
❌ - remove device from schedule; triple click to clear the schedule
Refresh button - you don't need to touch it. It's called programmatically
Displaying the current schedule
Logging the events to debug window: add, remove, turn on, turn off
automatic support for plugins with turnOff action attribute
support for custom virtual devices and plugins
instant turn on/off (VD and plugins also)
presenting the current device state ( ⚡ when the device is on, and - when is off)
Customization:
change the VD labels to your own language
change the texts in the Refresh button code and in the main code:
local lT = {
newLine = "<br/>", -- change to "\n" if you use this VD on iOS mobile mainly or " " for Android
scheduledDevices = "Scheduled devices"
}
Actually there is a problem with breaking lines in labels, so you can choose new line char. More details here.
add your own virtual devices or plugins in main loop code:
local extraDevices = {
-- deviceId, commandOn, parameterOn, commandOff, parameterOff
["335"] = { "pressButton", "2", "pressButton", "3" },
["339"] = { "setVolume", "20", "setMute", "" },
}
icons:
Enjoy...