Closed robertsLando closed 3 years ago
Lifecycle:
The lifecycle of a node in zwavejs is:
node added
node alive/awake
node ready
interview completed
A node is ready
once we know it is not dead
and we have all the necessary information. That is:
While a node is being interviewed, a bunch of queries are made and you'll either see value added
or value updated
as well as some metadata updated
events.
This interview starts once a node is either awake
or alive
and after it was included.
Once ready
, it is safe to interact with the device, since all values are at least cached. It does not mean that the values are up to date though.
In theory, associations could change (if you control the device with another driver while zwave-js is off).
neighbors are usually updated at the very end of the interview, so you should wait for interview completed there.
In openzwave-shared each valueId was identified by <nodeId>-<cmdClass>-<instance>-<index>
Ex: 1-112-0-0
In zwavejs a valueid is identified by (https://zwave-js.github.io/node-zwave-js/#/api/valueid):
interface ValueID {
commandClass: CommandClasses;
endpoint?: number;
property: number | string;
propertyKey?: number | string;
}
@robertsLando do we still need this?
Nope
This issue will collect some Q/A about the migration from OZW shared and this library