roobbb / mipurifier-esphome

ESPHome for the Xiaomi Mi Air Purifier 3H (and similar devices using the same protocol)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ESPHome for various Xiaomi Air Purification Devices

There are two separate microcontrollers inside the device: one STM32F4 which actually controls the device, and one ESP32 which only acts as a gateway to the internet/local network. This config replaces the firmware running on the ESP32 and implements the proprietary serial protocol used to communicate with the STM32.

Features:

  • turning the purifier on/off
  • exposing PM2.5, humidity, temperature, and remaining filter life as sensor values
  • switching modes
  • controlling speed in manual mode
  • changing various settings (display brightness, beeper, lock)
  • sending custom commands using the esphome.mipurifier_send_command service (e.g. sending down set_properties 5 1 false disables beeping)

FAQ

Does this remove the Filter remaining 0% warning?

Flashing this firmware does NOT change anything about how the remaining filter life is read/managed. However you can easily reset your filter to continue using it by following this video for example.

Is my air purifier supported?

The following devices are known to work with this library (this list is not exhaustive)

  • Air Purifier 3 (2019) (zhimi.airpurifier.ma4)
  • Air Purifier 3H (2019) (zhimi.airpurifier.mb3)

Please don't hesitate to expand this list by opening a pull request if your device also works with this library! Make sure to backup the original firmware on your device's ESP32 before flashing ESPHome.

Flashing

Connect any USB-to-serial adapter and power on the ESP32 while GPIO0 and GPIO2 are pulled low.

About

ESPHome for the Xiaomi Mi Air Purifier 3H (and similar devices using the same protocol)

License:The Unlicense


Languages

Language:C++ 100.0%