[Release] ADP1 1.1 (official) - G1 Android Development

It's about time! This is not the holiday update - this is ADP1's real RC9/RC33!
http://android-developers.blogspot.com/2009/03/software-update-available-for-android.html
Download at HTC: http://www.htc.com/www/support/android/adp.html
Back in December, the Android Dev Phone 1 (ADP1) went on sale, giving developers access to unlocked hardware for their work. A few weeks ago, consumers with retail devices received an over the air update with the 1.1 release of Android. I know that many developers will be pleased to hear that today, our colleagues at HTC have released a 1.1 version of Android for the Android Dev Phone which you can install on your device. If you have questions about the process of updating your device, you can ask the mailing list we've set up for such questions.
This new system image is fully compatible with Android 1.1. To see a list of everything that's new, you can review the notes from the 1.1_r1 SDK. This update also includes support for searching by voice, and priced apps in the Android Market.
Some developers have asked about the support for copy-protected apps on developer devices, and indeed there is a limitation you should be aware of. Many developers are concerned about the unauthorized redistribution of their applications, so they make use of the copy-protection feature (known as "forward locking") which prevents applications from being copied off devices. However, developer phones like the ADP1 allow for unrestricted access to the device's contents, making it impossible to enforce copy protection. As a result, the Market application on such devices is not able to access copy protected apps, whether they are free or paid. If you choose to add copy protection when you upload your application to the Android Market, then you won't be able to test it on the ADP1's Android Market client. Your application will always be accessible to users who have standard configurations though, and if your application (whether it is free or paid) is not copy-protected it will appear on all devices, including developer configurations.
If you own an Android Developer Phone, I definitely suggest you take advantage of this update. There's lots of good stuff in there, and the new software is backward compatible with Android 1.0, too. The original 1.0 system image is also now available, you need to downgrade for any reason. Happy coding!

how is this different to the ADP1.1h that we already have thanks to JF?

I was wondering that too. I see new one is supposed to have voice search for example, but we alread have that in 1.1h. I guess 1.1h is some kind of "halfway there" image.

The new release supports paid applications.
http://blogs.zdnet.com/Burnette/?p=848

aoi0123 said:
The new release supports paid applications.
http://blogs.zdnet.com/Burnette/?p=848
Click to expand...
Click to collapse
The current adp1.1h supports paid apps.

You beat me to it

I'd really like to see a JF version of this (pretty please JF ) because it's "newer" and way more "official" than the leaked Holiday update.
Oh, and this does not work with DRM apps - and Google simply explains why in their post about this new update. Those other websites clearly misinterpreted it, and didn't read carefully (Google is essentially sugarcoating the situation). Any way to get around it? Maybe install RC33 Market binary? I'd really like to get my hands on some nice games, and stop playing my Stop At 500 game hundreds of times over and over again.

Someone mentioned in an earlier thread that installing rc33 then adp1.1 without a wipe allowed them to see all apps. We may just need the odex file, who knows...

Will they offer new dev images for the new carrier based devices running 2.3?
Flashing your Android Dev Phone with a Factory System Image
This page provides instructions on how you can flash your Android Dev Phone with a factory Android platform system image and associated radio image. From here, you can also download the actual image binaries, as well as relevant tools to help you flash the images to your device.
With these system image files, you can:
Keep your Dev Phone up to date with the latest Android system images
Test your application on multiple Android platform versions, to ensure compatibility
Restore a corrupted device to a factory state.
Overview
The sections below describe two alternative methods that you use to flash your device with a factory Android system image:
Flashing the device using an updated recovery image (recovery-image method)
This approach involves using the adb tool, available in the Android SDK, to copy updated radio and recovery images to the device's recovery partition on the SD card. It's a straightforward operation that you can run in a Windows, OS X, or Linux environment. If you are an Android application developer, this method of flashing your device is recommended. Note that to use this method, the device must have the original factory bootloader that came with the device (hboot 0.95.3000).
Flashing the device using fastboot commands (fastboot method)
This approach is slightly more complicated and involves using the adb tool to update the radio image and the fastboot tool to flash a system image to the device. Flashing your device in this way is useful if you need to install the radio and system images independently or you are already familiar with fastboot and are using it successfully in your environment. To use this method, your device must have a fastboot-compatible bootloader. Having the original factory bootloader included on ADP devices is not required.
Before you get started, decide which of these two methods is appropriate for you, then follow the instructions below, in the order given. The flashing process for both methods is similar ??the main difference is that the recovery-image method does not require the fastboot tool. Rather than using fastboot to flash a system image to the device, you use adb to copy an updated recovery image to the device. All other steps are the same.
Supported Devices
The system images provided on this page are designed only for installation on devices that meet the following requirements:
HTC Dream hardware platform only
Device must have the original factory bootloader (hboot 0.95.3000) or a development bootloader that supports fastboot
You cannot flash these system images to other hardware platforms or to a version of HTC Dream hardware that doesn't have an original factory bootloader, unless the device bootloader supports fastboot (fastboot is described in the next section). Additionally, you cannot flash these images to a retail devices such as the T-Mobile G1 because the images do not have the appropriate cryptographic signatures.
Get the Tools
To flash a system image to your device, you need to have access to the proper tools.
If you are flashing your device using the recovery-image method, you need the adb tool, included in the Android SDK.
If you are flashing your device using the fastboot method, you need the fastboot tool, in addition to the adb tool.
For either method, if you are working in a Windows development environment, you should update your USB driver to the version provided in the Android SDK.
Adb Tool
The adb tool is included in the Android SDK. If you have already installed the Android SDK on your local machine, you will find adb in the <sdk>/tools/ directory.
If you do not have the Android SDK, download the latest version from this location and install it:
http://developer.android.com/sdk/index.html
Once you install the SDK, the adb tool will be available to you.
Fastboot Tool
If you are flashing your device using the fastboot method, you need the command-line tool called fastboot.
The fastboot source code is available in the Android open source repository and is compiled whenever you build from that tree. If you've built from the Android open source tree, you will find the fastboot executable in this location:
<build-dir>/out/host/<platform>/bin/
For your convenience, you can also download the fastboot executable directly, using the links below.
Platform Download Size (bytes) Checksum
Fastboot binary, Windows fastboot.exe 992202 6bbf05d97585c3c515bdb172eb9e7d12
Fastboot binary, OS X
(Unzip the file before executing) fastboot-mac 59071 ed784e50cfcaba3c60380c5f448aa354
Fastboot binary, Linux
(Unzip the file before executing) fastboot 61887 9851bb6ad29cd4b60c9ba9d011ba9efd
On OS X and Linux, you can store the fastboot executable anywhere on your machine. On Windows, you must store the fastboot executable where it can find the AdbWinApi.dll file (included with the Android SDK), otherwise it will not work properly. The recommended place to store the fastboot executable on Windows is with the other tools in the Android SDK, in the <sdk>/tools directory. On all platforms, you may want to add the location to your PATH, for convenience.
USB Driver
If your development machine is running Windows, you should make sure to update your USB driver before continuing. For your convenience, the Android SDK (1.0 r2 or later) includes an updated USB driver that you can install. For more information, see Setting up a Device for Development on the Android Developers Site.
Download the Image Packages
To flash a new system image to your device, you need to download two image packages to your local machine.
If you are flashing your device using the recovery-image method, you need to download a recovery image package and a radio image package only.
If you are flashing your device using the fastboot method, you need to download a system image package and a radio image package only.
The table below provides links to the downloadable image packages. The sections provide more information about the contents of each package and how you should handle it after download.
Version Image Download Size (bytes) Checksum
Android 1.6 Radio Image ota-radio-2_22_19_26I.zip 9181622 aeecdb49b74a0d4bb67f9d8af70c1889
System Image signed-dream_devphone_userdebug-img-14721.zip 40118457 a06a3d24ff4cbe5c81317e41891e6965
Recovery Image signed-dream_devphone_userdebug-ota-14721.zip 47202626 b3e12b004c155761a10b1a848288e0c3
Android 1.5 Radio Image ota-radio-2_22_19_26I.zip 9181622 aeecdb49b74a0d4bb67f9d8af70c1889
System Image signed-dream_devphone_userdebug-img-150275.zip 38027127
5ca85a135ff1ddd41643237577cb8ec4
Recovery Image signed-dream_devphone_userdebug-ota-150275.zip 46907411 01c19785eef97b06409f52fed568feff
Android 1.1 Radio Image ota-radio-1_22_14_11.zip 9131603 5520b3386707b570afc0e593aa854586
System Image signed-dream_devphone-img-142608.zip
(Same as img-130444, except with Voice Dialing enabled.)
36845408 5278ae25c10946cb12f449ac1edc5923
signed-dream_devphone-img-130444.zip 36794552 b74cee3f66f673bd09954bf990985ec2
Recovery Image signed-dream_devphone-ota-142608-b.zip
(Replaces 142608. Adds support for downgrade. See troubleshooting note)
45680454 c3436df93e4cbdd946868d6badafddb0
Android 1.0 Radio Image ota-radio-1_22_12_29.zip 9128783 66853a7ffbb14f291d9fa446494ca420
System Image signed-dream_devphone-img-116222.zip 35840707 3a9c88935d8772405b6094b68f449095
Radio Image Download
For both methods of flashing your device, you need to download a radio image package from the list of links in the table above.
Each Android platform version is designed to run on top of a specifc version of the radio firmware. Typically, each successive release of the Android platform relies on a newer version of the radio firmware, so whenever you are planning to flash a new system image to your device, whether upgrade or downgrade, you should also update the radio firmware to the version expected by the platform. If you do not update your radio image, the system may encounter problems.
Use the links provided in the previous section to download the radio image package that corresponds to the system image you downloaded.
Once you've downloaded a radio image package, you do not need to extract it - you can reference the image package directly from adb commands, as described in the sections below. You can store the radio image package anywhere on your machine, but make sure to store to maintain its version-specific naming.
System Image Download
If you are flashing your device using the fastboot method, download the signed system image package(s) that you need from the list of links in the table above. Multiple versions of the Android platform are available, so make sure that you understand what version(s) you need and what version(s) you are downloading.
For development, you should select the lowest possible Android platform version that meets the needs of your applications. For example, if you are working in the Android 1.1 SDK and your application is using APIs introduced in Android 1.1, then you should download the Android 1.1 system image. If you are using the Android 1.1 SDK but your application does not use Android 1.1 APIs, then using Android 1.0 image is sufficient.
For testing, consider downloading all platform versions with which your application is compatible, then running your applications on those platform versions to ensure that they work as designed.
Each system image package is a .zip archive that includes several images that you will flash to your device:
A boot image - contains the kernel and initrd.
A recovery image - contains files used for rebuilding/updating the system.
A system image - contains the Android platform/apps of the specified version.
Note that the images in each package are mutually dependent, so you must flash them all to your device together. For example, you should not flash a system image to the device without also flashing the boot and recovery images included in the same image package.
Once you've downloaded a system image package, you do not need to extract it ??you can reference the image package directly from fastboot commands, as described in the sections below. You can store the system image package anywhere on your machine, but make sure to store to maintain its version-specific naming.
Recovery Image Download
If you are flashing your device using the recovery-image method, download the recovery image package(s) that you need from the list of links in the table above. Currently, a recovery image packages is available only for the Android 1.1 platform version.
Each recovery image package is a .zip archive containing the full contents of a recovery partition, including:
A boot image - contains the kernel and initrd.
A recovery image - contains files used for rebuilding/updating the system.
A system image - contains the Android platform/apps of the specified version.
A radio image - contains the compatible radio firmware.
Note that the images in each recovery package are mutually dependent, so you must copy them all to your device together. For example, you should not copy a system image to the device without also copying the boot and recovery images included in the same image package.
Once you've downloaded a recovery image package, you do not need to extract it - you can reference the image package directly from adb commands, as described in the sections below. You can store the recovery image package anywhere on your machine, but make sure to store to maintain its version-specific naming.
Update the Device Radio Firmware
For both the recovery-image and fastboot methods, you need to update the radio firmware on the device before you go on to update the system. This step is necessary both to ensure that a compatible radio image exists on the device and to satisfy version prerequisites enforced by the bootloader when loading the updated recovery image.
After you've installed the tools and downloaded a system/recovery image package and corresponding radio image package, follow the steps below to update the radio firmware on the device.
Ensure that a SD card is inserted in the device
Boot the device normally
Connect the device to your development machine over USB.
At a command line, ensure that adb recognizes your device by issuing this command:
$ adb devices
You should see your device in the console output generated by the command
Use the adb push command to copy the contents of the radio image package to the update.zip archive on the device's SD card:
$ adb push <radio-image-package>.zip /sdcard/update.zip
The command prints the number of bytes copied and the elapsed time, then completes. However, note that the files are still being copied in the background, so wait a minute or two before continuing. If you continue too soon and terminate the operation before it is complete, you will get a "bad update.zip" error later, when you try to install the update.
To ensure that the entire radio image package is copied before you continue, use this command:
$ adb shell sync
When sync returns, all of the data has been copied to the device.
Reboot the device into recovery mode by holding down the HOME key during reboot. When the device enters recovery mode, it displays a "!" icon.
With the recovery console displayed, open the sliding keyboard and hold down the ALT+l key combination to enable log output in the recovery console.
Next, hold down the ALT+s key combination to install the update. An "installing update" icon and progress bar (or a similar status message) are displayed ??when the progress bar completes, the installation is finished.
Press the HOME-BACK key combination to write the radio image, update the firmware, and automatically reboot. Note that if you do not use HOME-BACK at this point, the device will not load the updated radio image. After writing the radio image, the device shows a "updating firmware" icon for a few seconds and then automatically reboots in normal mode.
After the device reboots normally, you can update the system image or recovery image, as described in the next sections. To check the radio image version, you can start the device in fastboot mode.
Copy the Recovery Image Package to the Device
For the recovery-image method only, after you've successfully updated the radio firmware, the next (and final) step is using the adb tool to copy the recovery image package to the device SD card. (If you are using the fastboot method, you do not need to copy a recovery image to the device - see Flash the System Image Package to the Device instead.)
To copy the recovery image to the device SD card, follow these steps:
Ensure that the SD card containing the updated radio image is inserted in the device
Boot the device normally
Connect the device to your development machine over USB.
At a command line, ensure that adb recognizes your device by issuing this command:
$ adb devices
You should see your device in the console output generated by the command
Use the adb sync command to copy the contents of the radio image package to the update.zip archive on the device's SD card:
$ adb push <recovery-image-package>.zip /sdcard/update.zip
The command prints the number of bytes copied and the elapsed time, then completes. However, note that the files are still being copied in the background, so wait a minute or two before continuing. If you continue too soon and terminate the operation before it is complete, you will get a "bad update.zip" error later, when you try to install the update.
To ensure that the entire recovery image package is copied before you continue, use this command:
$ adb shell sync
When sync returns, all of the data has been copied to the device.
Reboot the device into recovery mode by holding down the HOME key during reboot. When the device enters recovery mode, it displays a "!" icon.
With the recovery console displayed, open the sliding keyboard and hold down the ALT+l key combination to enable log output in the recovery console.
Next, hold down the ALT+s key combination to install the update. An "installing update" icon and progress bar (or a similar status message) are displayed ??when the progress bar completes, the installation is finished.
Press the HOME-BACK key combination to write the recovery image, update the firmware, and automatically reboot. Note that if you do not use HOME-BACK at this point, the device will not load the updated radio image. After writing the image, the device shows a "updating firmware" icon for a few seconds and then automatically reboots in normal mode.
After the device reboots normally, the operation is complete.
For discussions and support about updating your Android Dev Phone, please head over to the Android-DevPhone-Updating group.
Flash the System Image Package to the Device
For the fastboot method only, after you've successfully updated the radio firmware, the next (and final) step is using the fastboot tool to flash the system image package to the device. Note that you should always update the radio image whenever you update the Android system image on your device. (If you are using the recovery-image method, you do not need to flash the system image package to the device - see Copy the Recovery Image Package to the Device instead.)
Follow the steps below to flash a system image package to your device:
Boot the device in fastboot mode.
To enter fastboot mode, power up the device (or reboot it) while holding down the BACK key. Hold the BACK key down until the bootloader screen is visible and shows "FASTBOOT". The device is now in fastboot mode and is ready to receive fastboot commands. If you want to exit fastboot mode at this point, you can hold down the keys MENU+SEND+END (on the Android Dev Phone, SEND is the "Call" key and END is the "End call" key).
Note that the bootloader screen may vary across devices. For Android Dev Phone devices, the bootloader screen shows an image of skateboarding robots. Other devices may show a different image or color pattern. In all cases, the bootloader screen shows the text "FASTBOOT" when in fastboot mode. The bootloader also shows the radio version.
Connect the device to your development machine over USB, if it isn't currently connected.
You may want erase the contents of the userdata partition, by using this fastboot command:
$ fastboot erase userdata
This will remove all of the installed applications and their data, but it is a useful step when debugging because it ensures a clean execution environment for the application. Erasing the user data may also be necessary when you are flashing a lower (downgrade) platform version to your device. However, it is not strictly necessary to erase the userdata partition when upgrading to a higher (upgrade) platform version, which is the typical use-case in consumer devices.
You may also want to erase the cache partition, using this fastboot command:
$ fastboot erase cache
Note that, rather than using separate fastboot commands to erase the userdata and cache partitions, as described in the previous steps, you can simply supply the -w option when flashing the system image, which has the same result.
Next, use this fastboot command to flash the contents of the image package to the device:
$ fastboot update <imagepackage>.zip [-w]
With this command, fastboot copies all of the images in <system-image-package>.zip to the appropriate partitions on the device. During the process, it prints status messages to the command shell. Depending on your bootloader version, fastboot may also print status messages to the bootloader screen.
When all image are copied to the device successfully, fastboot displays a success message.
For information about other fastboot commands, use
$ fastboot
Reboot the device. In most cases, fastboot should reboot the device automatically after copying the image files.
If necessary, you can reboot the device manually using these fastboot commands:
$ fastboot reboot
or
$ fastboot reboot-bootloader
You can also reboot from the device by holding down the key combination MENU+SEND+END.
After rebooting, the device should start normally. If the device does not start normally, you can try flashing it again. If you did not erase the userdata partition and the device hangs during boot, try erasing the userdata partition and then reboot.
For discussions and support about updating your Android Dev Phone, please head over to the Android-DevPhone-Updating group.
Troubleshooting
fastboot.exe (on Windows) doesn't detect the ADP device properly
In some cases, Windows detects the ADP1 bootloader as a USB mass storage device, preventing fastboot.exe from accessing it. To resolve the issue, you can dissociate the USB Mass Storage driver from your ADP1 on your Windows machine and install the proper driver instead, as described in the steps below:
Boot the device into fastboot mode, as described above, and connect the device to your machine over USB.
Navigate to Start > Control Panel > System > Hardware > Device Manager > Universal Serial Bus Controllers. Observe that the ADP device is listed as a USB Mass Storage Device.
Right-click USB Mass Storage Device and select Uninstall. Windows then prompts you with a "New Hardware Found Wizard" message. If Windows doesn't prompt you, you can manually re-detect devices by selecting Action > Scan for hardware changes.
Install the USB driver included in the Android SDK, as described in Setting up a Device for Development on the Android Developers site.
If you are unable to use fastboot successfully, note that you can use the recovery-image method to flash an updated system image to the device, provided the device has the original factory bootloader. See the Overview for more information, then follow the instructions starting from the top of this document.
When installing updated radio firmware, the recovery console fails to open the update.zip file
As described in Update the Device Radio Firmware, you need to copy the contents of the radio image package to the update.zip archive on the device's SD card, then install the update using the recovery console. In some cases, when you try to install the update, the operation fails because of a problem with the update.zip file. This type of failure usually occurs when you start the installation before all of the radio files are copied to the update.zip archive. To resolve the issue, copy the files again to update.zip, this time waiting a minute or two before starting the installation, to ensure that all of the files are copied successfully.
Cannot downgrade to Android 1.1 with recovery package 142608
If you are using the recovery-image method and had previously downloaded and the Android 1.1 recovery package signed-dream_devphone-ota-142608.zip, you should make sure to download the replacement recovery package signed-dream_devphone-ota-142608-b.zip (see the download link at the top of this page).
This is necessary because the recovery package signed-dream_devphone-ota-142608.zip prevents you from downgrading to it from a higher version of the recovery image. Therefore, if you upgrade to the Android 1.5 recovery image, you won't be able to downgrade to Android 1.1 unless you use the replacement package signed-dream_devphone-ota-142608-b.zip.

Related

Rotted, Team win, er how to update to 5.1?

pretty much says it all, its been a long long time since ive flashed anything ( and the last time i did something it didnt exactly go to plan )
Ive got a Nexus 5 (32GB) its rooted with team win recovery and i would like to update it to the latest version, preferably without losing any data
ive tried searching but there doesn't appear to be a simple guide on how to do this
any help would be greatly appreciated thanks.
There's a whole thread on ota's in the general forum. Start there. You have a number of different options. It would also help to know what android version you're on now.
Sent from my Nexus 5 using XDA Free mobile app
Your Nexus 5 is rotted?
Its not rotted yet, however my typing skills probably have.
Android version 5.0.1
just tried downloading the OTTA update and renaming it as update.zip
then adb sideload with adb sideload update.zip
then error : closed
and thats that.
the guides says this:
Scenario #2
You are stock, with root. Custom Recovery without any modifications or deletions.
Continue to Section B
Click to expand...
Click to collapse
OK, so on to section B as advised
Section B says
Section B: Flashing in a Custom Recovery (TWRP- CWM)
(For Flashing 4.4.4 OTAs and Below ONLY!)
1) Download the OTA.zip and copy to your phone.
2) Boot into recovery.
3) Flash the OTA just like you would a ROM.
4) Reboot.
Click to expand...
Click to collapse
Im on 5.0.1 so thats that out of the window
Download the latest Factory image.
Download the Android SDK.
Boot into bootloader (Vol- & Power). Connect the phone to your Computer. Check for exclamation marks in device manager.
If there are some install the drivers. If there are none extract the contents of the SDK. Copy the contents of the extracted factory image into the same folder (into platform-tools).
Open up the command prompt, by typing "cmd" into the search in the start menu. Once you are in cmd you can change the current folder with "cd" (cd .. gets you out of the current folder and into the above one, path wise / cd foldername enters a folder). "dir" lists the contents of the current folder.
Navigate to your SDK, into the platform tools folder.
Open the flash_all.bat (DO NOT DOUBLE CLICK, do a right click select edit). Type these commands one after the other (just the stuff starting with fastboot). So you flash the new bootloader, reboot, flash radio etc.
The latest fastboot has a "-w" in it. Leave that "-w" out, otherwise you will wipe your device.
Congrats, you flashed a factory image.
If you only want to flash parts of the "image-hammerhead.zip", extract it. It will have several .img files. You can flash these with "fastboot flash "image Type (system/recovery/data)" "filename.img" (without "" of course).

Shield Tablet not being recognized by .adb\devices command

Hello,
I am trying to flash an Nvidia Shield K1 tablet back to a factory image for the first time, and documentation from Nvidia is incredibly vague - and existing posts online just seem to say to refer to the Nvidia instructions.
I have enabled Developer Mode on my Shield. It is running Android 7.0, and when connected to my Windows 7 PC, I have made sure it is in "Transfer Files" mode, and not just "Charge USB" mode.
I have installed the current full Android Studio (the one with the UI, it's not some kind of "minimal install"), and according to the SDK Manager > SDK Tools window, I have Android SDK Build-Tools, Android SDK Platform-Tools, Android SDK Tools, and the Google USB Driver installed. I believe this gives me the "adb" functionality which seems to be a prerequisite for flashing a device.
When I open a standard windows command prompt, and navigate to the sdk\platform-tools directory, and run the ".\adb devices" command, it starts the daemon, but does not detect my Shield Tablet - it doesn't output anything after it says "* daemon started successfully *", just a blank carriage return, and then I'm back to the standard command prompt.
One possibility I had considered as to why the device may not be recognized is because there is a "SHIELD Family USB Windows driver" available online, which might be required for a Windows 7 machine to recognize. I can't link it because of absurd forum restrictions because I'm new. But the site is developer(dot)nvidia(dot)com(slash)shield-open-source. There, in the Shield Tablet K1 section, there 's a Windows USB Driver download link
But I downloaded that, and followed the instructions, and encountered an error
Basically, the driver download file for the official NVIDIA USB driver has a bit of a different folder structure than what the accompanying .txt instructions say, but I did find the android_winusb.inf file.
However, when I attempt to actually apply that android_winusb.inf according to the instructions, I get an error message, essentially saying the android_winusb.inf file is incompatible:
Basically, I get to the screen where there is the "Have Disk..." button, and my Shield appears in the "Model" section as a MTP USB device. When I try to apply the android_winusb.inf file, I get an error message saying "The folder you specified doesn't contain a compatible software driver for your device. If the folder contains a driver, make sure it is designed to work with Windows for x64-based systems." My Windows is 7 64-bit.
So, I can't even apply the official Nvidia USB drivers? Is this what's preventing adb from recognizing my devices? How do I apply the Nvidia USB drivers?
Note that I don't think I've ever put my tablet in Fastboot mode before, but I don't think that should be necessary for it to be recognized by the adb devices command, right? If my understanding is correct, adb is NEEDED to put the device in fastboot mode I think.
EDIT: I've also tried this on a Windows 8.1 machine - EXACT same problem.
fastest way to find the directory will be to search for fastboot.exe. For me, I'm running the "Minimal ADB and Fastboot" (I'm on version 1.31, that's probably not the latest, but it works) so I have a C:\Program Files (x86)\Minimal ADB and Fastboot\ directory.
Just search for fastboot and you'll find the directory. Or google the minimal adb and fastboot package and install it.
Frankenscript said:
fastest way to find the directory will be to search for fastboot.exe. For me, I'm running the "Minimal ADB and Fastboot" (I'm on version 1.31, that's probably not the latest, but it works) so I have a C:\Program Files (x86)\Minimal ADB and Fastboot\ directory.
Just search for fastboot and you'll find the directory. Or google the minimal adb and fastboot package and install it.
Click to expand...
Click to collapse
OK, I've downloaded the Minimal ADB and Fastboot v1.4 and installed it. I put my shield tablet into fastboot mode via the hardware volume and power button, and then I ran the fastboot oem unlock command via the Minimal ADB and Fastboot command window and it was successful.
I have gone to this webpage: developer(dot)nvidia(dot)com(slash)gameworksdownload, and searched for "NVIDIA SHIELD Tablet K1 Recovery OS Image"
I downloaded the 1.5.0 image, and extracted the contents.
Am I supposed to take those extracted contents, and paste them directly into the Program Files (x86)\Minimal ADB and Fastboot\ directory? And then I run these commands one at a time from the Minimal ADB and Fastboot command prompt (?):
fastboot flash recovery recovery.img
fastboot flash boot boot.img
fastboot flash system system.img
fastboot flash userdata userdata.img
fastboot flash staging blob
Yes, you can do exactly that!
However, I prefer to leave them on a different hard drive on my system. I keep them in a folder over on my e: drive, so for me the commands might be something like this:
fastboot flash recovery "e:\images\shield50\recovery.img"
and so on...
Before your first flash, make sure your model of shield matches the files!
I've got an original shield so I won't be using the K1 files, but I'm presuming you've got a K1 device so probably you are good to go. Happy flashing. Enjoy!
Frankenscript said:
Yes, you can do exactly that!
However, I prefer to leave them on a different hard drive on my system. I keep them in a folder over on my e: drive, so for me the commands might be something like this:
fastboot flash recovery "e:\images\shield50\recovery.img"
and so on...
Before your first flash, make sure your model of shield matches the files!
I've got an original shield so I won't be using the K1 files, but I'm presuming you've got a K1 device so probably you are good to go. Happy flashing. Enjoy!
Click to expand...
Click to collapse
OK, on that developer(dot)nvidia(dot)com(slash)shield-open-source webpage, I downloaded the Recovery Images for v 1.3, v1.5, and 5.0. These are NOT the developer images - just the so-called "Factory Recovery" images.
My Device had done the 5.1 OTA update (which brought it from 1.3 to 5.1), and my whole point of trying to flash it was I wanted to revert back to 1.3. However, when I use the 1.3 and 1.5 images, when I use the "flash-all.bat" command using the Minimal ADB and Fastboot command line, the Tablet is put into an unusable state - the K1 tablet says "updating apps", and when it finishes, it just reboots to Nvidia logo, and goes to "updating apps", reboots, infinitely.
If I use the 5.0 image files, and use "flash-all.bat", the device is usable, and does boot into Android v7.0, but it doesn't prompt me about user settings and personalization like when I first got the device - it goes straight into the Android Nougat OS. Also, Bluetooth is completely hosed on it, which it wasn't when I fist got it. If I ever turn Bluetooth on a "Bluetooth Share keeps stopping. Close App" message keeps appearing and disappearing, and I can see that Bluetooth keeps turning off and on, for 5 to 10 minutes straight. It eventually stops if I poke around other system menus for some reason, even without changing any settings.
What is also very strange is even though this is supposed to be a "Factory Fresh" image (the 5.0 image I downloaded), my device still remembers my wi-fi network (connecting to it automatically), even though it was supposed to be wiped clean. Again, I used the "flash-all.bat" file that is included with all the image.
Any ideas why my device isn't truly resetting to the "Factory Image"? Possibly of note is that the official Nvidia instructions mention a command "fastboot flash userdata userdata.img", but there is no userdata.img file in their image files that they provide.
ravl13 said:
OK, on that developer(dot)nvidia(dot)com(slash)shield-open-source webpage, I downloaded the Recovery Images for v 1.3, v1.5, and 5.0. These are NOT the developer images - just the so-called "Factory Recovery" images.
My Device had done the 5.1 OTA update (which brought it from 1.3 to 5.1), and my whole point of trying to flash it was I wanted to revert back to 1.3. However, when I use the 1.3 and 1.5 images, when I use the "flash-all.bat" command using the Minimal ADB and Fastboot command line, the Tablet is put into an unusable state - the K1 tablet says "updating apps", and when it finishes, it just reboots to Nvidia logo, and goes to "updating apps", reboots, infinitely.
If I use the 5.0 image files, and use "flash-all.bat", the device is usable, and does boot into Android v7.0, but it doesn't prompt me about user settings and personalization like when I first got the device - it goes straight into the Android Nougat OS. Also, Bluetooth is completely hosed on it, which it wasn't when I fist got it. If I ever turn Bluetooth on a "Bluetooth Share keeps stopping. Close App" message keeps appearing and disappearing, and I can see that Bluetooth keeps turning off and on, for 5 to 10 minutes straight. It eventually stops if I poke around other system menus for some reason, even without changing any settings.
What is also very strange is even though this is supposed to be a "Factory Fresh" image (the 5.0 image I downloaded), my device still remembers my wi-fi network (connecting to it automatically), even though it was supposed to be wiped clean. Again, I used the "flash-all.bat" file that is included with all the image.
Any ideas why my device isn't truly resetting to the "Factory Image"? Possibly of note is that the official Nvidia instructions mention a command "fastboot flash userdata userdata.img", but there is no userdata.img file in their image files that they provide.
Click to expand...
Click to collapse
Sounds like the FlashAll.bat is hosed and not clearing your user partition. Don't use it. The fact that it's not overwriting the user data explains why it remembers your user data, and also why it's a bit borked after completing. Random bits of 1.5 settings are hanging around and confusing 1.3.
To recover, flash them manually one at a time, like this, in this exact order:
fastboot flash recovery recovery.img
fastboot flash boot boot.img
fastboot flash system system.img
fastboot flash userdata userdata.img
fastboot flash staging blob
Meanwhile I'm having my own fun fiasco, having taken advice that it was safe to flash the ROW LTE image on a US Device. Messed up my baseband in the process, apparently...
Frankenscript said:
Sounds like the FlashAll.bat is hosed and not clearing your user partition. Don't use it. The fact that it's not overwriting the user data explains why it remembers your user data, and also why it's a bit borked after completing. Random bits of 1.5 settings are hanging around and confusing 1.3.
To recover, flash them manually one at a time, like this, in this exact order:
fastboot flash recovery recovery.img
fastboot flash boot boot.img
fastboot flash system system.img
fastboot flash userdata userdata.img
fastboot flash staging blob
Meanwhile I'm having my own fun fiasco, having taken advice that it was safe to flash the ROW LTE image on a US Device. Messed up my baseband in the process, apparently...
Click to expand...
Click to collapse
Thanks. I found out there's no longer any userdata.img in the Nvidia Shield K1 official images, so I have to do an extra step of doing the factory reset/wipe data procedure on my tablet first, and then image it.
Good luck with the phone
I am at basically the same spot on my Shield K1 Nougat in that in ADB Fastboot cmd line: adb devices and get nothing, neither in recovery mode or fully booted Android with MTP USB mode selected. The device isn't detected at all in Device Manager in any of the usual spots, and doesn't repopulate the list when unplugged/plugged back in.
PLEASE HELP!!!

[GUIDE] [SUPPORT] How to root, optimize, and repair Xiaomi Redmi Go.

The One-for-All Guide to rooting, improving, and fixing various errors in Xiaomi Redmi Go!​Hello everyone! This thread that I made is for all people who wants to modify and gain full access, as well as to repair their Xiaomi Redmi Go devices the well-guided way, I've noticed that nobody has made an all-in-one guide for this phone so I decided to do it, this thread will keep on expanding depending on what I will discover about this phone, but for now, here is the thread, i expect that you have at least a little amount of knowledge when it comes to phones such as ADB and Developer Options.
What can we do with Xiaomi Redmi Go:
1. We can root it, and the best root manager for this phone is Magisk, SuperSU is also good, but if you're planning to use your phone for mobile banking, then Magisk is right for you. (Unfortunately this isn't true right now due to ctsProfile being hard to manipulate, Redmi Go supports hardware backed key attestation which means your device will definitely be not certified no matter what you do, so until we get a new method, don't root your phone if you want to use apps like Google Pay
2. TWRP is the current custom recovery available for this phone, it has flaws, but its currently the best out there, so its worth the shot to install it, the thread for it will guide you.
3. No custom kernels, people said that they have managed to install AOSP 9 and GSI on this device and made it boot up, but for me, it's better to wait for the official ROM update, after all, the device is still supported.
Prerequisites:
1. Xiaomi Redmi Go
2. An internet connection, a strong one is recommended if you want to download a ROM.
3. A computer with SDK Platform Tools ready to use, this is required, the link is here: https://developer.android.com/studio/releases/platform-tools
Don't forget to also get its driver! The link is also here: https://developer.android.com/studio/run/win-usb
The drivers are tricky to install but I will guide you on doing it in the easiest way possible, please continue on the thread.
4. SD card, your user data will be erased later, better back your files up, this is a warning.
5. Turning on "OEM unlocking" and USB Debugging in Developer Options, this is also really important!
Table of contents:
1. Unlocking the bootloader (and setting up ADB)
2. Rooting
3. Applying the custom recovery
4. Additional modifications
5. Stock ROM links
6. Bonus Section
WARNING: I am not responsible for anything that happens to your device as you follow my guide, do not blame me if you turned your device into a paperweight, made it explode, made it fly or whatever it may be, you chose to modify this phone and you should be accountable for it, you must know the consequences of what you're doing, try to point your finger at me because of what YOU did and I will laugh at you.
I am ready to assist though, so please feel free to ask some questions!
Let us begin, this will take several minutes, so please be patient and avoid rushing.
1. Unlocking the bootloader.
NOTE: This requires your computer to have SDK Platform Tools extracted to any location as long as its easy to access, and its really complicated to talk about it here, this step doesn't include the method where you request a code from Xiaomi, but I've provided a link for it.
A. First, get your phone up, and open the folder on where the SDK Platform Tools are placed, make sure that your in the directory where you see the .exe files of the SDK, now, hold Shift on the keyboard and click "Open Command Prompt here" and type "adb reboot bootloader", without quotes don't forget! This applies to all the steps that I will provide, don't forget to change the USB connection mode of your phone to PTP for it to be detected by ADB! (Only applies to Windows 8/8.1) Once your phone is asking for an authorization, check "Always allow this computer" then tap allow.
B. Once your device has been booted up into Fastboot or the bootloader, check first if your device is being detected, type "fastboot devices", if yes then proceed, if no, then stop here for now.
1B. If this happens then you may have to check your drivers and see if its installed correctly, once your device can be seen at "adb devices" it should also been seen in "fastboot devices" and when the phone is in adb sideload, if not then you have to reinstall ADB, get the proper drivers and do it again.
C. Now, type "fastboot oem unlock-go", the terminal will warn you that all of your user data will be removed, if you have them backed up then and go ahead and enter the command, if not, then just type "fastboot reboot" and start backing up your files, then do this again.
D. The phone will boot up and say "Erasing", to confirm that your phone has its bootloader unlocked, once it boots up again see if it says "Unlocked" on the bottom part of your screen, if there is then congratulations, it should be unlocked at this point.
1D. https://www.getdroidtips.com/unlock-bootloader-xiaomi-redmi-go/, this one particular link provides you on how to unlock the bootloader by entering a certain code, I believe this is a safer method but requires a bit of time, go here if you're interested.
NOTE: The phone supports the command "fastboot flashing unlock_critical" if you are going to unlock your phone with the normal command (fastboot oem unlock_go/fastboot flashing unlock), consider using this 2nd command too, what it does is that it allows you to also flash partitions you supposedly don't have access to, just be very careful not to flash any wrong file! It will be useful to make the "flash_all.bat" script work that you can find on the fastboot ROM for this device, more below!
Once your bootloader has been unlocked, you can now proceed to the other steps that I provided here, don't forget to enable USB Debugging on your Developer Options.
1.2 Setting up ADB
1. Grab your phone, unlock and open your Developer Options then enable "USB Debugging", then change your connection type to "PTP" if you are using Windows 8/8.1, I am not sure if this is required on 7, but it is not needed on Windows 10.
2. Go to this link: https://developer.android.com/studio/releases/platform-tools and download the .zip file, then extract it to a location that is easy to access, like your desktop.
3. Get the official Google drivers here: https://developer.android.com/studio/run/win-usb download the .zip file as well, and extract it too.
4. Go to the extracted folder of your SDK Platform Tools, and go to the directory where you can see various .exe files such as "adb.exe", now, hold the Shift key then click the Right mouse button, then click "Open command prompt here" If this doesn't work for you, open up CMD with admin rights, then type in cd *the location of your platform tools* say on mine, I will input cd C:\Users\James\Downloads\platform-tools_r31.0.3-windows\platform-tools then enter
5. Open your Device Manager by pressing Windows + R, put "devmgmt.msc" without any quotes then Enter, do not close the Device Manager until you're done with all the steps! And please be fast here too or else ADB will not work, now go to your extracted folder of the Google USB driver, and look for the file "android_winusb.inf", copy the location path of it as you will need the exact location path of the file later, in my case it was "C:\Users\Symphony\Desktop\latest_usb_driver_windows\usb_driver\android_winusb.inf".
4A. There are 3 main ADB devices that you have to install, Android ADB Interface, Android Bootloader Interface and Android Composite ADB Interface, so I will divide this into 3 sections, have your Device Manager, and the exact location of the .inf.
NOTE: Turn off the internet connection of your computer, why? Because, if you let Windows install the drivers for you, the drivers may be incorrect and will break things apart, as we will encounter several "Unknown devices" in the Device Manager and we have to update them with the extracted files from Google.
Android ADB Interface
1. Now, make sure that USB Debugging is enabled, now plug in your phone and let the drivers install WHILE your computer is offline, now go to your Device Manager after the driver installation and you should see that there is a driver named "Android" with an exclamation mark.
2. Select the "Android" driver with an exclamation mark, then click "Update device driver", click "Browse my computer for driver software" then click "Let me pick from the list of devices on my computer", click Next, then click "Have Disk", now, remember the location path you copied earlier? Now paste that path (like C:\Users\Symphony\Desktop\latest_usb_driver_windows\usb_driver\) to the white bar under "Copy manufacturers files from:", overwrite the A:\ with your copied path then Browse, select the "android_winusb.inf" and click OK, now, select the "Android ADB Interface", once the driver has been installed and the interface doesn't give errors such as "The device cannot start", then you're good to go.
NOTE: If you plug your phone and there is no "Android" device with exclamation mark, you can proceed to try and see if adb detects your device by typing "adb devices" in the command right now, it should be since this is what I experienced when setting up my device in Windows 10, this step usually applies only if you are using Windows 8/8.1
Android Bootloader Interface
1. To test, go to the command prompt you opened earlier, and type "adb devices", the device should now be detected at this point, when it does, type "adb reboot bootloader".
2. Now, make sure USB Debugging is enabled on the device before booting it into bootloader, now plug in your phone again and let the drivers install WHILE your computer is offline, Go to your Device Manager after the driver installation and you should see that there is a driver named "Android" with an exclamation mark.
3. Select the "Android" driver with an exclamation mark, then click "Update device driver", click "Browse my computer for driver software" then click "Let me pick from the list of devices on my computer", click Next, then click "Have Disk", now, remember the location path you copied earlier? Now paste that path (like C:\Users\Symphony\Desktop\latest_usb_driver_windows\usb_driver\) to the white bar under "Copy manufacturers files from:", overwrite the A:\ with your copied path then Browse, select the "android_winusb.inf" and click OK, now, select the "Android Bootloader Interface", once the driver has been installed and the interface doesn't give errors such as "The device cannot start", then you're good to go.
Android Composite ADB Interface
1. Before proceeding, type "fastboot devices", the device should now also be detected on fastboot, now, type "fastboot reboot", and afterwards, enable "USB Debugging" on the Developer Options, then go your command prompt, then type "adb reboot recovery".
2. Now, now plug in your phone again and let the drivers install WHILE your computer is offline, now go to your Device Manager after the driver installation and you should see that there is a driver named "Android" with an exclamation mark.
3. Select the "Android" driver with an exclamation mark, then click "Update device driver", click "Browse my computer for driver software" then click "Let me pick from the list of devices on my computer", click Next, then click "Have Disk", now, remember the location path you copied earlier? Now paste that path (like C:\Users\Symphony\Desktop\latest_usb_driver_windows\usb_driver\) to the white bar under "Copy manufacturers files from:", overwrite the A:\ with your copied path then Browse, select the "android_winusb.inf" and click OK, now, select the "Android Composite ADB Interface", once the driver has been installed and the interface doesn't give errors such as "The device cannot start", then you're good to go.
2. Applying the recovery/custom recovery
A. Open up your phone and ensure that USB Debugging has been enabled, now, open up your command prompt just like in Step 1 in Unlocking the Bootloader and type "adb reboot bootloader"
B. Next up, type "fastboot flash recovery path/to/recovery.img", substitute the path/to/ with the actual location of your recovery, and please make sure that the name of the image is "recovery.img"! Or else it will not overwrite/update the recovery, you can also put your recovery.img directly within the platform-tools folder so that all you have to type is "fastboot flash recovery recovery.img" then press enter.
C. Once your done, reboot the phone and press Volume Up + Power at the same time, and the recovery will start. (You may want to do this else the recovery will be automatically removed and replaced with the stock one)
1C. For the stock recovery, once you press the combination, the phone will say "No command", at this point, hold your Power button and press Volume up one time to get into recovery.
https://forum.xda-developers.com/android/development/recovery-twrp-3-3-0-redmi-t3929282 here is the link of the TWRP recovery, I encourage you to follow the steps mentioned in the post properly.
WARNING: The fix I provided below is now pushed here for 1 certain reason, before you try to root your phone and do everything else, you must decrypt your internal storage first and it is quite easy, first you must get the decrypt.zip linked in this thread (if the .zip cannot be found, I still have a copy of it), go to TWRP and do "format data", not Wipe Data! How so? Once you reboot to TWRP, it will show you the "Wipe" button, tap that, then the "Format Data" button should show up, this will require you to type in "yes" so type it in, then once it is done formatting, go back to the main TWRP screen, tap "Reboot", then "Reboot to Recovery", afterwards you must go to "Install" then proceed to install the "decrypt.zip", after that you can now flash .zip files from your internal storage too, but beware that you must do this every time you update your device!
3. Rooting your phone
A. To get started, install TWRP for your phone first.
B. Get the .zip file of Magisk/SuperSU so you can install them, the links are https://forum.xda-developers.com/apps/magisk/official-magisk-v7-universal-systemless-t3473445 and https://forum.xda-developers.com/apps/supersu/stable-2016-09-01supersu-v2-78-release-t3452703
C. Reboot your phone to recovery or just plug it in, open the command prompt again just like in the previous step and put "adb reboot recovery" without quotes.
D. Tap "Install" on your TWRP recovery and select the respective installation .zip file of your chosen root management app, and wait for it to finish.
1D. The .zip for both SuperSU and Magisk can be installed through "adb sideload", if incase you don't have an SD card! It may also work with fastboot as well but I need someone to confirm this.
E. When it's done, wipe the cache first, then reboot.
1E. If the root management app didn't appear in your phone after boot, just install the APK of it in the Play Store and check if root has been applied, if not, repeat step C and D again.
BONUS: It may be useful also to grab EdXposed or LSposed for Magisk and the link is here: https://forum.xda-developers.com/t/...or-of-xposed-oreo-pie-q-r-2020-07-19.4070199/ and here: https://forum.xda-developers.com/t/...e-magisk-module-edxposed-alternative.4228973/, please choose only one! You will use the normal Xposed if you're using a different root management app such as SuperSU, the link is here: https://forum.xda-developers.com/showthread.php?t=3034811
What this does is that if the app is an Xposed/EdXposed/LSposed framework module, any modifications it does to your phone will be based on memory only, it won't modify your phone directly which means your device will be clean, and if it incase the said modification bricks your phone, you can easily recover from it too!
BONUS 2: I also recommend getting the Busybox module from Magisk itself, it can easily be downloaded from the Magisk app, you will need this module if you want your root applications to work more efficiently and avoid errors, as most of them requires Busybox to work, don't use the Busybox installer apps on Play Store as they modify /system directly, only use it if you are using SuperSU.
4. Additional modifications
Once you've managed to root your phone and everything else, what I recommend you could do with your device is to get the following apps:
Titanium Backup - It has the ability to back up apps on your phone, and even its data! this app could do so much more than with what I just mentioned.
LSpeed - A root boosting app that has almost every root tweak packed into it, its really convenient to use! I do not recommend using Entropy tweaks as I heard it is a placebo.
Greenify - For me, this is the only legit battery saving app aside from LSpeed which also offers tons of battery saving features, it requires Xposed to have more options you have to buy it to gain full functionality
ROM Toolbox - This app pretty much contains everything a rooted user needs, such as a terminal and root-based file manager.
System app uninstaller (optional) - Just in case if you're planning to remove some bloatware (the list of it is below)
Root Browser - An alternative to ROM Toolbox, this root explorer is really popular and gets the job done without any interruptions.
Terminal emulator - This will allow you to enter various commands on your phone, like being able to reboot the phone without using any keys.
In order to make the phone as fluid as possible, just leave it with stock ROM installed, try to also use lite apps like Facebook Lite to reduce RAM and battery consumption.
Kernel Adiutor - Another great root application, it's like LSpeed but it doesn't automate tweaks, it instead allows you to modify most of it on your own, then it reapplies your tweaks every time your cellphone will boot up if you tap the "Apply on startup" switch. the link for the app is here: https://m.apkpure.com/kernel-adiutor-root/com.grarak.kerneladiutor
NOTE: Most of these apps can be found on the Play Store, and please don't install any more similar root boosting apps such as HEBF, scripts such as V6 Supercharger, or modifying files like build.prop, it is due to the fact that this will conflict with LSpeed, as LSpeed contains most of the tweaks that past scripts and apps provide, this will result in your phone slowing down a lot, Greenify will require Xposed Framework which is mentioned above on the Rooting section, the link to LSpeed is here https://github.com/Paget96/LSpeed, because the app has been removed from Play Store.
WARNING: The perf.zip https://forum.xda-developers.com/android/development/-t3935220 here, that was provided in Xiaomi Redmi Go forum section must be applied with extreme caution, you have to make a backup of your build.prop in /system, and build.prop + default.prop in /vendor for easy recovery, you can use ZipMe to easily make a backup for these files.
5. Stock ROM links
https://xiaomirom.com/en/rom/redmi-go-tiare-global-fastboot-recovery-rom/, this link so far provides all the ROMs (both recovery and fastboot) available for download on this phone, and they are actually light enough, so it will be easy to download them.
https://xiaomifirmwareupdater.com/archive/miui/tiare/ a new link I've found recently, this rom contains the .tgz format of the latest ROM for the Xiaomi Redmi Go, which could be used for fastboot and Mi Flash Tool, just search for the model and go for Global.
NOTE: Most of the ROMs for this phone provided on several sites, even on the actual Xiaomi website, has an invalid format of .zip, and doesn't contain a flashall script, as a result, Mi Flash Tool will never be able to use these ROMs, you could not also use adb sideload and fastboot for these ROMs, only the stock recovery of the phone could install the ROM, due to the links provided above finally giving the latest ROM versions for the phone, extracting the stock recovery is very easy now, you can do it yourself but if you need a link, tell me.
5A. Applying the stock ROM
This section will be divided into 2 sections, flashing the ROM through recovery, flashing the ROM through fastboot manually, or automatically with flash_all.bat
Stock recovery method.
A. Download the stock ROM with .zip format and put it into your SD Card.
B. Flash your recovery back to stock with the steps given above, boot into your stock recovery, then using your Power button and volume keys to navigate, select "Apply update from SD card".
C. Select the .zip file and wait for the update to finish.
D. The device will boot up automatically after, if not, just go back to the main menu of the recovery and select "Reboot system", enjoy!
Fastboot manual flashing method.
A. Ensure that you have prepared your device and computer for ADB, now grab the ROM given in this thread in .tgz format, and keep extracting the file until you see the files such as "flash-all.sh" after extraction, as you need to extract the .tgz ROM two times before you could use it properly.
B. Now go to the extracted folder of the stock ROM, go the "images" folder and copy the following image files: boot.img, system.img, recovery.img (make a backup of this file somewhere!), vendor.img, cache.img, userdata.img, persist.img, and splash.img.
C. Paste them to the extracted folder of your SDK Platform Tools where various .exe files are located such as "adb.exe", or in my case the location is "C:\Users\Symphony\Downloads\platform-tools_r29.0.4-windows\platform-tools".
D. Now open your command prompt on this directory, or Shift + Right click, then plug in your phone, now type "adb reboot bootloader" so your phone will go to bootloader, don't forget to enable "USB Debugging" and PTP connection mode before rebooting! (only applies to Windows 8/8.1, it may vary on Windows 7 but it is different on 10, no need for PTP connection mode, you can just turn on USB debugging and that's all)
E. Now, this is a little tricky, but try to follow me as much as you can, make sure first that you are detected with "fastboot devices", input the following commands that I will give so you can flash the ROM to your phone, now go to the command prompt and:
To flash the boot.img to your phone, put the command: "fastboot flash boot boot.img"
For the recovery, the command is: "fastboot flash recovery recovery.img"
For the system or main OS: "fastboot flash system system.img"
For cache: "fastboot flash cache cache.img"
For persist: "fastboot flash persist persist.img"
For the vendor or additional system files: "fastboot flash vendor vendor.img"
For data or apps: "fastboot flash userdata userdata.img"
For splash or probably boot animation: "fastboot flash splash splash.img"
D. After that, type "fastboot reboot", and enjoy!
Fastboot automatic flashing method (NEW!)
A. Extract the fastboot ROM 2 times as instructed, after getting the files, grab all the files and copy it to the directory of your platform tools where files such as "adb.exe" can be found, just copy all the files in there and that's all you have to do.
B. Open the "flash_all.bat" on Notepad and remove the following lines:
fastboot %* getvar product 2>&1 | findstr /r /c:"^product: *tiare" || echo Missmatching image and device
fastboot %* getvar product 2>&1 | findstr /r /c:"^product: *tiare" || exit /B 1
Afterwards, save the .bat file, that should be ready to use now
C. As instructed above, you must also do "fastboot flashing unlock_critical" after unlocking your bootloader the normal way, this will act as your 2nd unlock command, without this, the flash_all.bat will not work as it should be.
D. Boot up your phone in fastboot mode, open up your adb devices and make sure that your phone is seen in "fastboot devices", once it does, type in "flash_all.bat" without any quotes and execute it, the command will now automatically flash everything without you doing anything else, it will also automatically reboot after doing so.
Bonus section:
1. TWRP-compatible stock ROM
For this part, in order for you to generate a TWRP-flashable stock ROM is by basically making it yourself, you have to make sure that your patch is latest, and its pretty much a good idea to just tick everything in the backup selection except for the recovery, as well as the cache as you don't need those.
Once you have it, go ahead and keep it somewhere safe but easy to find, so if case that you need to use it, you could get it immediately, this is extremely useful so please just do it, as of now, I've confirmed that only the /data backup was usable, but please try to confirm if other partition backups are working for you.
Certain custom ROMs that can boot up in this device could be flashed through TWRP though, and the links of them are provided here in this thread.
2. GSI, AOSP 9 and custom ROMs
The link for AOSP is provided here: https://forum.xda-developers.com/android/development/redmi-aosp-9-t3922192
The link for GSI is right here: https://forum.xda-developers.com/android/general/tested-gsi-redmi-t3924705
These images/ROMs can be applied with TWRP, just make sure to follow the steps mentioned in these posts to avoid inconvenience, don't forget to take precautions too! I haven't tried them, but so far I believe that these are stable to use.
There are also custom ROMs released for the device but I am lazy to link all of them, they can easily be found by going here: https://forum.xda-developers.com/tags/xiaomi-redmi-go/
Please take note that I haven't tested these custom ROMs yet and I most likely never will, since the stock ROM for the device is already good enough, you can comment here and tell me what custom ROMs are stable so I can link them here for future reference.
3. Current status
My phone is still working, yes! and it's still staying strong, updated to 2.25 using the fastboot method and it is still fast, the only issue currently is that SafetyNet is a lot more secure than before, so it will be impossible to use stuff like Google Pay for now.
I usually decided to lay low and just stay with my LSpeed, Kernel Adiutor and Greenify, all I had to do is to tinker with these apps and my phone just reached into a whole new level! The performance improvement is nice, that I didn't need to use a custom ROM anymore.
4. How to install a OTA update after rooting your device
Due to the changes made by Google on SafetyNet, and the fact that this device will always require you to wipe the device every update, it is pretty much the same, it doesn't matter anymore if you are certified or not, you will still receive an OTA update even if your device is not certified as long as you are using the stock ROM, you only won't be able to install it, and if you want to install the OTA update you must install it by flashing the updated fastboot ROM, I have links for it above, you can try installing the OTA updates yourself through the settings but you will still have to do a factory reset anyway, you have to also unroot also and revert to stock recovery, else the installation will fail, and your device may slower afterwards.
5. Bloatware you can safely remove (NEW!)
So, like I said above, as much as how lightweight the device is, there are still bloatware that you can remove if you really want, but it's only 3 of them:
Mi Video
Mint Browser
Mi Music
The rest such as Mi Share and Mint Launcher are also bloatware, you can remove them but to me they are useful so I didn't, do not remove the "Cleaner" app, if it however says something like "com.CleanMaster", you can try removing it but take caution as your Play Store may be removed along with it too.
Credits to everyone who made the apps/tools that I mentioned here! such as @topjohnwu for the Magisk, and @YasiR Siddiqui for the TWRP, @Paget96 for the awesome LSpeed app, @rovo89 for the Xposed Framework and many more, you guys totally rock!
Hello and thank you for this tutorial. I'd like to ask. Do You know a way where I can unlock the bootloader without permissions or oem unlock? I have a soft-bricked device and for me, there is no way I can get into the OS and manually switch the Oem unlock setting. I've tried different softwares, different adb commands, different region firmwares, still no luck. I can't also get into the the download mode. I mean, yeah, I get the "no command" screen but after pressing power button + up volume button my phone restarts into the fastboot mode and there is no way I can normally boot. It's looping to fastboot mode over and over...
TheAngryGuitarist said:
Hello and thank you for this tutorial. I'd like to ask. Do You know a way where I can unlock the bootloader without permissions or oem unlock? I have a soft-bricked device and for me, there is no way I can get into the OS and manually switch the Oem unlock setting. I've tried different softwares, different adb commands, different region firmwares, still no luck. I can't also get into the the download mode. I mean, yeah, I get the "no command" screen but after pressing power button + up volume button my phone restarts into the fastboot mode and there is no way I can normally boot. It's looping to fastboot mode over and over...
Click to expand...
Click to collapse
Can you please elaborate all of what you've done so far? I will also ask you a few questions.
1. Is your phone usable with the platform tools? I mean with adb and such.
2. Did you try going into recovery and flashing stock ROM through there?
3. Is your phone being detected by "fastboot devices"? The fastboot mode of Redmi Go is its download mode, and i've provided the link for the stock ROM that's usable thru fastboot mode, as well as on how to apply it.
My phone is usable with adb and such, the recovery mode was not working, only the fastboot. I've tried flashing stock rom with the flash tool but I had no success with a bricked soft and a locked bootloader. I've finally fixed it by going into the edl mode by test point method then I flashed the stock rom, and I've fixed my problem this way. I couldn't unlock the bootloader manually from adb or the unlocker tool, but I've did it in the edl way.
TheAngryGuitarist said:
Hello and thank you for this tutorial. I'd like to ask. Do You know a way where I can unlock the bootloader without permissions or oem unlock? I have a soft-bricked device and for me, there is no way I can get into the OS and manually switch the Oem unlock setting. I've tried different softwares, different adb commands, different region firmwares, still no luck. I can't also get into the the download mode. I mean, yeah, I get the "no command" screen but after pressing power button + up volume button my phone restarts into the fastboot mode and there is no way I can normally boot. It's looping to fastboot mode over and over...
Click to expand...
Click to collapse
TheAngryGuitarist said:
My phone is usable with adb and such, the recovery mode was not working, only the fastboot. I've tried flashing stock rom with the flash tool but I had no success with a bricked soft and a locked bootloader. I've finally fixed it by going into the edl mode by test point method then I flashed the stock rom, and I've fixed my problem this way. I couldn't unlock the bootloader manually from adb or the unlocker tool, but I've did it in the edl way.
Click to expand...
Click to collapse
Can you please elaborate the term "edl mode"?
Good job then, usually, before you modify the phone and start doing something crazy out of stock, your number one step is to really unlock the bootloader, and in order to make things more easier, you should allow your OEM to be unlocked through the developer options, after that you can now unlock the bootloader with fastboot.
_XblackshadowX_ said:
Can you please elaborate the term "edl mode"?
Good job then, usually, before you modify the phone and start doing something crazy out of stock, your number one step is to really unlock the bootloader, and in order to make things more easier, you should allow your OEM to be unlocked through the developer options, after that you can now unlock the bootloader with fastboot.
Click to expand...
Click to collapse
Yes, it's the emergency download mode. You use it when there is nothing you can do about the soft of your device. It automatically unlock the bootloader and you can flash the stock rom. Well, my problem was another. I did not tried to flash roms or recoveries with a locked bl. My phone automatically rebooted into the fastboot mode and from there I was not able to start my phone normally. I've tried rebooting fastboot from adb, unlock bl from adb, no success. I had to dissamembly the phone and make a short-circuit to the test points while slowly pushing in the mtp cable with the battery disconnected. Once I saw the Qualcomm driver on device manager I was able to flash the stock rom. You can search if you want to, for the test pins of this device. Btw, thank for your advice, you are really helpful to the community! ?
TheAngryGuitarist said:
Yes, it's the emergency download mode. You use it when there is nothing you can do about the soft of your device. It automatically unlock the bootloader and you can flash the stock rom. Well, my problem was another. I did not tried to flash roms or recoveries with a locked bl. My phone automatically rebooted into the fastboot mode and from there I was not able to start my phone normally. I've tried rebooting fastboot from adb, unlock bl from adb, no success. I had to dissamembly the phone and make a short-circuit to the test points while slowly pushing in the mtp cable with the battery disconnected. Once I saw the Qualcomm driver on device manager I was able to flash the stock rom. You can search if you want to, for the test pins of this device. Btw, thank for your advice, you are really helpful to the community!
Click to expand...
Click to collapse
Woah, you really had to open the phone before doing it, that's an interesting method!
That part where your phone booted into fastboot was kind of scary, any ideas why it booted into fastboot in the first place? It has to be reported if incase, seems like a dangerous bug.
_XblackshadowX_ said:
Woah, you really had to open the phone before doing it, that's an interesting method!
That part where your phone booted into fastboot was kind of scary, any ideas why it booted into fastboot in the first place? It has to be reported if incase, seems like a dangerous bug.
Click to expand...
Click to collapse
I'm not really sure if a malware caused this issue or a failed system update over-night.
TheAngryGuitarist said:
I'm not really sure if a malware caused this issue or a failed system update over-night.
Click to expand...
Click to collapse
I usually had failed system updates numerous times because when i install them, the phone has already been modified by a lot, and that's actually riskier.
That's why i recommend unrooting and putting back the stock recovery before updating first, still works on mine even with "Device is not certified" by Play Store.
The TWRP linked here is for Pie 9, I couldn't get it to boot on my phone, it shows vertical lines.
This is the older version for Oreo 8...
https://forum.xda-developers.com/android/general/twrp-xiaomi-redmi-beta-t3918993
I formatted the phone from TWRP it so it was no longer encrypted.
Mounted the drive from TWRP and installed the "decrypt.zip" from the other TWRP...
https://forum.xda-developers.com/android/development/recovery-twrp-3-3-0-redmi-t3929282
I unlocked the bootloader successfully.
In the setting up ADB step, I don't clearly understand. When I connect my device to the pc, no drivers are installing. And there is no driver named "Android" with an exclamation mark. But my device is getting recognized in "portable devices >> redmi go". I'm very new with adb it would be a lot of help.
I've attached the screenshot of my device manager,
bhattinb said:
I unlocked the bootloader successfully.
In the setting up ADB step, I don't clearly understand. When I connect my device to the pc, no drivers are installing. And there is no driver named "Android" with an exclamation mark. But my device is getting recognized in "portable devices >> redmi go". I'm very new with adb it would be a lot of help.
I've attached the screenshot of my device manager,
Click to expand...
Click to collapse
Did you try turning on USB Debugging on Developer Options? Did you try installing the USB drivers from Google?
_XblackshadowX_ said:
Did you try turning on USB Debugging on Developer Options? Did you try installing the USB drivers from Google?
Click to expand...
Click to collapse
Yeah, I've done everything you told, I also turned the connection mode to PTP also. Somehow it just not showing that android with an exclamation mark.
after that, I even tried to use the 15-second ADB installer. after installing that I tried to flash recovery but that just didn't do anything. After using that flashing command, I had the same stock recovery.
I'm really thankful you took the time to answer my question.
Help!! My device stuck on screen saying your system has been destroyed. What I had done is locked the bootloader using command fastboot oem lock then this happened. Now i can boot device in stock recovery and bootloader too but when i am trying to unlock bootloader it says device is lock and also i am not able to flash anything. Plz help.
I am not able to flash TWRP on my redmi go
How to update the redmi go to the latest version without formatting/Factory Reset should I just follow Fastboot flashing method and if so which files should I just flash. Thank you
bhattinb said:
I unlocked the bootloader successfully.
In the setting up ADB step, I don't clearly understand. When I connect my device to the pc, no drivers are installing. And there is no driver named "Android" with an exclamation mark. But my device is getting recognized in "portable devices >> redmi go". I'm very new with adb it would be a lot of help.
I've attached the screenshot of my device manager,
Click to expand...
Click to collapse
Hi! sorry for the late reply, if this is the case then it's fine, you can just connect the device, open up adb tools, type adb devices and ensure that your USB debugging is on, and the device will connect immediately, at that point all you need is the adb driver for Fastboot
akki_007 said:
Help!! My device stuck on screen saying your system has been destroyed. What I had done is locked the bootloader using command fastboot oem lock then this happened. Now i can boot device in stock recovery and bootloader too but when i am trying to unlock bootloader it says device is lock and also i am not able to flash anything. Plz help.
Click to expand...
Click to collapse
oh no, but why lock your bootloader? you can try using a recovery ROM, you must have a spare SD Card within you, grab a recovery ROM, put it in your sd card then put it into the phone and use it on stock recovery, you should be able to apply it and boot back into the system, please update me
igpraan said:
I am not able to flash TWRP on my redmi go
Click to expand...
Click to collapse
you must have unlocked bootloader if you want to do so.
niknah said:
The TWRP linked here is for Pie 9, I couldn't get it to boot on my phone, it shows vertical lines.
This is the older version for Oreo 8...
https://forum.xda-developers.com/android/general/twrp-xiaomi-redmi-beta-t3918993
I formatted the phone from TWRP it so it was no longer encrypted.
Mounted the drive from TWRP and installed the "decrypt.zip" from the other TWRP...
https://forum.xda-developers.com/android/development/recovery-twrp-3-3-0-redmi-t3929282
Click to expand...
Click to collapse
that's strange, the TWRP I linked isn't giving me any vertical lines

How To Guide How to extract boot.img from OnePlus 9 firmware packages to patch with Magisk & flash to your phone using Linux Mint 21.1

As a OnePlus 9 user who likes to root their phone mainly to allow Network Signal Guru to work (as well as a few other root things like AdAway) I had been trying to extract the boot.img the same way as I had done with a OnePlus 7T using Payload Dumper for Windows. However it looks like Payload Dumper has issues with extracting xx.img files (including boot.img) if the payload.bin file is bigger than 4.3 GB in size. So I've been looking to see if another method was possible that would work for our OnePlus 9 ROMs that are above this file size. As I use Linux Mint as my usual desktop OS & only fall back onto Windows for stuff that'll only run on that OS, I went to have a look to see if something could be done under Linux. Turns out there is an old thread elsewhere on XDA that almost nearly provides what is needed for this, and I thought I would gives details here that should work for the time of this post (March 2023).
This not only extracts the boot.img to patch in Magisk, but also extracts other xx.img files as well.
I'm using Linux Mint 21.1, but I'd assume that this will also work for similar Ubuntu builds or anything that is based on Debian.
Obligatory disclaimer: The following instructions I'm giving below have worked well for me several times in the past, however I am in no way responsible for screwing up or damaging your phone if you try and follow what I've written below. In extreme cases, a bad flash may require using the OnePlus MSM tool to completely reflash your phone. Back up anything important first before doing any of the following!​
1. You will need to ensure that you have downloaded packages to be able to do adb & fastboot from the command line. You can check by running the following commands - if it's already installed with the latest versions, the terminal interface will let you know...
Code:
sudo apt install adb
Code:
sudo apt install fastboot
2. You will need to go to your software manager in LM21.1 and install both Python 3 & the Python Protobuf compiler. Just search for "Python 3" & "Protobuf-compiler" in the software manager and the first option for each search is what you should need - if they are not installed, install them.
3. Create a read/writable directory that will hold your ROM that you've just downloaded & other files that I'll mention soon. I just use a folder calls "ROM" in my Downloads folder (e.g. /home/lawhec/Downloads/ROM ), but you can choose wherever you want that suits you.
4. If you have not done so already, make sure you have the FULL package of your OnePlus 9 ROM downloaded. As of right now (March 2023) it seems the best way is to download the package using the Oxygen Updater app which is available on Google Play - more info available at oxygenupdater.com - just download the ROM to your phone and transfer it on to your computer into the folder you've created for it.
5. Download and save the following two Python scripts/files ("Right click" & "Save Link As") into the folder you have just created for your ROM (all credit to Gregory Cyxx at github.com/cyxx )...
https://raw.githubusercontent.com/c...payload/master/extract_android_ota_payload.py
https://raw.githubusercontent.com/cyxx/extract_android_ota_payload/master/update_metadata_pb2.py
6. Make sure in your file browser (Nemo in my case as it is the default for LM21.1 Cinammon, yours may differ) the window is open in the ROM folder that contains the two Python scripts above that you've just downloaded as well as a ROM package (ZIP file) you've downloaded (in my case from Oxygen Updater mentioned in step 3). Create a new folder for the extracted images to be written to - in my case I just call the folder "output" which is located at "/home/lawhec/Downloads/ROM/output" but again you can call it what you wish.
7. After you've created your output folder, in your ROM directory in the file manager window right-click on your mouse in a white or free space and select "Open in Terminal" - a command terminal will pop up defaulting to your directory.
8. In the command terminal, type the following command and press enter/return...
Code:
sudo python3 extract_android_ota_payload.py <<Your ROM.zip>> <<Your Output Directory>>
...for example, in my case the command would be either...
Code:
sudo python3 extract_android_ota_payload.py LE2113_11_F-75.zip output
...or for handiness you can type "sudo python3 extract_android_ota_payload.py " (remember to leave a space) and simply drag the ROM zip file to the command terminal, press space and then drag the output foler to the terminal line, which will look like in my case...
Code:
sudo python3 extract_android_ota_payload.py '/home/lawhec/Downloads/ROM/LE2113_11_F-75.zip' '/home/lawhec/Downloads/ROM/output'
...this will now run the python script you downloaded earlier that will begin extracting the ROM you've specified and will output all relevant xx.img files into your output folder, including the one we want, "boot.img" - there is no need to extract paylod.bin beforehand, the script will automatically do this for you. Once all xx.img files have been extracted the script will stop, depending on your computer this will take anything from 1-5 minutes, maybe longer on some very old or low spec'd computers - but just let it run its course. Once it is done you can then close the terminal window.
9. Now with the boot.img we've extracted, transfer this file on to your phone (the Downloads folder is usually a good choice). Now open Magisk and patch the boot.img file - once this has been completed, it'll generate a patched boot.img file named something like "magisk_patched-25200_12345.img" - copy and paste this patched boot image back on to your computer (into the folder you've been using will be fine here).
10. If your OnePlus 9 phone is connected to your computer via USB cable, disconnect it now. Then shutdown your phone into a power-off state then reboot it into fastboot mode - this can be done by holding down the volume up & down buttons, then holding down the power button and keep holding down all three buttons until you feel a vibration from your phone. Your OnePlus 9 should then boot into fastboot mode.
11. Now reconnect your OnePlus 9 to your computer via the USB cable and then open up a new display terminal (preferably by right-clicking in the file window of the directory where you saved your Magisk patched boot.img file). Enter the following...
Code:
fastboot devices
...you should then get a line featuring a block of numbers that should match the serial number that is displayed on your phone's display, followed by "fastboot", for example...
Code:
85f53405 fastboot
...if you get anything else, double check your connections at try again - if more than one device is displayed, disconnect the and try again to make sure that only one device is listed. It might also be the case that you don't have the proper drivers installed on your computer for your phone though in my case LM21.1 automatically recognises my phone, so I'm not of any direct help here I'm afraid for this, sorry.
12. Now you will be flashing your patched boot.img to your phone - this is where things can be a little nervous though as long as you do everything right nothing should really go wrong. Type the following into the command terminal, assuming you did so by opening a command terminal from the folder your Magisk Patched boot.img file is located...
Code:
fastboot flash boot <<Magisk Patched boot.img>>
...for example in my case the command line would be...
Code:
fastboot flash boot magisk_patched-25200_12345.img
...otherwise you will need to provide the location of where your patched boot.img is, so in this case...
Code:
fastboot flash boot '/home/lawhec/Downloads/ROM/magisk_patched-25200_12345.img'
...either way, your phone will now be in the process of getting its boot image replaced with the one patched by Magisk. This should take no more than a few seconds and that should be it done! You can then close the terminal window again.
13. Once you've patched the boot image, disconnect the phone from the USB cable to the computer and make sure that the screen on your mobile says "START" in green at the top, if it doesn't, use the volume keys to change this. Then just simply press the power button and your phone will now reboot, this can take a little bit longer than before as your phone's firmware has changed so give it time - (however if it takes longer than 10 minutes or so you might have a problem here) - once your home screen becomes available, give it a few seconds once you've entered before selecting the Magisk app. Once you've done this, Magisk should say that it is installed however to double check, use an app that requires root permissions either to work (e.g. Network Signal Guru) or to do additional things, like a simple root checker app that you can download from wherever you download your apps. If everything is good, then you've rooted your OnePlus 9!
Notes: This process will probably work for other firmware packages for various phones where the boot.img can be extracted to be patched by Magisk and then flashed via fastboot (assuming the bootloader is unlocked) which includes the OnePlus 7T's stock firmware, but I can give no guarantees for this. Once again, try at your own risk.​
I would suggest to boot the magisk patched image and then doing a direct install from the app instead of flashing it directly. This way you can use the "Restore images" feature in the Magisk app that can be useful when doing incremental update.
Thank You for thinking of Us Linux Users !
Attempted to update to LOS 20 via ADB, and now my touch screen will not work. All the remedies here require a Windows system for the MSM tool, which I do not have...
barguybrady said:
Thank You for thinking of Us Linux Users !
Attempted to update to LOS 20 via ADB, and now my touch screen will not work. All the remedies here require a Windows system for the MSM tool, which I do not have...
Click to expand...
Click to collapse
You have a computer you can install windows on another partition it's not like you don't have the ability to use msm
stez827 said:
You have a computer you can install windows on another partition it's not like you don't have the ability to use msm
Click to expand...
Click to collapse
no comment
barguybrady said:
Yup.
Just gonna spend another 4 or 5 hours prepping a drive to somehow install windows just to fix a phone.
Maybe - No....
Click to expand...
Click to collapse
It does not take that long as a Linux user who has had to install for that exact reason it took maybe an hour or 2
lawhec said:
As a OnePlus 9 user who likes to root their phone mainly to allow Network Signal Guru to work (as well as a few other root things like AdAway) I had been trying to extract the boot.img the same way as I had done with a OnePlus 7T using Payload Dumper for Windows. However it looks like Payload Dumper has issues with extracting xx.img files (including boot.img) if the payload.bin file is bigger than 4.3 GB in size. So I've been looking to see if another method was possible that would work for our OnePlus 9 ROMs that are above this file size. As I use Linux Mint as my usual desktop OS & only fall back onto Windows for stuff that'll only run on that OS, I went to have a look to see if something could be done under Linux. Turns out there is an old thread elsewhere on XDA that almost nearly provides what is needed for this, and I thought I would gives details here that should work for the time of this post (March 2023).
This not only extracts the boot.img to patch in Magisk, but also extracts other xx.img files as well.
I'm using Linux Mint 21.1, but I'd assume that this will also work for similar Ubuntu builds or anything that is based on Debian.
Obligatory disclaimer: The following instructions I'm giving below have worked well for me several times in the past, however I am in no way responsible for screwing up or damaging your phone if you try and follow what I've written below. In extreme cases, a bad flash may require using the OnePlus MSM tool to completely reflash your phone. Back up anything important first before doing any of the following!​
1. You will need to ensure that you have downloaded packages to be able to do adb & fastboot from the command line. You can check by running the following commands - if it's already installed with the latest versions, the terminal interface will let you know...
Code:
sudo apt install adb
Code:
sudo apt install fastboot
2. You will need to go to your software manager in LM21.1 and install both Python 3 & the Python Protobuf compiler. Just search for "Python 3" & "Protobuf-compiler" in the software manager and the first option for each search is what you should need - if they are not installed, install them.
3. Create a read/writable directory that will hold your ROM that you've just downloaded & other files that I'll mention soon. I just use a folder calls "ROM" in my Downloads folder (e.g. /home/lawhec/Downloads/ROM ), but you can choose wherever you want that suits you.
4. If you have not done so already, make sure you have the FULL package of your OnePlus 9 ROM downloaded. As of right now (March 2023) it seems the best way is to download the package using the Oxygen Updater app which is available on Google Play - more info available at oxygenupdater.com - just download the ROM to your phone and transfer it on to your computer into the folder you've created for it.
5. Download and save the following two Python scripts/files ("Right click" & "Save Link As") into the folder you have just created for your ROM (all credit to Gregory Cyxx at github.com/cyxx )...
https://raw.githubusercontent.com/c...payload/master/extract_android_ota_payload.py
https://raw.githubusercontent.com/cyxx/extract_android_ota_payload/master/update_metadata_pb2.py
6. Make sure in your file browser (Nemo in my case as it is the default for LM21.1 Cinammon, yours may differ) the window is open in the ROM folder that contains the two Python scripts above that you've just downloaded as well as a ROM package (ZIP file) you've downloaded (in my case from Oxygen Updater mentioned in step 3). Create a new folder for the extracted images to be written to - in my case I just call the folder "output" which is located at "/home/lawhec/Downloads/ROM/output" but again you can call it what you wish.
7. After you've created your output folder, in your ROM directory in the file manager window right-click on your mouse in a white or free space and select "Open in Terminal" - a command terminal will pop up defaulting to your directory.
8. In the command terminal, type the following command and press enter/return...
Code:
sudo python3 extract_android_ota_payload.py <<Your ROM.zip>> <<Your Output Directory>>
...for example, in my case the command would be either...
Code:
sudo python3 extract_android_ota_payload.py LE2113_11_F-75.zip output
...or for handiness you can type "sudo python3 extract_android_ota_payload.py " (remember to leave a space) and simply drag the ROM zip file to the command terminal, press space and then drag the output foler to the terminal line, which will look like in my case...
Code:
sudo python3 extract_android_ota_payload.py '/home/lawhec/Downloads/ROM/LE2113_11_F-75.zip' '/home/lawhec/Downloads/ROM/output'
...this will now run the python script you downloaded earlier that will begin extracting the ROM you've specified and will output all relevant xx.img files into your output folder, including the one we want, "boot.img" - there is no need to extract paylod.bin beforehand, the script will automatically do this for you. Once all xx.img files have been extracted the script will stop, depending on your computer this will take anything from 1-5 minutes, maybe longer on some very old or low spec'd computers - but just let it run its course. Once it is done you can then close the terminal window.
9. Now with the boot.img we've extracted, transfer this file on to your phone (the Downloads folder is usually a good choice). Now open Magisk and patch the boot.img file - once this has been completed, it'll generate a patched boot.img file named something like "magisk_patched-25200_12345.img" - copy and paste this patched boot image back on to your computer (into the folder you've been using will be fine here).
10. If your OnePlus 9 phone is connected to your computer via USB cable, disconnect it now. Then shutdown your phone into a power-off state then reboot it into fastboot mode - this can be done by holding down the volume up & down buttons, then holding down the power button and keep holding down all three buttons until you feel a vibration from your phone. Your OnePlus 9 should then boot into fastboot mode.
11. Now reconnect your OnePlus 9 to your computer via the USB cable and then open up a new display terminal (preferably by right-clicking in the file window of the directory where you saved your Magisk patched boot.img file). Enter the following...
Code:
fastboot devices
...you should then get a line featuring a block of numbers that should match the serial number that is displayed on your phone's display, followed by "fastboot", for example...
Code:
85f53405 fastboot
...if you get anything else, double check your connections at try again - if more than one device is displayed, disconnect the and try again to make sure that only one device is listed. It might also be the case that you don't have the proper drivers installed on your computer for your phone though in my case LM21.1 automatically recognises my phone, so I'm not of any direct help here I'm afraid for this, sorry.
12. Now you will be flashing your patched boot.img to your phone - this is where things can be a little nervous though as long as you do everything right nothing should really go wrong. Type the following into the command terminal, assuming you did so by opening a command terminal from the folder your Magisk Patched boot.img file is located...
Code:
fastboot flash boot <<Magisk Patched boot.img>>
...for example in my case the command line would be...
Code:
fastboot flash boot magisk_patched-25200_12345.img
...otherwise you will need to provide the location of where your patched boot.img is, so in this case...
Code:
fastboot flash boot '/home/lawhec/Downloads/ROM/magisk_patched-25200_12345.img'
...either way, your phone will now be in the process of getting its boot image replaced with the one patched by Magisk. This should take no more than a few seconds and that should be it done! You can then close the terminal window again.
13. Once you've patched the boot image, disconnect the phone from the USB cable to the computer and make sure that the screen on your mobile says "START" in green at the top, if it doesn't, use the volume keys to change this. Then just simply press the power button and your phone will now reboot, this can take a little bit longer than before as your phone's firmware has changed so give it time - (however if it takes longer than 10 minutes or so you might have a problem here) - once your home screen becomes available, give it a few seconds once you've entered before selecting the Magisk app. Once you've done this, Magisk should say that it is installed however to double check, use an app that requires root permissions either to work (e.g. Network Signal Guru) or to do additional things, like a simple root checker app that you can download from wherever you download your apps. If everything is good, then you've rooted your OnePlus 9!
Notes: This process will probably work for other firmware packages for various phones where the boot.img can be extracted to be patched by Magisk and then flashed via fastboot (assuming the bootloader is unlocked) which includes the OnePlus 7T's stock firmware, but I can give no guarantees for this. Once again, try at your own risk.​
Click to expand...
Click to collapse
If Using the t-Mobile Variant - LE2117 - we are Unable to Install any OTA Updates with OxygenUpdater, and are promptly warned of this limitation upon install. Nevertheless, I forged ahead and,
Following this Method, I downloaded a LE2115_11_F.17.zip, and proceeded to use your helpful .py scripts to extract the boot.img file, and Flash it - promptly sending me to a Qualcomm CrashDump mode.
Having a chance to MSM back to "stock" LE2117 - 11.2.2.2 LE54CB, I am wondering if I should just let the t-Mobile Update, through "Settings >> System >> System update" to Update the Stock ( bloated !? ) OS with all that are available,
Then attempt to Extract a boot.img and Magisk patch it ?
Any Advice?
TIA

Guide to Rooting the Infinix Hot 30 Play, With Magisk

Preface​Luckily, it looks like Infinix is following the general trend of Android root solutions being more straightforward than in the recent past. Besides the usual spiel about your warranty being voided, and the annoying chirp each time you boot your phone, this hopefully won't present any problems for you if you do end up rooting your phone.
Notices​
Still, I'm not responsible for anything bad that will happen to your phone if you do this, and there's no support guaranteed either from me or your OEM/support centre.
There's quite a few steps to this, and naturally you're gonna need a few more things to setup before you even start.
Your phone's data will be reset, please backup everything you'd like to keep before rooting your phone (now and in general).
You do need to know some things already, mainly what ADB and Fastboot are, and how to keep your working environment clean and straightforward.
Please do review all the tools you're working with, be sure that you personally trust all the software you're running.
And last but not least, you won't be able to update your phone through OTA updates anymore unless you go back to stock firmware.
The process​
Make an environment for easy access:
Setup ADB and Fastboot (either as a local executable or a global environment variable to that executable).
Setup an easy to access directory with the Google Fastboot driver in it.
Grab your firmware's boot.img file, or grab the one attached to this post, or from here (and skip to the preliminary work section):
1. Download your phone's current ROM.
2. Extract it, as it should be a simple .zip file.
3. Look for the file of the same name (boot.img).
4. Copy it to your phone's storage, anywhere works.
Install the Magisk APK (from their Github).
Once it's installed, Magisk's app frontend allows you to patch your stock boot.img with itself, the gist of it is:
Click on Install within the app, in the "Magisk" section of the main menu.
Click "Select and patch a file", a file selection menu will show up, select the stock boot.img, then start the installation.
Magisk should spit out a patched boot.img named in the format of magisk_patched_[random_strings].img, in your phone's /sdcard/Download/ directory.
Copy that back into our working directory, and rename it to magisk_patched.img for easier usage.
Now, let's do some preliminary work, in any order, really:
Have Powershell or CMD open in the directory of all your tools, alongside the patched image.
Click to expand...
Click to collapse
From here on out, if you have to use adb as a command, and it's not a global environment variable, use ./adb while in the working directory instead, the same goes for fastboot.
Click to expand...
Click to collapse
Make sure that the adb daemon (adbd) is properly detecting your phone:
Enable developer options.
Enable ADB debugging.
Run adb devices to start the server daemon for ADB, and see if ADB detects your phone.
Authorize your PC for ADB debugging if it prompts you to.
Click to expand...
Click to collapse
Infinix's implementation of Fastboot will exit back out of itself and into normal boot after 60 seconds of inactivity, which makes this a tad annoying, although you can simply send it any input to reset that timer.
Click to expand...
Click to collapse
Let's start:
Restart the phone into Fastboot, adb reboot bootloader loader, it'll take a second, the phone is slow.
Unlock flashing 3rd party software, fastboot flashing unlock, the phone will prompt you on the screen to confirm doing this. Yes, this will void your warranty.
Flash magisk_patched.img to both A and B virtual partitions, fastboot flash boot_a magisk_patched.img and then fastboot flash boot_b magisk_patched.img.
That should be it! fastboot reboot to boot normally!
Be sure to also run the Magisk app so it finishes setting itself up, with another reboot, naturally.
Technicalities​The Infinix Hot 30 Play does have a dedicated vbmeta partition, it's advised that you also flash it alongside flashing the patched boot.img for Verified Boot, but that's not necessary if you don't want to tinker with your super partition's crypto keys.
Thank yous​- topjohnwu for their work on Magisk.
- ansh_/ and their post/guide on rooting the Infinix Hot 11, that I used originally.
Addendum​
Using fastboot with MediaTek SoCs will be a bit of a pain as their driver availibilty is limited, if it doesn't get installed by Windows automatically, you have a few options:
Grab the Google's Pixel driver, and install it in realtime during fastboot.
Try to install the VCOM driver from a source you trust.
For grabbing the Google one, you'll have to:
Extract the driver somewhere easy to access.
Open Windows' Device Manager.
Plug in your phone during fastboot to your Windows PC.
Replace the "Unknown" entry for your phone with the Google driver in device manager, within the 60 second window it stays open in.
Note that you'll have to do this every time you go into fastboot.

Categories

Resources