Xiaomi Robot Vacuum Binding

I’ve added the channels for the AIR PURIFIER 2. (zhimi.airpurifier.m1)
Should be available in market place in about 20 min.
Note, the conversions are not implemented yet, just the raw data

@Andrew_Pawelski
With help of @chrode found issue in the IOS token decryption. Pls update to the latest version from marketplace (available now) to have the binding decode your IOS token.

Hi! Just wanted to let you know, that I updated the binding to the newest version tonight and now it works. Perfect! Thank you so much for your Effort!!!

all added channels work…
some comments…

  • miio:basic:035CAFE2:filterusedhours → in raw data this is seconds currently; it reports the same value for a longer time… and internally seems to be updated in periodic cycles when division by 3600 is ,25 ,5 ,75 or a full decimal…
    however in my case the value matches neither the run time of the device, of the filter or anything… so not sure what it actually is

  • miio:basic:035CAFE2:filtermaxlive → still a little typo here → maxliFe

the most relevant I added quick and dirty:

THANKS !!! :slight_smile:

update to this channel again… it seems to be the RUN TIME of the device itself in seconds…
I was confused before because the iOS version says something different… see below the screenshots of
iOS compared to ANdroid; (iOS needs to fully stop and restart the app to pull the correct value)

→ Run Time vs Working Time
→ air purified (seems to be runtime * 37; ignoring any fan speed setting :wink: )

:smiley::smiley::smiley: haha

sorry … another thing I stumbled over…

miio:basic:035CAFE2:favoritelevel … is that read only? when I set it to a another level in the UI it reads back to level set via the official app in the next periodic cycle

With new version of MiToolkit 1.5, I successfully discovered the vacuum token key. Previous versions are not worked for me.

@marcel_verpaalen: Thanks for your work. Finally I could controll my Xiaomi Vacuum too, next to Air Purifier 2 :slight_smile: Great work!

Great to hear that my tool is helpful. Have done some work with various versions of adb.exe in 1.5 to cover as many different Android devices/versions as possible.

1 Like

Did you my any chance make an English version?

Thank you @ultrara1n :slight_smile:

In version 1.5, you can change the language to English :slight_smile:

1 Like
21:15:39.342 [DEBUG] [inding.miio.handler.MiIoBasicHandler] - Periodic update for 'miio:basic:03197AFA' (miio:basic)
21:15:39.346 [DEBUG] [inding.miio.handler.MiIoBasicHandler] - Building Channel Structure for miio:basic:03197AFA - Model: zhimi.airpurifier.v6
21:15:39.347 [WARN ] [inding.miio.handler.MiIoBasicHandler] - Database entry for model 'zhimi.airpurifier.v6' cannot be found.
21:16:09.347 [DEBUG] [inding.miio.handler.MiIoBasicHandler] - Periodic update for 'miio:basic:03197AFA' (miio:basic)
21:16:09.350 [DEBUG] [inding.miio.handler.MiIoBasicHandler] - Building Channel Structure for miio:basic:03197AFA - Model: zhimi.airpurifier.v6
21:16:09.350 [WARN ] [inding.miio.handler.MiIoBasicHandler] - Database entry for model 'zhimi.airpurifier.v6' cannot be found.

When I click in any miio thing, I got an Error: 404 - NOT FOUND. Any Idea what happen?

@illxi
Please update to the latest version, the database entry for your model should be in.
Your model is not tested yet. Would be great if you can see if all properties refresh for your model and feedback in the topic for the purifiers: Xiaomi Mi Air Purifier (Xiaomi Mi IO)

I am using the latest version. I also own an XiaoMi Purifier 2, the properties did refresh. But for all miio entries, including vacuum and purifiers, I got this Error: 404 thing.

I included the v6 this week and only made it available 2h ago on the market. Did you do the update fter my message and still had the error? If yes, can you send me the log. Otherwise, uninstall and re-install the binding from the marketplace.
Note: The workaround for it would be to enter the model code for your purifier 2 in the model config field of your v6, than it will use the database entries of the purifier 2

The vacuum should be added as miio:generic or as miio:vacuum, not as basic device as that will not work. If you have this error for the vacuum, pls send the debug log, I can see what is going wrong.

Thank you. I didn’t know it was just updated. The latest version worked for v6, and database entry error gone. But I still got the error 404, but I can’t find anything related in the log. I will post a screenshot.

Can it be that your oh version is bit older.
I used to have the same, but after some oh update it went away. I think it had to do with the firmware version feature. (as for me it started when the binding provided the firmware version no.)

Wrt to the first command not working… I indeed have seen that as well. I haven’t investigated it deeply as whatever command is failing, it will be executed in 30s again.

Pls post your logs (or pm) if the properties are not updating. Esp for the v6 I don’t know exactly what properties are supported by the device. If a
Non supported property is requested, the device will respond with a null for that property

Thank you! Problems solved by upgrading to 2.2 snapshot, I was using 2.1.

For V6, buzzer doesn’t work for me

16:21:37.235 [DEBUG] [binding.miio.handler.MiIoBasicHandler] - Property 'buzzer' returned null (is it supported?).

And “OFF” doesn’t work as well. Turning on/off with power works though.

Switch item= AIRPRO_mode label="Modus []" icon="fan" mappings=[auto=Auto, silent=Silent, favorite=Manual, idle=Off]

@illxi
i think the v6 only has the
following modes:
auto,silent,favorite

Or do you see in the app also idle?

Thats aaawesome. Thank your for your job! It is possible to get the informatin about the scanned room? e.g. the image?

Unfortunately that is coming from the cloud. It has multiple layers of encryption that is sofar not well understood.