NorthernMan54 / homebridge-alexa

Expose your homebridge controlled devices to Amazon Alexa.
https://www.homebridge.ca
458 stars 68 forks source link

Thermostat status update fails with error #274

Closed silentcossack closed 4 years ago

silentcossack commented 4 years ago

Hi. I have a thermostat added in homebridge (zwave thermostat in Homeseer, added to homebridge with homeseer plugin), which shows up and works well in HomeKit. It was discovered by Alexa, but when i click on in in Alexa app, alexa homebridge plugin starts spitting out the error bellow (it repeats).

This is running on ubuntu server 16.04 with following:

node v12.13.1 homebridge@0.4.50 homebridge-alexa@0.4.43 homebridge-camera-ffmpeg@0.1.14 homebridge-homeseer-plugin-2018@2.3.25 npm@6.13.1

This is the error with debug on:

alexaLocal Emitting Alexa +3s alexaActions MESSAGE: {"directive":{"header":{"namespace":"Alexa","name":"ReportState","payloadVersion":"3","messageId":"b7e32905-dbe1-4773-9134-51d0001a76d9","correlationToken":"AAAAAAAAAAC6Po/pdYCCCG2N4rcfgxPPDAIAAAAAAAAotnBBAT9iLIegXrq60mLD4KHkdupCQl7Rl3/mUFRlWISKowG8+E0E+80A6t4ZoXMu7sXpgHXQ7cZqgAy9P5A0kOwb+GCYnpxCBJTGZ0Sp8YZ+NHDvuy7UROochTBiXWUY7Fx/v2VeTOWQ+NZtjCfdY4qH04/fMXueYf+efGD+LPQZCF7sDtOUIsNoMVucCRbfKOtzTTS5UZu8WioubnackM5tldMgkEzhLd2x8MPtapw1mZ7vQM3ut31xSwIvSgFe2Oox3Ay/seI3w7PxqWAXpLg/MDws1rJzCZBgsey4rJVK9pGPmLW3UjCJ+5tzIcmaa/pg1w48pwpeez/qQb6EgwwrXivXejO6gyUoql7EGUT0Q2O15InJuWjA0AhbOG8emSespusXfmsvjGRiCMVERWe66KMMQ45PjXm7xsAtxqhZRR1GYJ81wR8+rjW1alU91qAwyMWVaH8e0c0G3HtaLK0KedNyULfO1p+cDl9atzWWnVwRhWTpNA38vPuE3/T1ShFaZjSie20gpnDQOSPMFYSs1WvCY6oC8dwEqdCcDXxLQLAdTAAErxiBxElTslr1vOHB8IWOKvedIea35fQQ3MshdJt/eDlTahf53GKxSDsH1dydcHZJRUeQuRGTRKnq+PFXa8aEU6YG5BbDZ7FHSm07kKGL4cJQ7nkOAK95YaZuzhntxpIW0HRgXg=="},"endpoint":{"endpointId":"Q0Q6MjI6M0Q6RTM6Q0U6MzMtVE5ULUhvbWVicmlkZ2UtSG9tZVNlZXItVGhlcm1vc3RhdC0wMDAwMDA0QS0wMDAwLTEwMDAtODAwMC0wMDI2QkI3NjUyOTE=","cookie":{"ReportState":"[]"}},"payload":{}}} { ReportState: '[]' } +2s alexaActions reportState ReportState undefined undefined undefined Error: getaddrinfo ENOTFOUND undefined at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:60:26) { errno: 'ENOTFOUND', code: 'ENOTFOUND', syscall: 'getaddrinfo', hostname: 'undefined', attempts: 1 } +20ms ERROR: alexaStateResponse getaddrinfo ENOTFOUND undefined

Here is the thermostat related accessory dump entries:

{ "aid": 53, "services": [ { "iid": 1, "type": "0000003E-0000-1000-8000-0026BB765291", "characteristics": [ { "iid": 2, "type": "00000014-0000-1000-8000-0026BB765291", "perms": [ "pw" ], "format": "bool", "description": "Identify" }, { "iid": 3, "type": "00000020-0000-1000-8000-0026BB765291", "perms": [ "pr" ], "format": "string", "value": "HomeSeer", "description": "Manufacturer" }, { "iid": 4, "type": "00000021-0000-1000-8000-0026BB765291", "perms": [ "pr" ], "format": "string", "value": "Z-Wave Temperature", "description": "Model" }, { "iid": 5, "type": "00000023-0000-1000-8000-0026BB765291", "perms": [ "pr" ], "format": "string", "value": "Thermostat", "description": "Name" }, { "iid": 6, "type": "00000030-0000-1000-8000-0026BB765291", "perms": [ "pr" ], "format": "string", "value": "HS Thermostat ref 35", "description": "Serial Number" }, { "iid": 20, "type": "00000052-0000-1000-8000-0026BB765291", "perms": [ "pr" ], "format": "string", "value": "1.0", "description": "Firmware Revision" } ], "primary": false, "hidden": false }, { "iid": 7, "type": "0000004A-0000-1000-8000-0026BB765291", "characteristics": [ { "iid": 8, "type": "0000000F-0000-1000-8000-0026BB765291", "perms": [ "pr", "ev" ], "format": "uint8", "value": 1, "description": "Characteristic.CurrentHeatingCoolingState", "valid-values": [ 0, 1, 2 ], "maxValue": 2, "minValue": 0 }, { "iid": 9, "type": "00000033-0000-1000-8000-0026BB765291", "perms": [ "pr", "pw", "ev" ], "format": "uint8", "value": 1, "description": "Characteristic.TargetHeatingCoolingState", "valid-values": [ 0, 1, 2, 3 ], "maxValue": 3, "minValue": 0 }, { "iid": 10, "type": "00000011-0000-1000-8000-0026BB765291", "perms": [ "pr", "ev" ], "format": "float", "value": 20.8, "description": "Characteristic.CurrentTemperature", "unit": "celsius", "maxValue": 75, "minValue": -50, "minStep": 0.1 }, { "iid": 11, "type": "00000035-0000-1000-8000-0026BB765291", "perms": [ "pr", "pw", "ev" ], "format": "float", "value": 21.1, "description": "Characteristic.TargetTemperature", "unit": "celsius", "maxValue": 35, "minValue": 0, "minStep": 0.1 }, { "iid": 12, "type": "00000036-0000-1000-8000-0026BB765291", "perms": [ "pr", "pw", "ev" ], "format": "uint8", "value": 0, "description": "Temperature Display Units", "valid-values": [ 0, 1 ], "maxValue": 1, "minValue": 0 }, { "iid": 18, "type": "0000000D-0000-1000-8000-0026BB765291", "perms": [ "pr", "pw", "ev" ], "format": "float", "value": 10, "description": "Characteristic.CoolingThresholdTemperature", "unit": "celsius", "maxValue": 35, "minValue": 0, "minStep": 0.1 }, { "iid": 19, "type": "00000012-0000-1000-8000-0026BB765291", "perms": [ "pr", "pw", "ev" ], "format": "float", "value": 0, "description": "Characteristic.HeatingThresholdTemperature", "unit": "celsius", "maxValue": 35, "minValue": 0, "minStep": 0.1 } ], "primary": false, "hidden": false } ] }

Any help would be greatly appreciated. Thanks.

NorthernMan54 commented 4 years ago

Ask Alexa to discovery devices, then try again

If that fails, please share a homebridge accessory dump

Sent from my iPad

On Dec 2, 2019, at 10:24 PM, silentcossack notifications@github.com wrote:

 Hi. I have a thermostat added in homebridge (zwave thermostat in Homeseer, added to homebridge with homeseer plugin), which shows up and works well in HomeKit. It was discovered by Alexa, but when i click on in in Alexa app, alexa homebridge plugin starts spitting out the error bellow (it repeats).

This is running on ubuntu server 16.04 with following:

node v12.13.1 homebridge@0.4.50 homebridge-alexa@0.4.43 homebridge-camera-ffmpeg@0.1.14 homebridge-homeseer-plugin-2018@2.3.25 npm@6.13.1

This is the error with debug on:

alexaLocal Emitting Alexa +3s alexaActions MESSAGE: {"directive":{"header":{"namespace":"Alexa","name":"ReportState","payloadVersion":"3","messageId":"b7e32905-dbe1-4773-9134-51d0001a76d9","correlationToken":"AAAAAAAAAAC6Po/pdYCCCG2N4rcfgxPPDAIAAAAAAAAotnBBAT9iLIegXrq60mLD4KHkdupCQl7Rl3/mUFRlWISKowG8+E0E+80A6t4ZoXMu7sXpgHXQ7cZqgAy9P5A0kOwb+GCYnpxCBJTGZ0Sp8YZ+NHDvuy7UROochTBiXWUY7Fx/v2VeTOWQ+NZtjCfdY4qH04/fMXueYf+efGD+LPQZCF7sDtOUIsNoMVucCRbfKOtzTTS5UZu8WioubnackM5tldMgkEzhLd2x8MPtapw1mZ7vQM3ut31xSwIvSgFe2Oox3Ay/seI3w7PxqWAXpLg/MDws1rJzCZBgsey4rJVK9pGPmLW3UjCJ+5tzIcmaa/pg1w48pwpeez/qQb6EgwwrXivXejO6gyUoql7EGUT0Q2O15InJuWjA0AhbOG8emSespusXfmsvjGRiCMVERWe66KMMQ45PjXm7xsAtxqhZRR1GYJ81wR8+rjW1alU91qAwyMWVaH8e0c0G3HtaLK0KedNyULfO1p+cDl9atzWWnVwRhWTpNA38vPuE3/T1ShFaZjSie20gpnDQOSPMFYSs1WvCY6oC8dwEqdCcDXxLQLAdTAAErxiBxElTslr1vOHB8IWOKvedIea35fQQ3MshdJt/eDlTahf53GKxSDsH1dydcHZJRUeQuRGTRKnq+PFXa8aEU6YG5BbDZ7FHSm07kKGL4cJQ7nkOAK95YaZuzhntxpIW0HRgXg=="},"endpoint":{"endpointId":"Q0Q6MjI6M0Q6RTM6Q0U6MzMtVE5ULUhvbWVicmlkZ2UtSG9tZVNlZXItVGhlcm1vc3RhdC0wMDAwMDA0QS0wMDAwLTEwMDAtODAwMC0wMDI2QkI3NjUyOTE=","cookie":{"ReportState":"[]"}},"payload":{}}} { ReportState: '[]' } +2s alexaActions reportState ReportState undefined undefined undefined Error: getaddrinfo ENOTFOUND undefined at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:60:26) { errno: 'ENOTFOUND', code: 'ENOTFOUND', syscall: 'getaddrinfo', hostname: 'undefined', attempts: 1 } +20ms ERROR: alexaStateResponse getaddrinfo ENOTFOUND undefined

Any help would be greatly appreciated. Thanks.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe.

silentcossack commented 4 years ago

Thanks for replying. I deleted the thermostat from Alexa and discovered devices again (from Alexa app on iPhone - let me know if this needs to be done with voice echo dot or something). Same thing, thermostat is discovered but when i click on it, says unresponsive an error above is repeated. I added accessory dump last night, see first post - i only pasted the thermostat entries, let me know if you need the entire dump.

NorthernMan54 commented 4 years ago

I need the whole dump, as I use the parser to generate the alexa discovery response and want to see what it says

silentcossack commented 4 years ago

Here you go, attached. (removed)

NorthernMan54 commented 4 years ago

After running that thru the parser, the issue is with the description field in the thermostat accessory. The description field does not match a normal homebridge thermostat

Let me think a bit about how to resolve this

    }, {
      "iid": 7,
      "type": "0000004A-0000-1000-8000-0026BB765291",
      "characteristics": [{
        "iid": 8,
        "type": "0000000F-0000-1000-8000-0026BB765291",
        "perms": ["pr", "ev"],
        "format": "uint8",
        "value": 1,
        "description": "Characteristic.CurrentHeatingCoolingState",
        "valid-values": [0, 1, 2],
        "maxValue": 2,
        "minValue": 0
      }, {
        "iid": 9,
        "type": "00000033-0000-1000-8000-0026BB765291",
        "perms": ["pr", "pw", "ev"],
        "format": "uint8",
        "value": 1,
        "description": "Characteristic.TargetHeatingCoolingState",
        "valid-values": [0, 1, 2, 3],
        "maxValue": 3,
        "minValue": 0
      }, {
        "iid": 10,
        "type": "00000011-0000-1000-8000-0026BB765291",
        "perms": ["pr", "ev"],
        "format": "float",
        "value": 20.8,
        "description": "Characteristic.CurrentTemperature",
        "unit": "celsius",
        "maxValue": 75,
        "minValue": -50,
        "minStep": 0.1
      }, {
        "iid": 11,
        "type": "00000035-0000-1000-8000-0026BB765291",
        "perms": ["pr", "pw", "ev"],
        "format": "float",
        "value": 21.1,
        "description": "Characteristic.TargetTemperature",
        "unit": "celsius",
        "maxValue": 35,
        "minValue": 0,
        "minStep": 0.1
      }, {
        "iid": 12,
        "type": "00000036-0000-1000-8000-0026BB765291",
        "perms": ["pr", "pw", "ev"],
        "format": "uint8",
        "value": 0,
        "description": "Temperature Display Units",
        "valid-values": [0, 1],
        "maxValue": 1,
        "minValue": 0
      }, {
        "iid": 18,
        "type": "0000000D-0000-1000-8000-0026BB765291",
        "perms": ["pr", "pw", "ev"],
        "format": "float",
        "value": 10,
        "description": "Characteristic.CoolingThresholdTemperature",
        "unit": "celsius",
        "maxValue": 35,
        "minValue": 0,
        "minStep": 0.1
      }, {
        "iid": 19,
        "type": "00000012-0000-1000-8000-0026BB765291",
        "perms": ["pr", "pw", "ev"],
        "format": "float",
        "value": 0,
        "description": "Characteristic.HeatingThresholdTemperature",
        "unit": "celsius",
        "maxValue": 35,
        "minValue": 0,
        "minStep": 0.1
      }],
NorthernMan54 commented 4 years ago

@silentcossack after discussing with the home seer plugin dev he made a change that should resolve this. If you could update the homeseer plugin, and discover devices you should be good.

Alternatively he suggested to update to his improved homeseer plugin, homebridge-homeseer4

@jvmahon thanks for resolving this, much appreciated

silentcossack commented 4 years ago

@NorthernMan54 thank you so much for following up on this. I really appreciate the attention to this issue and the follow up with @jvmahon. I have since moved to a new thermostat, ecobee and don't have my zwave one anymore. So I will not be able to confirm this fix. I'm also in the process of moving all my home automation to openHAB, and won't be using the homeseer plugin. Really sucks that I can't confirm the fix, but i'm sure others will appreciate having this resolved. Thanks again!

NorthernMan54 commented 4 years ago

Tks for the update