understanding devicechanged vs. otherdevices
Posted: Thursday 12 January 2023 20:33
hello,
I have a problem understanding Devicechanged command,
This works ok, giving= LUA: switch is on
gives [string "commandArray = {}..."]:7: attempt to index a nil value (global 'devicechanged')
As far as i understand devicechanged can be a status or a value, a status is stated either 'On' or 'Off" and a value can be a number..
Please help
I have a problem understanding Devicechanged command,
Code: Select all
commandArray = {}
if (otherdevices['Switch on display2004'] == 'On') then
print('switch is on')
end
return commandArray
Code: Select all
commandArray = {}
if (devicechanged['Switch on display2004'] == 'On') then
print('switch is on')
end
return commandArray
As far as i understand devicechanged can be a status or a value, a status is stated either 'On' or 'Off" and a value can be a number..
Please help
