Flashing custom ROMs to a device is usually somewhat cumbersome. You’ll find yourself in forums where people are releasing their images and you download them from shady file hosting servers and you can never be sure what exactly you are flashing on your device. Incomplete instructions render you sometimes clueless what you should do and hundrets of users ask questions on how to fix stuff and you will have to post “thank you” in forums before you are allowed to see instructions or download tools.
I recently flashed my Xiaomi Mi Pad4 Plus. This is what I have done and it worked great for me. It might not work for you. Disclaimer: you might brick your device. I give no warranty. Don’t trust anyone on the internet.
You will need a Windows computer. The bootloader official tooling from Xiaomi runs not on Mac OS X or Linux.
I went ahead an installed a Windows 10 on Virtual Box.
If you also use a VM and encounter the problem that your Mi Pad is not accessible from within the VM, your user might not be a member of the
vboxusers group. On Ubuntu you can fix this via:
sudo usermod -a -G vboxusers <YOUR USER NAME>.
The change takes only affect after you log out and in again in Ubuntu.
First you will need to unlock the bootloader. Before you can do that, you will have to register the device with your Mi account. In addition you will have to link the device with your Mi account in developer settings and you will have to allow the OEM unlocking in the device settings. If you have not enabled developer settings:
- Go to main Settings on your Xiaomi devices.
- Scroll down to find About phone and tap on it.
- Locate MIUI Version and tap seven times on it.
- You will see a message, that you are a developer now (congrats! It’s that easy to become a developer, you haxxor!)
Enable “OEM unlocking” and “USB debugging” in “Settings -> Additioal Settings -> Developer Options” Log in with your Mi account in “Settings -> Additional settings -> developer Settings -> Mi Unlock Status -> Add account and device”
Xiaomi will let you unlock the bootloader only if you had the device “active” for 2 weeks with your account linked. I used mine not constantly, mostly for Spotify on mi Hi-fi, so don’t worry that you have to use it extensively to make these 2 weeks “active usage” pass.
fastboot tool from Xiaomi and put it on your Windows VM. The application is called “miflash_unlock.exe”. Follow the instructions to unlock your device.
Next we will download a tool “TWRP” that can backup whatever is on your device and can also install custom ROMs from ZIP files.
Go ahead and download the “clover” version, which is according to this forum post the one for “Mi Pad 4 / Mi Pad 4 Plus” (see table). Interestingly enough that the provider of the TWRP tool has a different code name for the Mi Pad. I went with “clover” version.
For simplicity, unzip the contained
.img file into the same folder as the bootloader unlock tool.
Turn off your Mi Pad. After shutdown give it a few seconds (the shutdown sequence is not completed even if the screen is off (??)). Press and hold volume down and power button at the same time until you see a cute bunny. Now your device is in fastboot mode. If you are using a VM: make sure that you enabled the VM to access the USB device.
fastboot flash recovery twrp.img
fastboot boot twrp.img
Now you will see the TWRP tool. I recommend you to create a backup from the system. Just dump it on the internal storage of the Mi Pad and then copy it to your computer (the backup is useless on the internal storage if you brick your device and can’t access it).
Do not unzip this, but just copy it to the internal storage of your Mi Pad.
In TWRP on the Mi Pad, go back and choose
install and then pick the uploaded zip file.
Swipe to install the custom ROM and you will see some progress like this.
This step is optional and only required if you want to have some Google apps (like the Play Store), which are not included in the lineageOS: Before you configure LineageOS, download the open GApps and put it like the custom ROM into the internal storage and install it as well.
Done. That’s it. After that your device will boot with the custom Rom.
blog comments powered by Disqus