Recently I encountered a situation, I flashed TWRP recovery on my redmi 6 pro [Sakura]. After rebooting the device it was getting back to its original recovery due to some rollback features. Fix of this thing was to flash lazy flash zip file but I was unable to flash anything as the internal storage was not mounted in TWRP recovery.
Now at this position, the only solution was to somehow flash the lazy flasher directly from PC but how?
As the PC doesn’t detect your device as MTP when you are in recovery mode(means no file transfer via USB). In this situation, an option is present in TWRP recovery which is called ADB sideload.
What exactly is ADB?
ADB stands for Android development bridge. It is a specific set of drivers through which one can get access to an android phone with USB and can perform various developments. The ADB command is followed by “ADB” e.g. ADB reboot, ADB reboot bootloader.
Table of Contents
What is ADB sideload?
Typically an android phone has three modes
You can transfer and access the files of the android phone via PC in ADB mode only, whereas in Recovery mode you can access the files stored in android device’s storage. But ADB sideload is a feature which is available in custom recoveries especially TWRP which enables you to flash the ZIP files stored in your PC into the android device without copying them into phone’s storage.
This may be very useful to people who accidentally deleted their Rom and now are unable to copy/move anything to android’s storage. With the help of ADB sideload one can flash any zip file directly from PC which was supposed to be flashed from the internal storage of android phone.
How to ADB sideload in TWRP recovery.
To flash a zip file stored on your pc to android phone you will need:
1. ADB drivers installed on PC
2. Fastboot setup on PC
3. USB cable & android phone[ofcourse 🙂 ]
a. Flashing TWRP will void your OEM warranty.
b. If you are not familiar with root processes, don’t mess with your device
c. I am not responsible for Dead SD cards, bricked/dead devices, or if your mobile became crazy after these steps.
Steps to sideload a zip file:
1. Boot into TWRP recovery. (volume up+power button)
2. Connect phone with PC via USB cable
3. In TWRP recovery go to Advance options >ADB sideload.
4. It will show you a message ” enabling ADB sideload feature “.
5. Now open the folder containing ADB setup on your PC and paste the zip file that you want to flash into that folder.
6. Rename the zip file as ROM
7. In the ADB setup folder on empty space press shift key and Right-click simultaneously. It will open a command prompt window.
8. Type ” ADB devices ” and hit enter.
9. If it shows your device with a codename that means your device is connected to PC in ADB mode.
10. Type the command ” ADB sideload ROM .zip” and hit enter.
11. It will begin the installation process and that’s it.
How to copy files to the internal storage of android using ADB sideload in TWRP recovery.
In case you prefer installing zip files from the internal storage of your device then you can try copying files from your PC into internal storage of your device then follow these simple steps.
1. In the command prompt enter the command ” Push Rom.zip /sdcard “
2. After hitting enter the Rom.zip file will be copied to root folder of your SD card
3. Now simply click install button in TWRP recovery and choose the file you want to flash.
4. Swipe right on the screen to confirm the installation.
Above methods can be extremely useful for you if you have bricked your phone and now are unable to access the internal storage of your device.
If you have any queries related to the above article please let us know in the comment section below we will try to respond ASAP.