JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 12
  • Score
    100M100P100Q63903F
  • License ISC

XiaoMi air purifier plugins for HomeBridge(https://github.com/nfarina/homebridge).

Package Exports

  • homebridge-mi-airpurifier

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (homebridge-mi-airpurifier) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

homebridge-mi-airpurifier

npm version

XiaoMi air purifier plugins for HomeBridge.
Thanks for nfarina(the author of homebridge), OpenMiHome, aholstenson(the author of miio), licuhui, superszy, all other developer and testers.

Note: I have only a part of these devices, so some devices don't have tested. If you find bugs, please submit them to issues or QQ Group: 107927710.

Supported Devices

1.AirPurifier(小米空气净化器)
2.AirPurifier2(小米空气净化器2)
3.AirPurifierPro(小米空气净化器Pro)

Pre-Requirements

1.Make sure your IOS version is ios11 or later.

Installation

  1. Install HomeBridge, please follow it's README.
    If you are using Raspberry Pi, please read Running-HomeBridge-on-a-Raspberry-Pi.
  2. Make sure you can see HomeBridge in your iOS devices, if not, please go back to step 1.
  3. Install packages.
npm install -g miio homebridge-mi-airpurifier

Configuration

"platforms": [{
    "platform": "MiAirPurifierPlatform",
    "deviceCfgs": [{
        "type": "AirPurifier",
        "ip": "192.168.88.xx",
        "token": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
        "airPurifierDisable": false,
        "airPurifierName": "AirPurifier",
        "silentModeSwitchDisable": false,
        "silentModeSwitchName": "AirPurifier Silent Mode Switch",
        "buzzerSwitchDisable": true,
        "buzzerSwitchName": "AirPurifier Buzzer Switch",
        "ledBulbDisable": true,
        "ledBulbName": "AirPurifier LED Switch",
        "airQualityDisable": false,
        "airQualityName": "AirQuality"
    }, {
        "type": "AirPurifier2",
        "ip": "192.168.88.xx",
        "token": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
        "airPurifierDisable": false,
        "airPurifierName": "AirPurifier",
        "silentModeSwitchDisable": false,
        "silentModeSwitchName": "AirPurifier Silent Mode Switch",
        "temperatureDisable": false,
        "temperatureName": "Temperature",
        "humidityDisable": false,
        "humidityName": "Humidity",
        "buzzerSwitchDisable": true,
        "buzzerSwitchName": "AirPurifier Buzzer Switch",
        "ledBulbDisable": true,
        "ledBulbName": "AirPurifier LED Switch",
        "airQualityDisable": false,
        "airQualityName": "AirQuality"
    }, {
        "type": "AirPurifierPro",
        "ip": "192.168.88.xx",
        "token": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
        "airPurifierDisable": false,
        "airPurifierName": "AirPurifier",
        "silentModeSwitchDisable": false,
        "silentModeSwitchName": "AirPurifier Silent Mode Switch",
        "temperatureDisable": false,
        "temperatureName": "Temperature",
        "humidityDisable": false,
        "humidityName": "Humidity",
        "buzzerSwitchDisable": true,
        "buzzerSwitchName": "AirPurifier Buzzer Switch",
        "ledBulbDisable": true,
        "ledBulbName": "AirPurifier LED Switch",
        "airQualityDisable": false,
        "airQualityName": "AirQuality"
    }]
}]

Get token

Open command prompt or terminal. Run following command:

miio --discover

Wait until you get output similar to this:

Device ID: xxxxxxxx   
Model info: Unknown   
Address: 192.168.88.xx   
Token: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx via auto-token   
Support: Unknown   

"xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" is token.
If token is "???", then reset device and connect device created Wi-Fi hotspot.
Run following command:

miio --discover --sync

Wait until you get output.
For more information about token, please refer to OpenMiHome and miio.

Version Logs

0.0.9

1.fixed bug that "AirPurifierPro" power status display inaccurate.

0.0.8

1.fixed bug that "AirPurifier" can not work.

0.0.7

1.fixed bug that linkage issues between silent mode switch accessory and air purifier accessory.

0.0.6

1.fixed bug that silent mode switch accessory don't display.
2.fixed bug that "AirPurifierPro" led light accessory display brightness.

0.0.5

1.fixed bug that "AirPurifier" and "AirPurifierPro" air purifier accessory don't display.

0.0.4

1.optimized code.

0.0.3

1.fixed bug that air purifier accessory disable when set "silentModeSwitchDisable" value is true.

0.0.2

1.fixed bug that can not startup.
2.add setting silent mode switch disable feature.
3.optimized code.

0.0.1

1.support for XiaoMi AirPurifier.
2.support for XiaoMi AirPurifier2.
3.support for XiaoMi AirPurifierPro.