I must be missing something: If I have a device with multiple components, each component containing a switch, for example - how do I know which switch was pressed in my handler?? I can find nothing documented that shows that a component ID is available either to my handler, or that can be specified in the driver template for capability handler declarations.
Typing on my phone so apologies if there are syntax errors.
local function set_switch(driver,device,command) component = command.component end
Thank you! Wouldn’t it be nice if that were documented?!..
There are some multi-endpoint z-wave drivers I’ve been perusing and then experimenting from, plus iterating through the various arguments that get passed to my capability and command class handlers.
I was just about to put a table print in my code so I could see what was in the command argument, when your answer arrived and saved me the trouble! Much appreciated!