The Future of Z-Wave in HA - QT-OpenZWave

Glad I wasn’t missing something obvious. I’ll just rotate the logs frequently while this is in early development.

I have an issue where various zwave devices become “unavailable” in HA. They are reporting statistics in the mqtt stream so they seem to be alive from the perspective of OZW. Some seem to come back if I restart everything although I have a door sensor that is battery powered that seems not to (although it is also appearing in a statistics message in the mqtt stream). Anyone know how to get HA to try again on a device it thinks is unavailable?

Can anyone tell me what to post to MQTT in order for me to include a new Z-Wave node?

Under Developer Tools -> Services there is a new zwave_mqtt.add_node service you can call.

1 Like

This worked for me. Thank you so much for the quick response. My new node is added.

Should I be adding all nodes as secure? I read somewhere that my z-wave network would be more responsive if I had non-secure nodes as there is less overhead in the traffic. I see in the readme for that zwave_mqtt.add_node that this may be shortsighted by me. I might need to go back and remove what I have done and start again with all secure.

Secure requires more messages, and will be slower.

I only use security on locks or other similar devices. I use insecure almost everywhere, I can live with the risk of an attacker turning on a light, or knowing the temperature in my room.

On the zwave_mqtt.add_node is there a way I can tell it I would like non secure? I don’t think I have anything z-wave that would require secure (locks like you say).

Wait… on the zwave_mqtt.add_node I see it wants a parameter secure

If I don’t specify is it correct that it adds as non secure?

Hi Guys, I was curious if there was a ‘rough’ ETA on when this would make it in HA. I know its still in early beta, possibly Alpha, so just curious.

2 Likes

I understood S0/S2 security as being a subset of Z-Wave and not compulsory for the features of Z-Wave plus.
I would only use secure if:

  1. Features are only available in secure mode.
  2. For security devices like locks.

Multi-node hopping should still be fine in non-secure include, this is part of the mesh.
Using secure increases traffic.

Someone correct me if I am wrong though :slight_smile:

Reference an item above related to battery powered door sensor not showing as available. (I also opened an issue in the integration github). I get actual mqtt messages for the door (command class 32 Basic Set) to indicate the door opens and then the door closes. However, HA seems to ignore these and leave the state as unavailable. Anyone seeing anything similar or have any suggestion for working around?

If you are only getting Basic Set messages and no others, see if you can configure the device to send Notifications (or Binary) instead. If that is not possible, check how the basic command class is mapped, in the ozwcache.xml file. HA has no idea what to do with the Basic Set message. In the native integration it generates an event. https://github.com/OpenZWave/open-zwave/wiki/CommandClass-Compatibility-Flags#basic-commandclass

@gdt not sure where your reading this (there is a LOT of outdated info on Z-wave) but your off the mark.

There is no relation to ZWave+ and S0 security, other than they were introduced around the same time and ZW+ certification requires devices to support S0. S0 actually sits on top of the protocol so routing etc are not affected by S0.

ZW+ devices are better at routing/meshing, having features like explorer frames etc. if a route fails, there is about 4-5 different steps a device will try before giving up. This includes rediscovering neighbors etc and eventually sending something akin to a Broadcast to all devices.

S0 does introduce a overhead on traffic. Users with moderate size networks often report slow response/latency due to everything being encrypted. I don’t advise either way other than to say if you want everything encrypted be prepared to trade off something for it (latency/responsiveness).

Thanks for setting me straight then. I am not really sure what I read where, but I was trying hard to figure it out - and do network protocols professionally. I am assuming that S0 is the group network key. I think part of the confusion is that all zwave+ have to do S0, and thus many people end up thinking it’s zwave+ feature.

The other confusion is with “Add Node Secure” in the control panel. I am assuming this means “Add Node using S0 Security”. Somewhere, I thought in the HA docs, but probably elsewhere, I remember reading that “add node secure” did a zwave+ inclusion with better meshing. But it sounds like zwave+ is done automatically if there, and there isn’t and shouldn’t be any option to control it. So “Add Node” will still result in Zwave+ improved meshing, etc., but without S0.

Also, https://www.home-assistant.io/docs/z-wave/devices/ says that there have been two extensions to Zwave: Zwave+ and S2. I believe S0 was an extension also, and the “two extensions” language I think contributes to people making the leap that S0 is part of +.

It would be nice if someone posted authorititatively about the security overhead. I am guessing there is some kind of padding to cipher block size and MAC bits. Plus, when talking about latency, there is just the bit transmission time over multiple hops, which is not so bad, and then actual congestion, which is very bad. So far I have not found an rtl_433 type decoder for the Zwave protocol that would let one sort of do a tcpdump like thing.

Searching is your friend. I’ve posted many times on S0 and so forth (probably worthy of setting up a blog one day!). Essentially, for each request/response in non-secure to moving to secure, you go from exchanging 4 packets to exchanging 7-8 packets. Add on to that the micro in devices sip power and generally a LOT slower and I’ve seen RTT times shoot from 40ms to ~2Seconds (to encrypt and decrypt the packets) on older devices.

S2 partially alleviates some of these problems but I’ve only just started on it and it’s a LOT more complicated than S0 so it will be a while.

1 Like

I’ve been holding off for lock support but thinking of installing it this weekend now that fan support is there… For the quick start I see Go to the HomeAssistant integrations page, add Zwave MQTT integration Is that referring to the Z-Wave to MQTT add-on ( /hassio/addon/a0d7b954_zwave2mqtt )?

EDIT: The step for the add-on repository had me confused as I thought it was referring to HACS

Also has anyone found a good way to dump all their zwave entity ids and rename them after migration in bulk fashion… I have 50+ z-wave devices with custom names.

For MQTT zwave goto the MQTT Zwave thread, not this one.

For WHOLE Config editing of entities use something like vsc which can do a search and replace across all your files.

If you didn’t name them to allow this, it’s a lesson for next time.

Just want to give a status update of my first time experience using the latest images and HACS add-on that was published a few hours ago… I ended up rolling back via a snapshot…

  1. I followed the quick start documentation. There needs to be a clarification on the 4th step about adding a custom repository because you can add a custom repository to HACS too (and this is right after the HACS step). Submitted PR (https://github.com/cgarwood/homeassistant-zwave_mqtt/pull/77/files)
  2. After reboots to ensure z-wave wasn’t configured and I rebooted again after removing the z-wave integration (imported from config is what it said). I started up the new add-on and I saw it starting up and I looked in Mqtt.fx and saw the status node saying starting up and logs and entries were flowing in from the z-wave network…
  3. With this running and logging to mqtt… I added the integration via the integrations page and nothing showed up…
  4. I rebooted and still nothing showed up… No errors in the startup logs…
  5. I then looked at the status node and saw that said offline so I restarted the add-on and noticed it added 61 scoped topics in mqtt and only the first node instance had command class entries…
  6. It then stayed at both the running/starting up status for a while so I restarted HA (multiple times) to see if entities would show up as they still weren’t listed…
  7. Looked into my previous config and noticed node 2 was a lock (node one being the z-stick)… I’m wondering if it’s blowing up when getting to this second node.
  8. It added 61 nodes (I know I don’t own 61 z-wave devices…) in sequential order but I know my network nodes well and I had some that never showed up in the network during original pairing and so the node id skipped… Makes me wonder if I have some phantom nodes that are causing issues…

I reverted after I couldn’t get a single entity to be added… I was also trying to track down a management portal and found it… But then I didn’t want to have to configure it all to look at it (it has been a very long day). Would be really nice to update the add-on to expose the management UI (I get that this is all a work in progress). I hope my experience helps in some way.

1 Like