Welcome to Mollberg.de

You are here:   Home > Xiaomi Token

Xiaomi Token

I want to explain a fast and easy way how to get the token of a Xiaomi device. My intention was not to root my device.

In my case I wanted to implement my Xiaomi Vacuum Cleaner to FHEM (https://forum.fhem.de/index.php/topic,73052.0.html) and after that, connect it to my Amazon Echo (http://bwssystems.com).

First download an Android emulator e.g. http://www.memuplay.com install and start it.

Now install the old Xiaomi MiHome app: https://www.apkmirror.com/apk/xiaomi-inc/mihome/mihome-4-2-0-release/ (this is important, because the new one has an additional encryption on it)

Now start the already installed App ES File Explorer and activate the root mode (left side, go down to the button)

Browse to /data/data/com.xiamoi.smarthome/databases and copy the file miio2.db to a place outside of root, e.g. /storage/sdcard0/backups/apps

Install e.g. Explorer from Speed Software https://www.apkmirror.com/apk/speed-software/explorer/ because it has an integrated SQLite viewer.

Open it and browse to your miio2db. When you open the file, you will ask what you want to use, please select the viewer.

Open the point devicereord to open the table and move to the right until the column token.

Done, you have the token to implement your device.

 

Login