I bought this used broken unit after covid, not really to solve any air problems but because I found the integrated sensors pretty interesting for the price. The Xiaomi air purifiers operate on a laser particle sensor to measure air quality, combined with a Sensirion SHT temperature/humidity sensor. The data are available over wifi via the smartphone app, which is rather not to my liking – especially hooking up such a reportedly unsafe ([4]) device to my network. That is something I wanted to change, along with fixing the motor. Well, a lot of time has passed, but now it’s actually happening.

I’ll try to add to the others’ knowledge wherever I can. I am currently writing my own custom software for the ESP32 with the aim of integrating the 3H into an MQTT ecosystem, but keeping out overhead like ESPHome or Home Assistant. I’ll push that to Github in the next few days when it’s finished – more to follow here. The code is written for the Espressif IDF toolchain, to be compiled in the Eclipse IDE. It uses standard libraries or openly available ones wherever possible, but also builds on Jaro’s code for the communications part. At a later point I also want to dabble at replacing the STM32 code. I should mention that this post series is not about dumping or modifying any original code or data, or about anything related to the cloud link, since all of that is most likely a waste of time. I’m not going to keep any linkage to the original cloud/app, but for the time being successively replace parts of the functionality – which requires me to figure out how things talk to each other.
Continue reading