Team Win strives to provide a quality product. However, it is your decision to install our software on your device. Team Win takes no responsibility for any damage that may occur from installing or using TWRP.
Support Status: Current
Code Name: lithium
Some Xiaomi Mi devices have bootloaders that require additional steps to unlock before you are able to flash custom images. This typically involves using MI Unlock Tool to apply & wait for certain time period to have your device unlocked.
You will need to follow the steps on Xiaomi's MIUI website in order to unlock your device.
Understand that unlocking your device will wipe all of your personal data, settings, and apps from its memory.
This means that swiping to allow system modifications will prevent you from being able to boot if you are using the stock kernel. In order to bypass dm-verity's boot prevention, you will have to install a kernel that has dm-verity disabled in the fstab.
Download the Official TWRP App (root required):
Install the app and open it. Agree to the Terms. Select TWRP Flash. Select your device from the device list (lithium) and choose a version. The file will download to your Downloads folder. Browse to and select the file. Tap on Flash to Recovery. Find out more about the app here.
Current and past versions of TWRP can be found at one of the mirrors below:
Download the latest TWRP image file (.img) from the download link and boot TWRP. Go to install and find and select the Images... button. Browse to the image that you downloaded and select it. Choose recovery and swipe to flash.
You will need the platform-tools from the Android SDK on your computer. Download the platform-tools as per your operating system.
Windows users will need proper drivers installed on their computer. You can try the simple FWUL adb/fastboot ISO or the Naked ADB drivers or the Universal ADB drivers if you don't already have a working driver installed
On your device, go into Settings -> About and find the Build Number and tap on it 7 times to enable developer settings. Press back and go into Developer Options and enable USB debugging. From your computer, open a command prompt and type:
adb reboot bootloader
You should now be in fastboot mode.
Download the correct image file and copy the file into the same folder as your platform-tools. Rename the image to twrp.img and type:
fastboot flash recovery twrp.img
Note many devices will replace your custom recovery automatically during first boot. To prevent this, use Google to find the proper key combo to enter recovery. After typing fastboot reboot, hold the key combo and boot to TWRP. Once TWRP is booted, TWRP will patch the stock ROM to prevent the stock ROM from replacing TWRP. If you don't follow this step, you will have to repeat the install.
Download the latest image file (.img) from the download link above. Place it in the root of your /sdcard folder and rename it to twrp.img. Run the following commands via adb shell or a terminal emulator app:
dd if=/sdcard/twrp.img of=/dev/block/platform/soc/624000.ufshc/by-name/recovery
lithium: Update to O-mr1 based kernel * The main motivation is to bring the latest F2FS updates as well as support for quota feature. * ft8716 firmware update disabled by setting CONFIG_TOUCHSCREEN_FT8716_DISABLE_FW_UPDATE=y * Source: https://github.com/LineageOS/android_kernel_xiaomi_msm8996/tree/42a64be1431033426c593c50f83a7c5586dcfcc8 Change-Id: I96641c8011d9d8385fcabbc4a6ae74162a9b3e00
lithium: Add support for a pseudo-vendor partition * Turn the partition used by Xiaomi to ship MIUI regional customizations into something more useful for us. Change-Id: Idef90127d7142d4f038d558b3281c9fe628a9d9f
- Luca Stefani
lithium: Add max brightness flag
- Bruno Martins
lithium: Blacklist hbtp input device * This removes the annoying mouse cursor that was appearing at the middle of the screen (alternative to disablement in kernel config, which is currently impossible) Change-Id: I1a487b645dc74b04e845840068ed27fa02449a2d
lithium: Rename and adapt for lithium