OH2 Z-Wave refactoring and testing... and SECURITY

Thanks for investigating and finding this commonality - I’ll see if I can see any issue here…

Done.

Was this the change to deal with devices that don’t wake up?

Yes, I already had a quick look at this and I don’t think it’s relevant as it’s related to the FAILED check and I think this code is now gone with the change in how this works… I need to double check though as I don’t currently have this code loaded.

This code is still in play, but it clearly went past this as this code would set the state to DONE if it was already initialised, and from your log, we’re in state PING which is after FAILED_CHECK, and clearly before DONE…

Do you have a longer log of the initialisation? I’f like to see what’s happening before it gets into this state…

No but I’ll create one.

Thanks. Ping it over by email if you like…

Starting at 2018-06-24 13:14:58.382

  • deleted the thing for node 72
  • ran discovery
  • added node 72 from inbox

https://drive.google.com/open?id=1p31MNpx8AmuiPK31EfJm2Bk44P5TJgqU

One other data point…

I excluded one of the Minimotes, did a factory reset, then included it into the network. Appears to have the same behavior as above. It’s node 93 in this log.
https://drive.google.com/open?id=17wZy49pAO59SmPpO-kz9IF3d2tyzJr8I

Also wanted to add that I’ve successfully migrated 6 other types of battery powered devices (ST814, ST812, FGFS101, FGMS001, ZW100, ZW097) – about 13 devices in total. As soon as these devices were woken up, they successfully initialized.

Interesting that you succeeded with your ST814. Mine never worked. Did you do something special ?
If I correctly remember the analysis, it was considered as failed by the controler.

This will not be device specific - I’d suggest to try again with the new dead code version that @mhilbush is using.

I actually have 6 of ST814’s, all of which are working well. I didn’t do anything special. They were fully initialized by the binding the first time I woke them up.

How do you wake them up ?

Triple press the C/F button (2nd button from the left). You will see a little symbol flash on the LCD display indicating it is awake.

@chris Looking at the logs I provided… Could it be that the node doesn’t indicate it supports WAKE_UP in the NIF? Then when it gets to this bit of code, it doesn’t process it because it thinks the node doesn’t support WAKE_UP (even though it obviously generated a WAKE_UP)?

I don’t recall this check being in the master version of the binding.

I’ll try and take a look at this tomorrow.

Looking at the log above though, this doesn’t look the same. In that log it just shows that the command class isn’t known. This is correct since the init stage is PING - as such we haven’t received the NIF, and therefore don’t know what command classes are supported yet.

I have an idea to skip this check for battery devices - PING shouldn’t be needed for battery devices because they need to explicitly send the wakeup. I think I did this in a previous version.

This is all completely new from the old binding. The old binding had separate queues for wakeup - the dev version doesn’t. It keeps everything in a single queue to simplify the transaction management, and then has to know if the device is awake.

So there are two logs above. The first one shows the device being discovered (it already is included in the network). The second one shows the device being included into the network.

I was looking at the second one where it looked like the NIF had been received (and it didn’t include WAKE_UP).

Of course, I might be misreading this.

It seems a little odd that this is just being exposed given how widely the dev version is being used. Is anyone else using any of these devices with the dev version? Have you been able to discover the device?
Aeon Minimote
Aeon Wallmote
Fibaro Button
Ecolink TILTZWAVE2 Garage Door Sensor

I’ve not looked at the detailed logs you posted yet - just the log entry above -: