Search found 5 matches

by BerryB
Friday 02 June 2023 13:44
Forum: dzVents
Topic: turns on a switch every time the air sensor value is 12
Replies: 15
Views: 1125

Re: turns on a switch every time the air sensor value is 12

The 'every minute' part should be removed as it will mix up the device setup: in 'execute = function(domoticz,device)' the device parameter is filled with the triggered device. When execute is triggered by the timer, device is a timer object and the declaration of device.temperature will fail as a ...
by BerryB
Friday 02 June 2023 11:19
Forum: dzVents
Topic: turns on a switch every time the air sensor value is 12
Replies: 15
Views: 1125

Re: turns on a switch every time the air sensor value is 12

I think I solved it. Don't know exactly if I did the repeat every minute ok? local switchDeviceID = 135 -- Vervang 123 door het werkelijke apparaat-ID van de schakelaar return { on = { timer = { 'every minute' } }, on = { devices = { 'SonofGTemperatuur' -- Vervang 'temperatuursensor' door het ...
by BerryB
Friday 02 June 2023 9:45
Forum: dzVents
Topic: turns on a switch every time the air sensor value is 12
Replies: 15
Views: 1125

Re: turns on a switch every time the air sensor value is 12

Probably because you are a new user. Are there urls in the code? No there are no URL's. I think I am this close solving the problem. Maybe I'm not giving the temp sensor a "start temp"? ####.updateTemperature(11) error is : attempt to compare nil with number The ### is in my script the name of the ...
by BerryB
Thursday 01 June 2023 11:55
Forum: dzVents
Topic: turns on a switch every time the air sensor value is 12
Replies: 15
Views: 1125

Re: turns on a switch every time the air sensor value is 12

I tried the script but it gives an error: attempt to compare number with nil What am I doing wrong here? Thanks in advance. Ps. trying to figure out how to paste my code beneath. Some device value probably wrong in your script. But it is important to know in what line of your script the error ...
by BerryB
Thursday 01 June 2023 8:50
Forum: dzVents
Topic: turns on a switch every time the air sensor value is 12
Replies: 15
Views: 1125

Re: turns on a switch every time the air sensor value is 12

I tried the script but it gives an error: attempt to compare number with nil
What am I doing wrong here? Thanks in advance.

Ps. trying to figure out how to paste my code beneath.