Sorry, still getting my feet wet in Edge Driver and LUA.
Trying to figure the right syntax for adding a variable object reference.
I am trying to write code to vary the switch number (1 through 5) in this line.
device:emit_component_event(device.profile.components.switch1, capabilities.switch.switch.on())
i.e. I would like to modify this based on switch number.
device:emit_component_event(device.profile.components.switch1, capabilities.switch.switch.on())
device:emit_component_event(device.profile.components.switch2, capabilities.switch.switch.on())
…
device:emit_component_event(device.profile.components.switch3, capabilities.switch.switch.on())
Trying to add construct to vary the components switch number.
Thanks for your help.