Device type script triggers on all devices with built in editor?
Posted: Friday 19 January 2018 22:52
I have a device called "P_tot" and a script "script_device_p_tot.lua" in /scripts/lua.
This works fine, and the script is only executed when the utility sensor "P_tot" is updated.
The problem: If I instead create a new script of type "device" in the built-in script editor and paste the code there and save it, it gets triggered when ANY device is updated. I have tried saving the script as "P_tot" and "p_tot" with the same result.
I also tested a script that triggers on uservariables (with the built-in editor) but that works fine!
Any ideas?
This works fine, and the script is only executed when the utility sensor "P_tot" is updated.
The problem: If I instead create a new script of type "device" in the built-in script editor and paste the code there and save it, it gets triggered when ANY device is updated. I have tried saving the script as "P_tot" and "p_tot" with the same result.
I also tested a script that triggers on uservariables (with the built-in editor) but that works fine!
Any ideas?