nicholasrobinson / homebridge-smartcielo

Smartcielo (MRCOOL) plug-in for [Homebridge](https://github.com/nfarina/homebridge) using the smartcielo API.
MIT License
14 stars 6 forks source link

TypeError: Cannot read properties of undefined #16

Closed dVIAN13 closed 1 year ago

dVIAN13 commented 2 years ago

@nicholasrobinson, glad you're still around! I'm thinking some of the API calls have been modified recently. I have a MRCOOL DIY unit and prior to the below error, I was never able to make changes to the unit. It would read the temperature correctly from the API, but any attempt to make changes from within HK(Home App / HomeBridge), the request would fail, followed by the unit turning off.

[1/1/2022, 12:26:19 PM] [MiniSplit] TypeError: Cannot read properties of undefined (reading 'listDevices') at /usr/lib/node_modules/homebridge-smartcielo/node_modules/node-smartcielo/SmartCielo.js:240:56 at processTicksAndRejections (node:internal/process/task_queues:96:5)

This error(warning) also comes up often:

`[1/1/2022, 12:33:31 PM] [homebridge-smartcielo] This plugin slows down Homebridge. The read handler for the characteristic 'Current Heating Cooling State' didn't respond at all!. Please check that you properly call the callback! See https://git.io/JtMGR for more info.` 
aotearoacoder commented 2 years ago

Hi all, thanks for the work here! ... I am getting this same error on startup of the plugin:

[Cottage] TypeError: Cannot read properties of undefined (reading 'listDevices')
    at /Users/davem/.nvm/versions/node/v16.13.2/lib/node_modules/homebridge-smartcielo/node_modules/node-smartcielo/SmartCielo.js:240:56

Any help would be appreciated

nullfx commented 2 years ago

same. installed one of these AC's about 6 months ago, have been seeing this issue since then (keep checking back to see if any updates have been made, looks like this is a dead plug in)

aotearoacoder commented 2 years ago

The problem is in the underlying api connect package …

https://github.com/nicholasrobinson/node-smartcielo/blob/61963c3689ca7c5d2f7b1e20ed895220b2bebb2b/SmartCielo.js#L240

I plan on taking a look + seeing how hard it would be to allow multiple devices (I have a multi-zone Mr Cool, so would need that also).

I would like to hear if any others have attempted fixing or attempted the multi-device step.

nm2124 commented 1 year ago

The problem is in the underlying api connect package …

https://github.com/nicholasrobinson/node-smartcielo/blob/61963c3689ca7c5d2f7b1e20ed895220b2bebb2b/SmartCielo.js#L240

I plan on taking a look + seeing how hard it would be to allow multiple devices (I have a multi-zone Mr Cool, so would need that also).

I would like to hear if any others have attempted fixing or attempted the multi-device step.

Any luck here?

isaac-webb commented 1 year ago

Hey all, Installed a couple of these units in my house this summer and wanted HomeKit as well. Finally got a few days this week to dig into this problem. I took both of @nicholasrobinson's packages, updated them as best I could, and republished them. node-mrcool is the re-implemented library, and homebridge-mrcool is the homebridge plugin. It seems to be working alright, but they are v1 packages, so probably some issues I haven't found. Please feel free to install and let me know how it works (and any bugs you find...!). In particular, I've only got the single zone 3rd gen units, so I'd be appreciative of input on multi-zone units @aotearoacoder.

nullfx commented 1 year ago

finally... thank you for the fix / update!!! i also only have the single zone though so unfortunately not any help on testing the multi-zone units.

nicholasrobinson commented 1 year ago

Closing per https://github.com/nicholasrobinson/homebridge-smartcielo/issues/22