cgarwood / homeassistant-zwave_mqtt

Limited Pre-Release of the new OZW1.6 Z-Wave component. Currently has limited platform support. Check the README for more details.
72 stars 8 forks source link

Battery powered node shows as unavailable even after a wakeup event #75

Closed kevinkahn closed 4 years ago

kevinkahn commented 4 years ago

I have a battery powered door sensor. After restarting OZW and HA it shows as unavailable. Sometimes it eventually becomes available. However, even when an actual event appears for the device via the mqtt channel is may stay unavailable. Here is a specific example from monitoring the mqtt traffic related to the node:

OpenZWave/1/node/22/instance/1/commandclass/32/value/369623057/

{
    "Label": "Basic",
    "Value": 255,
    "Units": "",
    "Min": 0,
    "Max": 255,
    "Type": "Byte",
    "Instance": 1,
    "CommandClass": "COMMAND_CLASS_BASIC",
    "Index": 0,
    "Node": 22,
    "Genre": "Basic",
    "Help": "Basic status of the node",
    "ValueIDKey": 369623057,
    "ReadOnly": false,
    "WriteOnly": false,
    "ValueSet": false,
    "ValuePolled": false,
    "ChangeVerified": false,
    "Event": "valueChanged",
    "TimeStamp": 1584037978
}

OpenZWave/1/node/22/instance/1/commandclass/32/value/369623057/

{
    "Label": "Basic",
    "Value": 0,
    "Units": "",
    "Min": 0,
    "Max": 255,
    "Type": "Byte",
    "Instance": 1,
    "CommandClass": "COMMAND_CLASS_BASIC",
    "Index": 0,
    "Node": 22,
    "Genre": "Basic",
    "Help": "Basic status of the node",
    "ValueIDKey": 369623057,
    "ReadOnly": false,
    "WriteOnly": false,
    "ValueSet": false,
    "ValuePolled": false,
    "ChangeVerified": false,
    "Event": "valueChanged",
    "TimeStamp": 1584037995
}

This is a sequence of basic messages indicating a door open followed by a door closed for the entitiy. After this sequence the device still shows as unavailable in HA. This is running 0.106.2 with the latest versions of the zwave_mqtt (via HACS) integration and OZW.

marcelveldt commented 4 years ago

@kevinkahn the zwave_mqtt component is a representation of the mqtt messages served by the ozw daemon. So good chance that this issue needs fixing upstream but we'll need to do some tests to verify.

Please use MQTT explorer to browse your OpenZwave topics. Lookup one of the doorsensor nodes and look at the status.

Schermafbeelding 2020-04-13 om 10 32 41
kevinkahn commented 4 years ago

@marcelveldt This seems to have stopped happening or perhaps given I've stopped investigating the refresh issue I've stopped restarting my OZwave network which has stopped triggering it. I think we should probably close this for now and if I see it return I'll be better prepared to gather forensic info for you. By the way, for some reason I had never tripped over MQTT Explorer - thanks for the pointer. Ever so much easier than just running broad subscription and capturing a log. Also, thanks for prompting on the refresh issue - I think there is more going on there than a simple refresh so I agree that pushing the issue up to the daemon is probably the right answer.