YinHangCode / homebridge-mi-airpurifier

XiaoMi air purifier plugins for HomeBridge.
114 stars 34 forks source link

Air Purifier Pro not recognized #30

Open thaipirate opened 5 years ago

thaipirate commented 5 years ago

in the device modules, i had to manually add the v7 purifier pro:

'zhimi.airpurifier.v7': AirPurifier,

then it works fine. Thanks for your efforts.

feraljojo commented 5 years ago

Hi Thaipirate, interested by the above tweak as I also have the v7. Are you creating a new device (.js) or adding to a list (which I cannot find yet) ? Thx to help us out there modifying the code as you did. Best of all.

thaipirate commented 5 years ago

hiya i added to models.js which i found in: /usr/lib/node_modules/miio/lib

I scrolled down and there was a commented line that read "// Air Purifier 1 (and Pro?)" with a bunch of entries, and i added v7 to the bottom like this:

// Air Purifier 1 (and Pro?) 'zhimi.airpurifier.v1': AirPurifier, 'zhimi.airpurifier.v2': AirPurifier, 'zhimi.airpurifier.v3': AirPurifier, 'zhimi.airpurifier.v6': AirPurifier, 'zhimi.airpurifier.v7': AirPurifier,

feraljojo commented 5 years ago

Thanks for the feedback. Indeed traced it back to miio. It did not solve it for me yet, so will restart from fresh install and look at it again. Take care.