Is there any way to use an entity declared in global_data.lua within the on statement of a dzVents script?
I mean:
This works -->
Code: Select all
return {
on = {
timer = {'every 1 minutes'},
devices = {'Horaires/Start Chauffage','Horaires/Stop Chauffage', 17, 16}
},
Runtime Error in the log: 2021-01-13 13:01:33.368 Status: dzVents: Error (2.4.19): /home/pi/domoticz/scripts/dzVents/scripts/Heating.lua:9: attempt to index global 'helpers' (a nil value)
-->
Code: Select all
return {
on = {
timer = {'every 1 minutes'},
devices = {'Horaires/Start Chauffage','Horaires/Stop Chauffage', domoticz.helpers.IDX_HEATINGSELECTOR, domoticz.helpers.IDX_THERMOSTAT_SETPOINT}
},
Code: Select all
return {
on = {
timer = {'every 1 minutes'},
devices = {'Horaires/Start Chauffage','Horaires/Stop Chauffage', helpers.IDX_HEATINGSELECTOR, helpers.IDX_THERMOSTAT_SETPOINT}
},