There is an error in the standard dzVents template:
It must be:
Suc6!
Standard dzVents template afterMin
Moderator: leecollings
-
DomoticaRob
- Posts: 80
- Joined: Sunday 29 November 2015 14:03
- Target OS: Raspberry Pi / ODroid
- Domoticz version: V4.9700
- Location: Halle, the Netherlands
- Contact:
-
dannybloe
- Posts: 1355
- Joined: Friday 29 August 2014 11:26
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Ermelo
- Contact:
Re: Standard dzVents template afterMin
Ah, good catch. Fixed it in the next version. Thanks.
Creator dzVents - RPi3, loads of zwave devices, esp8266, evohome.
-
DomoticaRob
- Posts: 80
- Joined: Sunday 29 November 2015 14:03
- Target OS: Raspberry Pi / ODroid
- Domoticz version: V4.9700
- Location: Halle, the Netherlands
- Contact:
Re: Standard dzVents template afterMin
Hello Danny,
I have cachet another one:
I think it must be scenes.
Suc6!
I have cachet another one:
I think it must be scenes.
Suc6!
-
DomoticaRob
- Posts: 80
- Joined: Sunday 29 November 2015 14:03
- Target OS: Raspberry Pi / ODroid
- Domoticz version: V4.9700
- Location: Halle, the Netherlands
- Contact:
Re: Standard dzVents template afterMin
Can I make my own template?
Where is it stored?
Where is it stored?
-
dannybloe
- Posts: 1355
- Joined: Friday 29 August 2014 11:26
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Ermelo
- Contact:
Re: Standard dzVents template afterMin
Not really. It is sort of hard coded into the editor unfortunately 
Creator dzVents - RPi3, loads of zwave devices, esp8266, evohome.
-
DomoticaRob
- Posts: 80
- Joined: Sunday 29 November 2015 14:03
- Target OS: Raspberry Pi / ODroid
- Domoticz version: V4.9700
- Location: Halle, the Netherlands
- Contact:
Re: Standard dzVents template afterMin
No problem.
I made my own already, called it dz_Template.lua, start with this one, make my changes and save it with a new name.
I made my own already, called it dz_Template.lua, start with this one, make my changes and save it with a new name.
-
dannybloe
- Posts: 1355
- Joined: Friday 29 August 2014 11:26
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Ermelo
- Contact:
Re: Standard dzVents template afterMin
what's the template look like?
Creator dzVents - RPi3, loads of zwave devices, esp8266, evohome.
-
DomoticaRob
- Posts: 80
- Joined: Sunday 29 November 2015 14:03
- Target OS: Raspberry Pi / ODroid
- Domoticz version: V4.9700
- Location: Halle, the Netherlands
- Contact:
Re: Standard dzVents template afterMin
Hello Danny,
I just use yours with the two corrections -> 'afterMin' and 'scenes'
As soon as I have some time I will make a more extended version with statements I will use often.
I just use yours with the two corrections -> 'afterMin' and 'scenes'
As soon as I have some time I will make a more extended version with statements I will use often.
Code: Select all
-- Check the wiki at
-- http://www.domoticz.com/wiki/%27dzVents%27:_next_generation_LUA_scripting
return {
-- 'active' controls if this entire script is considered or not
active = true, -- set to false to disable this script
-- trigger
-- can be a combination:
on = {
devices = {
-- scripts is executed if the device that was updated matches with one of these triggers
'device name', -- device name
'abc*', -- triggers for all devices which name begins with abc
258, -- id
},
timer = {
-- timer triggers.. if one matches with the current time then the script is executed
'at 13:45',
'at 18:37',
'every 3 minutes on mon,tue,fri at 16:00-15:00'
}
},
-- actual event code
-- in case of a timer event or security event, device == nil
execute = function(domoticz, device)
--[[
The domoticz object holds all information about your Domoticz system. E.g.:
local myDevice = domoticz.devices('myDevice')
local myVariable = domoticz.variables('myUserVariable')
local myGroup = domoticz.groups('myGroup')
local myScene = domoticz.scenes('myScene')
The device object is the device that was triggered due to the device in the 'on' section above.
]] --
-- example
if (device.state == 'On') then
device.switchOff().afterMin(2)
domoticz.notify('Light info', 'The light ' .. device.name .. ' will be switched off soon')
end
end
}Who is online
Users browsing this forum: No registered users and 1 guest