back to basics
Posted: Thursday 18 July 2019 12:06
hi everyone
its been forever since i picked up domoticz and had to blow away my config to get everything back up....
i think ive completely forgotten my dzvents, which is a shame as i was getting quite good at it...
can anyone help me jumpstart my memory so i can get back into it?
As you can see i havent got far
so my situation is as follows
i have the following devices
Rflink power monitor hooked directly to my heat pump
1 rf push button (Heatpump on)
1 rf push buttpon Heatpump off)
1 dummy switch (heater control)
so what i would like to achieve is that when i turn the heater on using the dumy switch in domoticz that it checks if the power meter has a reading sets the switch to on and turns it on if needed....
i could just go for the classic turn it on and or off....
but im after something a little more elgant, this way it doesnt matter if someone grabs the remote and changes the setting or muchs around pressing buttons, the power monitor is aware of if the power is on or not and takes care of it
18 months ago i could of written this is my sleep, but the whole thing escapes me at the moment
its been forever since i picked up domoticz and had to blow away my config to get everything back up....
i think ive completely forgotten my dzvents, which is a shame as i was getting quite good at it...
can anyone help me jumpstart my memory so i can get back into it?
Code: Select all
local Heatpower = 11
local Heatswitch = 12
return {
active = {
true,
on = {
devices = {
12, -- Heater Switch
11 -- Heater Power Monitor
},
},
data = {
},
logging = {
level = domoticz.LOG_DEBUG,
marker = "Cool script"
},
execute = function(domoticz, triggeredItem, info)
if Heatpower.WhActual > 0 then
Heatswitch.Switchon
end
end
}
}As you can see i havent got far
so my situation is as follows
i have the following devices
Rflink power monitor hooked directly to my heat pump
1 rf push button (Heatpump on)
1 rf push buttpon Heatpump off)
1 dummy switch (heater control)
so what i would like to achieve is that when i turn the heater on using the dumy switch in domoticz that it checks if the power meter has a reading sets the switch to on and turns it on if needed....
i could just go for the classic turn it on and or off....
but im after something a little more elgant, this way it doesnt matter if someone grabs the remote and changes the setting or muchs around pressing buttons, the power monitor is aware of if the power is on or not and takes care of it
18 months ago i could of written this is my sleep, but the whole thing escapes me at the moment