#read zwave config parameter in script/automation

1 messages · Page 1 of 1 (latest)

tepid tulip
#

I am looking for a way to read a specific config parameter using a script or automation. Is such a thing possible? I know you can use zwave_js.invoke_cc_api but I dont know how to get a response from that.

action: zwave_js.invoke_cc_api
data:
  device_id:
    - 4ecb15be7211864018cfa2150db71f3d
  command_class: "112"
  method_name: get
  parameters:
    - 8

Seems to work, but theres no response.

stiff vessel
#

Is this an unknown parameter or something?

#

All the defined parameters already have associated entities. If it's defined you can just enable the entity and use it like any other.

tepid tulip
#

I guess so, thats a valid point. I needed it for a specific parameter but tdecided to make a script that can be called on any parameter. In such a case it will not be enabled, but for the specific case I need, yes, it can be done that way.

stiff vessel
#

I would recommend the entities. AFAIK none of the Z-Wave actions have support for responses.

tepid tulip
#

Would you know if there is a way to programatically enable entities maybe using rest appi and curl? or is the only way by gui or dangerously by editing core registry?

stiff vessel
#

I am not aware of a way. What are you trying to do?

tepid tulip
#

Well I did it manually, but for over 30 devices with more on the way, i would make a script that repeats for each device and enables the disabled entity. Its if I want to do it for another entity or if I would want to temporarily enable all disabled entities on a specific device for testing purposes and then disable them.

#

Use case of all entities is a door/temp sensor that has some extra switches for tampering etc that are not showing the right state and I want to see if it is maybe being in one of the other disabled entities which are hard to know from the names.

stiff vessel
#

Yeah, you can use the entity list, filter on the name, and enable them in bulk.

tepid tulip
#

i did all that, I'm stuck by the action to enable them.

#

Maybe that's considered the easy part, but I couldn't find anywhere that said how to do it.

#

Looking again, i found this https://github.com/frenck/spook. I guess I'll check it out and see what it does.