Red Magic 5G Bootloader Unlock Guide: OR get ROOT & TWRP without unlocking the BL!!! - Nubia Red Magic 5G / 5S Guides, News, & Discussion

Red Magic 5G Bootloader Unlock Guide: OR get ROOT & TWRP without unlocking the BL!!!
***Bootloader Unlock Instructions for the Nubia Redmagic 5G + installing TWRP:***
WARNING: ANY BOOTLOADER UNLOCK METHOD INVOLVES THE RISK OF BRICKING YOUR DEVICE PERMANENTLY. WHILE THERE IS USUALLY A WAY TO RECOVER, DO NOT ATTEMPT THIS PROCEDURE IF YOU DO NOT KNOW WHAT YOU ARE DOING. BAD THINGS CAN HAPPEN. YOU HAVE BEEN WARNED!!! YOU MAY BE LEFT WITH A USELESS BRICK!!! READ ALL FURTHER WARNINGS EXPERIMENTAL METHOD IN ORIGINAL DOWNLOAD FILE WORKS, I'M USING IT
If you want a NOOB guide look at this post: https://forum.xda-developers.com/nu...beginner-tutorial-unlock-bootloader-t4131585/
Also note a user has managed to fix the FP sensor post BL unlock, see this post here: https://forum.xda-developers.com/nu.../guide-calibration-finger-print-loss-t4132961
Still, I suggest root bypass it's better.
MegaNZ Link for Root without unlocking the Bootloader, and without breaking the FP, also includes instructions for installing BlackMagic5G (explanation below), adding HD VOLTE, how to restore from a brick, and some other cool tricks: https://mega.nz/file/igphSCTD#OybJo9t1zwvJ0bdbAcN2BCqxWXAfHdhk3JFB4_5xkVc
I suggest you flash my BlackMagic5G and don't unlock your bootloader at all - just root. It's CN 2.52 ROM based. You'll get VOLTE, , GApps installed, Rooted with Magisk, TWRP, debloated, YouTube Vanced, AdAway, SmartPack Kernel Manager, etc. - looks like the Global / NA variant of the ROM. Almost perfect except still uses Messages and Phone from Nubia. Plus you will enable Face Unlock not available in the Global or NA versions of the ROM, and FP will still work! Click on the Google Search bar widget and the mic icon takes you to the Google Assistant, the left icon is Google Feed, type in the middle bar for a Google Search. Has 1Weather Free weather widget that looks great, and Google Calendar widget for your whole month of activities. Translate, Lens, Chrome, all the Google Apps are there. And the Chinese Nubia apps are nearly all GONE!
MegaNZ Link for BlackMagic5G Beta - IT'S ONLY THE DATA PARTITION + ROOTED KERNEL + NA SPLASH SCREEN, you NEED to 1) install the Red Magic 2.52 ROM below FIRST 2) Root using the first link posted above 3) Flash restore this from TWRP: https://mega.nz/file/r9hF2BwS#RrAXiFWSBNX8dLqfrH8nNHo_uigPC8uYXonwhALhGbo
MegaNZ Link for the Red Magic 5G CN 2.52 ROM: https://mega.nz/file/aoxBFAqY#EDt2OZBGTME4ZGKnERKpK_t-aJT_rWgD0aqBFkilRcY
*** NOW THE BOOTLOADER UNLOCK INSTRUCTIONS ***
Go to Settings / About phone / Build Number (NX659_J_ENCommon_V3.08 on North American Variant), click 7 times, Now you are a developer message appears, go back a menu to Settings / Other system settings / Developer options.
Enable:
OEM unlocking "Allow the bootloader to be unlocked"
USB debugging "Debug mode when USB is connected"
Install Minimal ADB and Fastboot (Windows 10 in this example): https://www.androidfilehost.com/?fid=746010030569952951
Default install path is:
C:\Program Files (x86)\Minimal ADB and Fastboot\
Go to the Search button on the bottom on Windows 10, type cmd, Command Prompt will appear in the menu. Right click it and Run as Administrator. All commands to be typed will be run in this Command Prompt window (referred to as terminal) unless otherwise stated to run on the phone.
Now Terminal window appears (it says Administrator: Command Prompt in the heading):
Text displayed is:
Microsoft Windows
(c) 2020 Microsoft Corporation. All rights reserved.
C:\WINDOWS\system32>
Typed in terminal:
cd "c:\Program Files (x86)\Minimal ADB and Fastboot"
I now connected the phone to a USB port on the PC.
On the phone, a Window appeared:
"Allow USB debugging?"
The computer's RSA key fingerprint is:
[36 digit code] Example:
C8:A17:E2:01:F6:A1
:368:10:E8:33:20:FB:
93:7D
Always allow from this computer (it's my computer so I clicked it since I trust the computer)
CANCEL / ALLOW (I clicked ALLOW)
Typed in terminal:
adb reboot bootloader
The phone reboots. Once the phone screen boots, in the center it says: Now you are in fastboot mode.
From the terminal I typed:
fastboot oem nubia_unlock NUBIA_NX659J
The terminal now displayed:
...
(bootloader) START update nubia fastboot unlock flag!!!
(bootloader) START set state to 1 ok!!!
In the terminal I typed:
fastboot flashing unlock *** DO NOT TYPE THIS IF YOU WANT TO KEEP A WORKING FP!!! READ TOP OF POST!!! AVOID THIS WITH THE EXPERIMENTAL METHOD OF ROOT WITH NO BL UNLOCK ***
Now a screen appeared on the phone with a big <!> red icon in the left corner. The rest in white text is a warning message. "By unlocking the bootloader, you will be able to install custom operating system on this phone. A custom OS is not subject to the same level of testing as the original OS, and can cause your phone and installed applications to stop working properly-
Software integrity cannot be guaranteed with a custom OS, so any data stored on the phone while the bootloader is unlocked may be at risk.
To prevent unauthorized access to your personal data, unlocking the bootloader will also delete all personal data on your phone.
Press the Volume keys to select whether to unlock the bootloader, then the Power Button to continue."
I selected UNLOCK BOOTLOADER and my device was completely erased. The factory OS loaded then. This process takes some time to complete.
Now the device rebooted with a warning message, and a big <!> yellow icon in the left corner.
"The boot loader is unlocked and software integrity cannot be guaranteed. Any data stored on the device may be available to attackers. Do not store any sensitive data on the device.
Visit this link on another device:
g.co/ABH"
Now the device reloads the firmware apparently and wipes all user data. Upon setting up the phone, the fingerprint display registration comes up and asked to place my finger on the back of the phone. There is no fingerprint sensor on the back of the Redmagic 5G! It is under the screen! So this step must be skipped. The ROM setup is corrupt or incomplete, a beta possibly. I setup the phone then went into Settings / Security to try to add a fingerprint. The button to add fingerprint then appears. Once I click the button, I get this error:
Loss of fingerprint calibration data
Loss of fingerprint calibration data was detected.
Currently unable to complete fingerprint entry,
please contact Nuia after-sales service via
4007006600
See the XDA post for recalibrating the FP: https://forum.xda-developers.com/nu.../guide-calibration-finger-print-loss-t4132961
ROOT FOR ALL DEVICES:
(These files are included in the tools download zip, Magisk 20.4 and MagiskManager-v7.5.1.apk, but this is the official source as updates post): Go to XDA and Download Magisk Manager and install the APK. Download the latest Magisk as well from the Manager. You can then reboot to Recovery (volume up + power, release the power button once the screen shows it loading, hold the volume up down until you see TWRP pop up). Flash Magisk from TWRP Install / Zip / sdcard / Magisk.zip reboot and you'll have root.
BL unlock first method was tested on North American variant and it works. But it breaks your FP sensor and gives you an annoying boot prompt.
If at any time you want to remove the OEM Bootloader unlock, you plug into the PC, go to the terminal for Minimal ADB and Fastboot, type:
adb reboot fastboot
fastboot oem nubia_unlock NUBIA_NX659J
fastboot flashing lock (screen will prompt to relock BL, choose to Relock)
The phone should reboot and install the original software. BUT...
If it says you are corrupted well, you have more issues.
You'll have to reflash the stock recovery.img, reboot to stock recovery, wipe data, wipe cache, and flash the CN update.zip rom to a flash drive FORMATTED TO FAT32 (annoying as hell) But you NEED a USB-C to OTG Adapter to attach a Flash Drive / SDCARD this way). If you don't have one, you better reflash TWRP using the prior instructions and flash the update.zip from there. Install, select the update.zip, flash. Wipe Data, Cache, ART/Dalvik. Reboot.
Now it should WIPE the entire phone and be back to normal Android 10 setup non rooted, no unlocked bootloader. Always beware of data loss doing root functions!!! Always be prepared to setup your phone entirely over again. Google Backup is very good to turn on before you do any of this stuff if you have already installed apps.
*** WARNING - THIS BYPASS METHOD COULD GO AWAY AT ANYTIME. IT SHOULD EVENTUALLY BE FIXED BY NUBIA ***

mslezak said:
{Mod edit}
***Bootloader Unlock Instructions for the Nubia Redmagic 5G + installing TWRP:***
Settings / About phone / Build # click 7 times, now your a dev message appears, good back a menu, go to Additional Settings / Developer Options
Enable:
ADB debugging, + OEM unlock
Connect phone to PC, approve device on phone RSA key for USB debugging
From Minimal ADB and Fastboot:
adb reboot bootlader
fastboot oem nubia_unlock NUBIA_NX659J
fastboot flashing unlock
(approve on phone with volume keys to unlock and hit the power button, now you'll get an annoyng mesage on boot as insecure unlocked BL) *ALL YOUR DATA WILL BE WIPED*
Next:
fastboot flash recovery recovery-TWRP-3.4.1B-0324-NUBIA_REDMAGIC_5G-CN-wzsx150.img
fastboot reboot recovery
Enter TWRP, set to not be removed by updates if prompted.
Boot up the device, setup as a new device. You're on stock ROM / kernel now unlocked.
Once you get up and running you'll want APK Mirror app to install stuff on the China Variant it's in the Nubia Playstore. Gboard download as well and set as default it's a lot easier than the Chinese keyboard that swaps between Chinese and English. Set size extra tall for this huge phone (I prefer anyhow). Chrome go download it from APK Mirror app as well. Then go to XDA and Download Magisk Manager and download it and install the APK. Download the latest Magisk as well from the Manager. You can then reboot to Recovery (volume up + power). Flash Magisk from TWRP reboot and you'll have root.
Note on my testing the fingerprint did not work after unlocking the bootloader. It says to contact Nubia support at some odd number. Hopefully they fix this.
Click to expand...
Click to collapse
You were able to actually install TWRP? Not just boot it? I thought A10 devices cant have twrp permanently installed?

That is a very good question my friend. I had to reflash it several times while rooting so it appears you are correct.
Now a window when I FIRST installed popped up and said make Recovery read only so a system update. can't overwrite it, to this I didn't even pay attention. So assuming that question does lock down recovery, it should stick.

mslezak said:
That is a very good question my friend. I had to reflash it several times while rooting so it appears you are correct.
Now a window when I FIRST installed popped up and said make Recovery read only so a system update. can't overwrite it, to this I didn't even pay attention. So assuming that question does lock down recovery, it should stick.
Click to expand...
Click to collapse
So its not permanent? Thats what I thought.

Well it could be permanent...
VZTech said:
So its not permanent? Thats what I thought.
Click to expand...
Click to collapse
What I was trying to say is that I've never had a phone where I had to select "prevent recovery from being overwritten" so I just clicked off the message. Had I selected "keep TWRP from being overwritten" then possibly it sticks. It's just a matter of making the recovery partition READ ONLY.

mslezak said:
What I was trying to say is that I've never had a phone where I had to select "prevent recovery from being overwritten" so I just clicked off the message. Had I selected "keep TWRP from being overwritten" then possibly it sticks. It's just a matter of making the recovery partition READ ONLY.
Click to expand...
Click to collapse
The issue with that could be any future updates though. Rm uses there own recovery for that. They don't provide fastboot images either I believe

Can anyone send me backup of the super partition?
I accidentally flashed an image to the super partition with twrp thinking it was the system partition (it technically is tho) and it bricked my phone and messed up twrp.
Only stock recovery works but the stock recovery cannot fix it by installing a full ota from a otg drive.
I do have a backup on my phone but it is inaccessable.
Could anyone please send me a backup of the super partition or have any idea on how to fix this?
(I tried to use edl and backup my data to recover my backup of the super partition but it seemed like it needed a programmer binary from qualcomm)

Future updates...
VZTech said:
The issue with that could be any future updates though. Rm uses there own recovery for that. They don't provide fastboot images either I believe
Click to expand...
Click to collapse
Yes what I've been told by prior Redmagic Users 3 and 3S is the ROM is released, as long as your boot.img is not patched with Magisk, it can be installed through the menus in Settings / About Phone / Update or someplace like that. You just download the ROM to the appropriate folder on the phone.
So far I have 1 link to a China ROM update here: https://ui.nubia.cn/rom/detail/65
Now on how to install the ROM, I use the Chrome browser set to autotranslate webpages. Most of the Chinese will be translated from here: https://bbs.nubia.com//thread-1136030-1-1.html
Basically it's going to wipe your device clean, and you can use a Nubia backup tool which will save all your items to a folder. Which then you should copy to your PC before installing the new ROM. Then it gives you instructions to get that data back onto your updated device.

apersomany said:
I accidentally flashed an image to the super partition with twrp thinking it was the system partition (it technically is tho) and it bricked my phone and messed up twrp.
Only stock recovery works but the stock recovery cannot fix it by installing a full ota from a otg drive.
I do have a backup on my phone but it is inaccessable.
Could anyone please send me a backup of the super partition or have any idea on how to fix this?
(I tried to use edl and backup my data to recover my backup of the super partition but it seemed like it needed a programmer binary from qualcomm)
Click to expand...
Click to collapse
Your probably screwed. I had this issue on a rm3s. You will need an unbrick tool. It was released for the rm3s about 4 mos after release. NUBIA should have true fastboot images available for download, but they dont.

VZTech said:
Your probably screwed. I had this issue on a rm3s. You will need an unbrick tool. It was released for the rm3s about 4 mos after release. NUBIA should have true fastboot images available for download, but they dont.
Click to expand...
Click to collapse
That's because of the super (dynamic) partition, see from the latest (and only) ROM:
Excerpt of the ROM installation script where it delineates the dynamic vs non dynamic partitions - you have product w/ a file transfer list, then vendor, system, and odm, The other files (boot.img, dtbo.img, splash.img, etc. and other various files) should be flashable with fastboot.
# Update dynamic partition metadata
assert(update_dynamic_partitions(package_extract_file("dynamic_partitions_op_list")));
unmap_partition("product");
block_image_update(map_partition("product"), package_extract_file("product.transfer.list"), "product.new.dat.br", "product.patch.dat");
unmap_partition("vendor");
block_image_update(map_partition("vendor"), package_extract_file("vendor.transfer.list"), "vendor.new.dat.br", "vendor.patch.dat");
unmap_partition("system");
block_image_update(map_partition("system"), package_extract_file("system.transfer.list"), "system.new.dat.br", "system.patch.dat");
unmap_partition("odm");
block_image_update(map_partition("odm"), package_extract_file("odm.transfer.list"), "odm.new.dat.br", "odm.patch.dat");
# --- End patching dynamic partitions ---

apersomany said:
I accidentally flashed an image to the super partition with twrp thinking it was the system partition (it technically is tho) and it bricked my phone and messed up twrp.
Only stock recovery works but the stock recovery cannot fix it by installing a full ota from a otg drive.
I do have a backup on my phone but it is inaccessable.
Could anyone please send me a backup of the super partition or have any idea on how to fix this?
(I tried to use edl and backup my data to recover my backup of the super partition but it seemed like it needed a programmer binary from qualcomm)
Click to expand...
Click to collapse
You should be able to flash the latest ROM via EDL mode if you've ever used EDL mode before, it usually requires shorting pins together in the device, although some recoveries will let you just boot into EDL mode if the phone still boots. It will be detected. Although on this device with the dynamic partition, I don't know how you would flash these in EDL mode... dynamic partitions - you have product w/ a file transfer list, then vendor, system, and odm that do not look like fastboot flashable parts. Possibly the unbrick tool for Redmagic 3/3S could be modified to do this for you.

mslezak said:
That's because of the super (dynamic) partition, see from the latest (and only) ROM:
Excerpt of the ROM installation script where it delineates the dynamic vs non dynamic partitions - you have product w/ a file transfer list, then vendor, system, and odm, The other files (boot.img, dtbo.img, splash.img, etc. and other various files) should be flashable with fastboot.
# Update dynamic partition metadata
assert(update_dynamic_partitions(package_extract_file("dynamic_partitions_op_list")));
unmap_partition("product");
block_image_update(map_partition("product"), package_extract_file("product.transfer.list"), "product.new.dat.br", "product.patch.dat");
unmap_partition("vendor");
block_image_update(map_partition("vendor"), package_extract_file("vendor.transfer.list"), "vendor.new.dat.br", "vendor.patch.dat");
unmap_partition("system");
block_image_update(map_partition("system"), package_extract_file("system.transfer.list"), "system.new.dat.br", "system.patch.dat");
unmap_partition("odm");
block_image_update(map_partition("odm"), package_extract_file("odm.transfer.list"), "odm.new.dat.br", "odm.patch.dat");
# --- End patching dynamic partitions ---
Click to expand...
Click to collapse
Yes those .img files can easily be fastboot flashed. Unfortunately it wont solve his problem. He needs the nubia unbrick tool, which is tough to get. I dont understand why Nubia makes things difficult. They should provide proper Fastboot files.

I already tried edl (not to flash, but to recover my backup of the super partition) but it seems like it needed a firehose binary. I still can use bootloader, fastbootd, recovery. It's just that the recovery fails at assert dynamic partition update thing with a error 7 (probably because my super partition turned into a normal partiton). I tried to flash a super empty image made with lpmake and try flashing the ota but that didn't work. I think if someone gives me a backup of the super partition I could flash that and that could work. I also had an idea of flashing a super partition of another devices factory image to make my super partition a dynamic partition, but I couldn't find any online.

apersomany said:
I already tried edl (not to flash, but to recover my backup of the super partition) but it seems like it needed a firehose binary. I still can use bootloader, fastbootd, recovery. It's just that the recovery fails at assert dynamic partition update thing with a error 7 (probably because my super partition turned into a normal partiton). I tried to flash a super empty image made with lpmake and try flashing the ota but that didn't work. I think if someone gives me a backup of the super partition I could flash that and that could work. I also had an idea of flashing a super partition of another devices factory image to make my super partition a dynamic partition, but I couldn't find any online.
Click to expand...
Click to collapse
I get a Global Device on Monday. I'll try to use Qualcomm tools to make a brick restore image of Global. If I get one made I'll post all the tools to restore the device on Mega.nz. Because of the super partition it has to be done this way. Not via TWRP as you know. I'm working on Dev tools for this device as fast as possible.

mslezak said:
I get a Global Device on Monday. I'll try to use Qualcomm tools to make a brick restore image of Global. If I get one made I'll post all the tools to restore the device on Mega.nz. Because of the super partition it has to be done this way. Not via TWRP as you know. I'm working on Dev tools for this device as fast as possible.
Click to expand...
Click to collapse
Thank you so much!

Okay I can't add anything special but daaamn this community is amazing. So much help I love you all

To relock BL repeat the instructions with 1 different command
Just replace
fastboot flashing unlock
with
fastboot flashing lock
Again you approve to lock on the phone prompt with the volume keys and your phone will be wiped and all will be back to normal, you'll be locked. And back to phone setup.
I'd edit the original post but the moderators took away my rights!!! Because I posted a Telegram link WHY - how do you expect development to get better???
BTW anyone with a NEW phone arriving that can record the FP failures and all errors please contact me so I can send to Nubia. They are waiting for me to reproduce the error but I already setup my new phone... Thinking I wouldn't be the ONLY ONE to contact [email protected] ... Guys you want developer support on this phone or not. Contribute please.
mslezak said:
{Mod edit}
***Bootloader Unlock Instructions for the Nubia Redmagic 5G + installing TWRP:***
Settings / About phone / Build # click 7 times, now your a dev message appears, good back a menu, go to Additional Settings / Developer Options
Enable:
ADB debugging, + OEM unlock
Connect phone to PC, approve device on phone RSA key for USB debugging
From Minimal ADB and Fastboot:
adb reboot bootlader
fastboot oem nubia_unlock NUBIA_NX659J
fastboot flashing unlock
(approve on phone with volume keys to unlock and hit the power button, now you'll get an annoyng mesage on boot as insecure unlocked BL) *ALL YOUR DATA WILL BE WIPED*
Next:
fastboot flash recovery recovery-TWRP-3.4.1B-0324-NUBIA_REDMAGIC_5G-CN-wzsx150.img
fastboot reboot recovery
Enter TWRP, set to not be removed by updates if prompted.
Boot up the device, setup as a new device. You're on stock ROM / kernel now unlocked.
Once you get up and running you'll want APK Mirror app to install stuff on the China Variant it's in the Nubia Playstore. Gboard download as well and set as default it's a lot easier than the Chinese keyboard that swaps between Chinese and English. Set size extra tall for this huge phone (I prefer anyhow). Chrome go download it from APK Mirror app as well. Then go to XDA and Download Magisk Manager and download it and install the APK. Download the latest Magisk as well from the Manager. You can then reboot to Recovery (volume up + power). Flash Magisk from TWRP reboot and you'll have root.
Note on my testing the fingerprint did not work after unlocking the bootloader. It says to contact Nubia support at some odd number. Hopefully they fix this.
Click to expand...
Click to collapse

Just in case if somebody need a Chinese version of official ROM v2.46 for RedMagic 5G.
Code:
https://mega.nz/file/vc0DiabR#npahTop-JXZ9Mwv-lA7G6DxTG2qqOOAf6AwW8NdEEKw

mslezak said:
Just replace
fastboot flashing unlock
with
fastboot flashing lock
Again you approve to lock on the phone prompt with the volume keys and your phone will be wiped and all will be back to normal, you'll be locked. And back to phone setup.
I'd edit the original post but the moderators took away my rights!!! Because I posted a Telegram link WHY - how do you expect development to get better???
BTW anyone with a NEW phone arriving that can record the FP failures and all errors please contact me so I can send to Nubia. They are waiting for me to reproduce the error but I already setup my new phone... Thinking I wouldn't be the ONLY ONE to contact [email protected] ... Guys you want developer support on this phone or not. Contribute please.
Click to expand...
Click to collapse
we found out that using the cn rom it all works without even unlocking the bootloader, even while oem unlock was disabled in dev options but there is some kind of vbmeta img required. a full guide is incoming.

VZTech said:
The issue with that could be any future updates though. Rm uses there own recovery for that. They don't provide fastboot images either I believe
Click to expand...
Click to collapse
You can flash their NX659J-update.zip files directly from TWRP that's how we restored our bricked devices already. So OTA updates no, but you can download them anyway and flash from TWRP directly. Yes we have to figure out a concrete restore method which isn't 100% working yet. I.e. all your data is lost this way apparently AT THIS MOMENT... MORE TO COME.

Related

[Guide] Stock MIUI (7/8): Official unlock, recovery, root, xposed, DPI & debloat

Please read this thread thoroughly and carefully. Do this at your own risk. The following had worked for two of the same devices. I've made this guide partly for my own notes and because other guides out there seemed incomplete.
Aim of this guide is to have an unlocked bootloader with a custom recovery for flashing root, Xposed and other things while possibly preserving the ability to get official OTA updates. The following is a summary of what this guide entails.
Official Mi FlashUnlock was used to unlock the bootloader. It will take 3-4 days before Xiaomi grants unlock permission on your account. This guide does not touch the emmc for unlocking since that method causes -2% or 50% battery bug. This is the same bug that most CM flashers are running into. In the meantime, prepare your computer and phone for when you do get permission.
Recovery TWRP Alka is a good recovery to use since it's already patched (boot.img) so that it can flash MIUI recovery ROMs (OTA) as well as CM based ROMs. It also has the ability to backup the entire phone (EFS partition). I would strongly suggest backing up all partitions and moving it to your computer or SD card after. You may choose Cofface TWRP if you're never going to try CM based ROMs. Helpful links from other guides will be posted at the end. I have yet to receive an OTA update yet so this part is not tested.
Root, Xposed and DPI instructions are all outlined below. Flash and configure these as you normally would.
Debloating is a big thing that I do to stock ROMs. This essentially prevents the ROM from running the apps, slimming the ROM and hopefully extending daily usage. There are few things that broke though. The only thing I could care about is that I'm not able to change the wallpaper via the Settings (lockscreen + homescreen) anymore. However, the rest that broke were the features that I don't use such as Cleaner (sponsored by Cheetah), dual apps and etc. Debloat accordingly. Be cautious, as I won't be necessarily explaining what each item does. ​
OTA updates does work. However, recovery, root, DPI, Xposed and debloat all needed to be done again.
Prep work
Sign up and login to all the neccessary accounts
Sign up for unlock: http://en.MIUI.com/unlock/, this will take 3-4 days.
Make sure you're also signed into your Mi account on your phone and that you can find your phone at http://i.mi.com/.
Prepare your computer for drivers and software
Enable Windows TESTSIGNING first: https://msdn.microsoft.com/en-us/library/windows/hardware/ff553484(v=vs.85).aspx
The TESTSIGNING boot configuration option is enabled or disabled through the BCDEdit command. To enable test-signing, use the following BCDEdit command:
Bcdedit.exe -set TESTSIGNING ON
To disable test-signing, use the following BCDEdit command:
Bcdedit.exe -set TESTSIGNING OFF​Restart your computer and then install the following:
Mi PC Suite (http://pcsuite.mi.com/)
Mi ROM Flashing Tool and drivers for fastboot & ADB (http://en.MIUI.com/a-234.html)
Mi FlashUnlock tool (http://en.MIUI.com/thread-202290-1-1.html)
Fastboot EDL, just in case (http://forum.xda-developers.com/redmi-note-3/how-to/guide-reboot-to-edl-mode-fastboot-test-t3398718)
Prepare your device
Enable developer mode by going to Settings > About phone > Tap on MIUI Version repeatedly until you get a toast that Developer Mode is enabled
Go back to Settings and then tap on Additional Settings > Developer options
Enable Developer options
Enable OEM unlock
Enable USB debugging
Plugin your phone into your computer, it should now install all the drivers
Turn TESTSIGNING OFF and restart your computer
Signs of computer recoginizing your phone properly (for ADB, Fastboot and etc)
In Device Manager, you should see under Android Phone: Android Composite ADB Interface and Xiaomi Composite MDB Interface
You phone should have also asked you to allow debugging from your computer (check always allow)
Unlocking your phone
Log in from time to time to check your unlock permission from the MiFlash Unlock Tool. You'll just need to follow the instructions to unlock your bootloader.
Boot into fastboot by holding volume-down + power
Run MiFlash Unlock and follow the onscreen instructions
If you're curious to see if it's unlocked, boot back into fastboot and type fastboot oem device-info
Using MiFlash tool to flash another MIUI ROM (China to Global, skip if you already like your MIUI version)
Boot into fastboot by holding volume-down + power, you will get the fastboot bunny
Download your desired fastboot version: http://en.MIUI.com/a-234.html, you can check the changelog and description from here: http://en.MIUI.com/download-301.html
Or you can use MIUI 8 Global Beta: http://forum.xda-developers.com/redmi-note-3/development/MIUI-8-global-beta-redmi-note-3-t3417423
Extract the fastboot ROM (.tgz) twice, the first extract you'll be left with .tar file, the second should leave you with a directory of files
Place that directory in the root of your drive (or somewhere with a short location)
Launch the MiFlash tool, browse to your extracted fastboot ROM and click on refresh. You should now also see your device listed
Click on Flash All and click on refresh once more
Now flash your device, it should take upwards of 170s
Let your device boot, which should take 5m or longer. Set it up as you normally would and redo all the steps outlined in the "Prepare your device" section (don't need the TESTSIGNING part).
Flashing TWRP (Alka) & Root
Download the following files:
TWRP https://dl.twrp.me/kenzo/
Alka http://www.mediafire.com/download/febttn8piu0vfae/recovery+Alka+Update.zip
Universal Boot Img Patcher http://forum.xda-developers.com/redmi-note-3/how-to/modified-twrp-deleting-emmcappsboot-t3371667
SuperSU https://download.chainfire.eu/969/SuperSU/
You should now be working in an administrator command prompt in this directory: C:\Program Files (x86)\Xiaomi\MiPhone\Google\Android. Take this chance to extract fastboot-edl into this same directory. Also place twrp and alkarecoveryupdate img files into this directory. You should have the Universal Boot Img Patcher and SuperSU copied to your phone.
Follow these, don't reboot in between unless stated:
Enter fastboot (volume-down + power)
Type fastboot boot twrp.img
Swipe to allow modifications
Flash universal boot img patcher zip
Flash twrp.img by selecting "Select Image" option.
Select recovery partition & flash it
For some reason twrp has to be flashed this way or else recovery will be reverted to stock MIUI recovery. You can try Alka directly to see if it works for you.
Now reboot to recovery
Flash alkarecoveryupdate.img by selecting "Select Image" option.
Select recovery partition & flash it
Reboot to recovery
Flash SuperSU
Reboot system and let it boot MIUI, it may take longer than usual
You should now test root, configure SuperSU & install Busybox.
Flashing Xposed
Download the latest SolarWarez Xposed: http://forum.xda-developers.com/xposed/unofficial-xposed-MIUI-t3367634
Download Material Xposed Installer: http://forum.xda-developers.com/xposed/material-design-xposed-installer-t3137758
Download Xposed uninstaller, just in case: http://forum.xda-developers.com/showthread.php?t=3034811
A few posts suggests that the latest official Xposed v86 works with MIUI, but doesn't seem to be the case for me.
Install the Xposed Installer of your choice (apk install)
Enter recovery (volume-up + power)
Flash v86-sdk22-arm64 (LP, sdk23 is for MM)
Clear cache and dalvik
Reboot the phone, this should take 5m or longer since we wiped the cache
If you notice bootloops or crashing services, use the uninstaller. Worst case, flash it back to stock using MiFlash.
Xposed modules that I use:
App Settings
MIUI Brightness Fix
Mobile Radio Active Fix
Power Nap
Play Store Fixes
Spotify Skip
TextLinkify
WhatsApp Tuner
xMIUI
xInsta unfortunately does not work well.
Changing DPI
Using FX Explorer (Root access enabled) or any explorer you feel fit.
Go to system/ and edit build.prop
Add this line in between persist.hwc.downscale_threshold=1.15 & #ro.hdmi.enable=true
ro.sf.lcd_density=370​
Reboot your phone
You should be able to use a DPI changer such as texdrodier_dpi to change it to whatever you like after
ROM Debloating, should get around 1.8GB of free memory on boot
Using FX Explorer (Root access enabled) or any explorer you feel fit.
Create the backup location:
Create a folder in system named _backup
Create subfolders named app, data-app, priv, vendor
Debloat app folder as you wish but here's my list:
Go to system/app
Cut the following into system/_backup/app
AGPSTestMode
AmapITS
AnalyticsCore
AntHalService
BasicDreams
BrowserProviderProxy
BugReport
CalendarLocalAccount
CalendarWidget
CloudService
Drive
Email
FileExplorer
FM
Galaxy4
GuardProvider
HTMLViewer
HiddTestApp
HoloSpiralWallpaper
KSICibaEngine
KingSoftCleaner
LatinImeGoogle
LiveWallpapers
LiveWallpapersPicker
LunarInfoProvider
MiDiscover
MiLivetalk
MiuiVideoPlayer
MiWallpaper
MSDC_UI
NoiseField
Notes
OmaDownload
OmaDrmEngineApp
PartnerBookmarksProvider
PhaseBeam
PhotoTable
QtiBackupAgent
QtiFeedback
SampleAuthenticatorService
SapClientApp
SecureSampleAuthService
SoundRecorder
SecProtect
StaProxyService
StepsProvider
Stk
SystemAdSolution
TouchAssistant
TranslationService
Videos
VisualizationWallpapers
WAPPushManager
WfdClient
xdivert
fastdormancy
imstests
jjcontainer
jjhome
jjknowledge
jjstore
Go to system/data-app
Cut the following into system/_backup/data-app
Facebook
klobugreport
Go to system/priv
Cut the following into system/_backup/priv
AndroidForWork
AutoTest
BackupRestoreConfirmation
Browser
Calendar
CleanMaster
FM2
GoogleBackupTransport
GoogleFeedback
Mipub
Music
MusicFX
SpacesManagerService
SpacesTrustAgent
Velvet
xtra_t_app
Go to system/vendor
Cut the following into system/_backup/vendor
CTA
ChinaMobile
ChinaTelecom
ChinaUnicom
CmccPower
MPCS
app
Helpful posts if you have other issues
Flashing to CM: http://forum.xda-developers.com/redmi-note-3/how-to/guide-step-step-guide-flash-cm13-build-t3391839
TWRP Explained: http://forum.xda-developers.com/redmi-note-3/how-to/guide-redmi-note-3-available-twrps-t3406708
Fastboot EDL for softbricked phones: http://forum.xda-developers.com/redmi-note-3/how-to/guide-reboot-to-edl-mode-fastboot-test-t3398718
IMEI Repair: http://en.MIUI.com/thread-245598-1-1.html
MIUI Unlock guide: http://en.MIUI.com/thread-202290-1-1.html
If using alka twrp and officially unlocked the bootloader, universal boot image patcher was not necessary for flashing any official miui rom.
Sent from my Redmi Note 3 using Tapatalk
timberwolf60 said:
If using alka twrp and officially unlocked the bootloader, universal boot image patcher was not necessary for flashing any official miui rom.
Sent from my Redmi Note 3 using Tapatalk
Click to expand...
Click to collapse
i had to do what i did because the recovery wouldn't stay flashed. alka has the boot image built in anyways, so really it's the same thing.
I think DPI should be ro.sf.lcd ? you've written ro.sf.ldc??? Is that correct?
rayulove69 said:
I think DPI should be ro.sf.lcd ? you've written ro.sf.ldc??? Is that correct?
Click to expand...
Click to collapse
fixed. typo
What if i directly boot and flash alka recovery?
What if i directly boot or flash alka recovery? instead of first flashing twrp official and then flashing alka through it
RavdeepAurora said:
What if i directly boot or flash alka recovery? instead of first flashing twrp official and then flashing alka through it
Click to expand...
Click to collapse
try it. like i said in my post, i had to do what i did or else alka wouldn't stay flashed. if it stays flashed for you then great, you've saved 5 steps.
The only thing I could care about is that I'm not able to change the wallpaper via the Settings (lockscreen + homescreen) anymore
Click to expand...
Click to collapse
For what it's worth, I haven't done anything yet aside from bootloader, MIUI 8 and install nova launcher; the wallpaper/lock screen error only happens when I've got nova set as default. When I go back to the stock launcher, I can change both without error. Then I set nova back to default, I can still change wall/lock until I actually restart the phone.
So hopefully that might give you an idea as to what's going on and maybe it'll help.
Do appreciate the guide, something I'll have to do eventually when CM13 works out the kinks.
Thanks the dpi edit works great.
capitak said:
For what it's worth, I haven't done anything yet aside from bootloader, MIUI 8 and install nova launcher; the wallpaper/lock screen error only happens when I've got nova set as default. When I go back to the stock launcher, I can change both without error. Then I set nova back to default, I can still change wall/lock until I actually restart the phone.
So hopefully that might give you an idea as to what's going on and maybe it'll help.
Do appreciate the guide, something I'll have to do eventually when CM13 works out the kinks.
Click to expand...
Click to collapse
Thanks! Good to know it wasn't from the debloating.
I just want to have "write access" to my MicroSD card, so I plan to unlock/root my device.
If I follow the guide just to unlock, is all my personal data/setting/profiles/installed apps still be there after unlock?
Pls advice.
Just waiting on my RN3 to arrive, so this post is perfect timing.
I'll report back once I've followed your steps.
should i install SolarWarez Xposed and Material Xposed Installer or just one of them?
same240 said:
I just want to have "write access" to my MicroSD card, so I plan to unlock/root my device.
If I follow the guide just to unlock, is all my personal data/setting/profiles/installed apps still be there after unlock?
Pls advice.
Click to expand...
Click to collapse
Don't know. Unlocking bootloader usually wipes the device.
doganmanis said:
should i install SolarWarez Xposed and Material Xposed Installer or just one of them?
Click to expand...
Click to collapse
You need both, as usual.
I'm getting this problem in cmd prep work
Bcdedit.exe -set TESTSIGNING ON
AN error has occured setting the element data.
The value is protected by Secure Boot policy and cannot be modified or deleted.
RexMi6 said:
I'm getting this problem in cmd prep work
Bcdedit.exe -set TESTSIGNING ON
AN error has occured setting the element data.
The value is protected by Secure Boot policy and cannot be modified or deleted.
Click to expand...
Click to collapse
You may need to disable driver signing instead. Google that for your windows 8 or 10 machine. My method ensures it's disabled.
I used your guide.
Thank you!
everything is working, on stable-globe rom.
I'm using Titanium backup to uninstall system apps
I'm using the official MIUI Global Stable 7.5.3.0 and have unlocked the bootloader using the official way as well. I just now installed alka recovery directly using fastboot commands and it seems to work fine. It's still there after rebooting a couple of times and I already took a full backup of the phone. Haven't tried restoring it yet, which I will probably do later and post the results, but I guess that will work as well.
Edit: I tried to restore a backup just now, but I got an error when it tried to restore the firmware partition. The error was "extractTarFork() process ended with error : 255" if I'm not mistaken. Still everything seems to be working fine regardless of that error.
Thanks !!! Amazing post!!! Helped me a lot !
I have a Note 3 Pro , couldn't unlock the Phone with Global Version (even with permission) always stoping in 50%, tried to change to Chinese Version, but I couldn't, so I tested with Global Developer Version (Miui 8) and I got the unlock
I'm doing same process you said after unlocking boot loader officially. I'm trying to flash mokee rom and open gapps pico arm 64. After booting rom is crashing saying com.android.phone is stopped and when i check for oem device info it is locked. plz help where am I going wrong

[GUIDE] All-In-One noob friendly guide for xperia X (Root/Bootloader/Rom)

[UPDATE]: USE THIS ONLY FOR NOUGAT 7 OR 7.1! THERE IS A DIFFERENT GUIDE FOR ANDROID OREO!
https://forum.xda-developers.com/xperia-x/how-to/root-xperia-x-f5122-android-n-34-2-2-47-t3594502 (Written by YasuHamed, not me!)
If you are not interested in android Oreo, or you want to go back to Nougat, this guide is still valid! [End of Update]
This is a guide for newbies or for people that are simply confused. If you have any questions, you can always ask me, and I will reply. but please make sure you haven't made mistakes and do not ask about things that are already stated here. Let's go!
BEFORE DOING ANYTHING, NOTES
-make sure you have installed ADB : https://forum.xda-developers.com/showthread.php?t=2588979
-make sure ADB can read your phone with the correct drivers installed. If you have trouble with that, read "DRIVERS" section
!It is absolutely necessary to install the drivers correctly!
-Backup your stuff if you have any, you will need to delete everything from the phone
-Enable USB debugging
-Note: some of these instructions apply to Windows OS only!
-Note: links to downloads have been shortcutted as much possible to make it easier for you!
-Find some stock roms here! https://forum.xda-developers.com/xperia-x/how-to/sonyx-f5121-downgrade-8-0-0-to-7-1-1-to-t3754986
(Credit: HEKER510)
-Warning: you will lose your warranty!
-I am not responsible for any damage done to your device.
BACKUP DRM KEYS (OR WORKAROUND)
You may want to unlock your bootloader. If you unlock it without backing up the DRM keys, you will lose them. I did that mistake and I regret it. If you already did, there is an alternative solution, skip to step 8.
1) If you are running android 7 nougat, you will need to downgrade to MM. If you are running MM, skip to step 7.
2) You will need to wipe everything before rolling back, so if you have any data back it up
3) Download any stock MM 6.0.1 firmware for the xperia X. You can find one here : https://mega.nz/#!1xRj2CYS Decryption key: !qBVi7yky8AL84eUF3bpTTGQ2YmN0ePCjc-eSDZGIZCI
Watch out: if you have the dual SIM model, F5122, you need to download accordingly!
For more firmwares, check "BEFORE DOING ANYTHING"
4) Download the latest flashtool: http://www.flashtool.net/downloads.php
Upon installation, tick on fastboot, flashmode drivers! If it didn't ask you, go to the installation folder and run Flashtool-drivers.exe. Please read "DRIVERS" section!
5) Flash the .tft file
How to flash?
0. Go to "C:\Users\[Your PC Name]\.flashTool\firmwares" , and put your firmware .ftf file in there!
1. Open Flashtool and click on the lightning bolt icon (first one from the left)
2. In the prompt, choose flashmode.
3. Under firmware, click on the version you put (It should probably only be one option)
4. Under wipe , tick everything. Under the others, do not make any changes.
5. Click "Flash"
6. When the popup appears, connect your device. It needs to be powered off, and connected while you are holding the
"volume down" button.
7. Wait for it to finish.
8. Done. Boot up the device, it might take some time to open so don't worry.
Click to expand...
Click to collapse
6)If your phone bootloops, try flashing again or a different firmware and make sure you followed the steps correctly.
7) Once your phone successfully boots android MM, use Dirtycow to get your DRM keys out: https://forum.xda-developers.com/crossdevice-dev/sony/universal-dirtycow-based-ta-backup-t3514236
8) If you unlocked the bootloader before backing up your keys, you can use DRM kernel fix. You can get it here: https://forum.xda-developers.com/xperia-x/development/kernel-drm-fix-nougat-t3530849 Before using it check out the custom rom that includes this fix and other things.
UNLOCK BOOTLOADER
This is relatively easy and you can follow official sony instructions to do it.
1) Go to your phone settings, developer options, and enable OEM unlock
"But there is no developer options!" -Go to the bottom of your settings, system, about phone, and tap multile times on "Build Number", also at the bottom.
Click to expand...
Click to collapse
2) If you haven't already , install ADB fastboot and configure drivers (Link on top )
3) Follow the steps on the Sony website to get your unlock code: https://developer.sonymobile.com/unlockbootloader/email-verification/
4) After unlocking, a warning message on boot is normal!
INSTALL RECOVERY
Installing TWRP on your xperia X is very important, since you can flash zips and img files so easily, plus wipe, backup and other features.
1) Download the TWRP .img file: https://androidfilehost.com/?w=files&flid=197369 (Credit: eagleeyetom )
2) Make sure you have USB debugging enabled
3) Open your downloaded twrp folder
4) Run CMD in that folder (shift + right click inside the folder, Open CMD here )
5) Connect your Xperia X to your PC
6) Type these lines:
adb reboot bootloader
fastboot flash recovery recovery.img [where recovery.img is your twrp file name]
fastboot reboot
7) If no errors, twrp is now installed. Once your phone boots , turn it off,. To access TWRP recovery hold power button and volume down button until the TWRP menu appears.
STOCK ROM, ROOT
If you just want to root and not interested in additional features and tweaks, you can simply flash SU through TWRP to get your phone rooted.
Note: Current best stock ROM available: 7.1.1 (252) - better features than older ver, and good battery life.
0) Install your desired stock firmware using the exact same previous instructions, (under DRM section) with flashtool.
1) Download SuperSu
Or magisk, using YasuHamed guide mentioned on top, but I have not tested with anything other than Oreo 8.0
Use magisk if you want more stability / root features (like hide root from apps, modules )
2) copy it anywhere on your phone
3) Run TWRP
4) Tap on install
4) Flash the file
5) Reboot, you are now rooted
6) Insert your DRM keys if you have them
Custom ROMS
After unlocking the bootloader and installing TWRP this is the best way to go in order to get full root, tweaks.
https://forum.xda-developers.com/xperia-x/development/rom-xperia-x-pexorom-v1-0-0-f5122-f5121-t3590552
^ This is a very good custom ROM made by prmk74. You can see its features in his thread.
1) Download the rom and copy it to your phone
2) Run TWRP
note: It is recommended to wipe dalvik, cache, data ( your storage partition doesn't need to be wiped)
3) Tap install, find your downloaded file and execute
note: It is recommended to wipe dalvik, cache, data ( your storage partition doesn't need to be wiped)
4) Follow on-screen instructions, do not stop the booting after finishing the installation, it will take some time
5) Insert your DRM keys if you have them
6) For those who lost their keys: Now the functions like vivid image mode are working properly.
DRIVERS
For Windows 8/8.1/10 users, how to solve driver problems:
1) Press the Windows key + R together and in the ‘Run’ box type: shutdown.exe /r /o /f /t 00
– Now make the following selections to boot into the Start Up Setting Screen: Troubleshoot > Advanced options > Start Up Settings > Restart
– Then, when the machine restarts, select number 7 i.e. “Disable driver signature enforcement”. Your machine will start with Driver signing enforcement disabled until the next reboot.
B) Now you can install the Flashtool drivers. Go to the flashtool install location and run the drivers.exe again, check fastboot and flashmode
– Windows will warn that the driver is not signed and will require you to confirm the installation.
– Once the installation is complete, reboot the machine
TO CONCLUDE:
This is what you may want to do to get the most out of your new xperia x:
1) Backup DRM
2) Unlock BL
3) Install TWRP
4) Flash Persian (or a different rom) through TWRP (And subscribe to the thread so you receive updates)
5) Restore DRM
Notes:
None of the links, tools are of my work, I'm just writing a guide for my fellow XX owners
^^ this guide is so really good :3. I post flash script for someone dont know how to find it ^^
unzip it in this position.
C:\Users\[user-name]\.flashTool\mydevices
max26292 said:
^^ this guide is so really good :3. I post flash script for someone dont know how to find it ^^
unzip it in this position.
C:\Users[user-name]\.flashTool\mydevices
Click to expand...
Click to collapse
Thanks!
Thanks for this, I need some help!
All was fine until I tried flashing the recovery, comes back "partition unknown" error. I was unable to bring the device up under an adb device only as a fastboot device.
34.0.A.1.264_R3A firmware.
Different official sony driver (Sony bootloader guide driver didn't work)
Device now hangs on the Sony logo after boot messgae warning "OEM bootloader unlocked, device not trusted," any help would be appreciated.
brianx87 said:
Thanks for this, I need some help!
All was fine until I tried flashing the recovery, comes back "partition unknown" error. I was unable to bring the device up under an adb device only as a fastboot device.
34.0.A.1.264_R3A firmware.
Different official sony driver (Sony bootloader guide driver didn't work)
Device now hangs on the Sony logo after boot messgae warning "OEM bootloader unlocked, device not trusted," any help would be appreciated.
Click to expand...
Click to collapse
These USB drivers are very annoying to work with. I got mine to finally work using a program called ADB driver installer. http://adbdriver.com/downloads/ Choose automated installation and try what I said. I believe it should fix your problem, after installing the drivers reboot and flash again.
Other than that, I have to ask are you 1000% sure you used the exact commands?
I saw another thread someone mistook
"flash recovery recovery.img" for "flash recovery.img"
"recovery" should be included before the recovery file name
brianx87 said:
Thanks for this, I need some help!
All was fine until I tried flashing the recovery, comes back "partition unknown" error. I was unable to bring the device up under an adb device only as a fastboot device.
34.0.A.1.264_R3A firmware.
Different official sony driver (Sony bootloader guide driver didn't work)
Device now hangs on the Sony logo after boot messgae warning "OEM bootloader unlocked, device not trusted," any help would be appreciated.
Click to expand...
Click to collapse
Why didn't the sony guide work? It worked for me. Just so you know, the "device cant be trusted" message is appearing on everyones' phones after unlocking the bootloader, it's not a problem or something
the part of restoring DRM is skipped,
please xplain
YasuHamed said:
the part of restoring DRM is skipped,
please xplain
Click to expand...
Click to collapse
I know, as I said there is room for improvement. The reason I did not include it is because I never did it myself, so I don't want to write something wrong or something that could lead to problems. I write something only if I am 100% sure. If anyone of you is kind to offer that piece so the guide is complete I will be glad
FoxTheLegend said:
Why didn't the sony guide work? It worked for me. Just so you know, the "device cant be trusted" message is appearing on everyones' phones after unlocking the bootloader, it's not a problem or something
Click to expand...
Click to collapse
Ok I figured out what I did wrong and was able to amend another issue I edited out of this post.
brianx87 said:
Ok I figured outwhat I did wrong (able to boot into the os and warning message no longer an issue ) and the issue I am now facing is that twrp is hanging on the boot screen. Is this version of twrp built to a specific version of android?
Click to expand...
Click to collapse
What do you mean hanging? the twrp logo frozen?
FoxTheLegend said:
What do you mean hanging? the twrp logo frozen?
Click to expand...
Click to collapse
Working now, used a previous version of twrp by mistake. Using latest build works fine now, have to wait to get home from work to proceed with the rest, annoying procedures this stuff but your guide is great.
brianx87 said:
Working now, used a previous version of twrp by mistake. Using latest build works fine now, have to wait to get home from work to proceed with the rest, annoying procedures this stuff but your guide is great.
Click to expand...
Click to collapse
Thanks, Im glad to it works now
FoxTheLegend said:
I know, as I said there is room for improvement. The reason I did not include it is because I never did it myself, so I don't want to write something wrong or something that could lead to problems. I write something only if I am 100% sure. If anyone of you is kind to offer that piece so the guide is complete I will be glad
Click to expand...
Click to collapse
thank you for the answer sir
i am unable to find any twrp that work for my F5122, it always bricks and i have to reset.
is there any twrp recovery image that works correctly with f5122?
YasuHamed said:
thank you for the answer sir
i am unable to find any twrp that work for my F5122, it always bricks and i have to reset.
is there any twrp recovery image that works correctly with f5122?
Click to expand...
Click to collapse
Hmm.. Did you try the one from the poison thread? I myself have still the old version installed (not 3 or 3.1) if I find it on my pc I will share it with you
FoxTheLegend said:
Hmm.. Did you try the one from the poison thread? I myself have still the old version installed (not 3 or 3.1) if I find it on my pc I will share it with you
Click to expand...
Click to collapse
I have to modified kernel
all i want is to boot it via fastboot command
for example i have the rooted kernel SU installed (but battery drain is high) so i what wana do is flashing kernel with all securities OFF and then with twrp image i will do
Code:
fastboot boot twrp.img
i will boot the X in to twrp and i will flash SUPERSU via twrp.
thanks all
YasuHamed said:
I have to modified kernel
all i want is to boot it via fastboot command
for example i have the rooted kernel SU installed (but battery drain is high) so i what wana do is flashing kernel with all securities OFF and then with twrp image i will do
i will boot the X in to twrp and i will flash SUPERSU via twrp.
thanks all
Click to expand...
Click to collapse
I see, but don't you want to figure out why it's not working normally? Noone has reported a similar problem
FoxTheLegend said:
I see, but don't you want to figure out why it's not working normally? Noone has reported a similar problem
Click to expand...
Click to collapse
since there is no offcial twrp for X out yes and only DORA (XA) is available) even XA don't work for X
so either twrp 2.8, 3.0 or 3.1 any should just boot in order to let us flash superSU.
YasuHamed said:
since there is no offcial twrp for X out yes and only DORA (XA) is available) even XA don't work for X
so either twrp 2.8, 3.0 or 3.1 any should just boot in order to let us flash superSU.
Click to expand...
Click to collapse
=-= try to use this command fastboot flash recovery [your_recovery_name].img
I use f5122 and flash successfull twrp 3.0.2 and 3.1. with this, i flash some kernel and rom without any problem.
Everything is working good for me now, the only issue now is restoring the DRM keys, has anyone found a credible source for doing this on this device?
How can I be sure I have a full root? I can't seem to be able to uninstall some of the bloatware only disable it!
brianx87 said:
Everything is working good for me now, the only issue now is restoring the DRM keys, has anyone found a credible source for doing this on this device?
How can I be sure I have a full root? I can't seem to be able to uninstall some of the bloatware only disable it!
Click to expand...
Click to collapse
Well titanium backup can assure you but I don't see why you wouldn't have full root... You need an app uninstaller to uninstall bloatware, it can't be done through the settings you know that right

Lineage OS 13 Port for BLU_Studio_XL_2

:good:
I have cm13 ported over from different Phone (Blu Life_Max) and booting.
already working
1. wifi
2. camera but not video camera
3. bluetooth audio
4. loud speaker audio
5. FM Radio
6. cell in sim1 and sim2 slot, but sim2 only gets H+ speed(5-10Mbps)
SIm1 gets 4G(LTE) speeds on test 50Mbps Both tests with freedomPop
known issue (mostly camera related)
1. videocamera causes camera crash
2. selfie-camera not available **Fixed with V6**
3. panarama shot crashes camera
4. NFC not able to turn on (stock rom did not have NFC, so this may not be possible to work) : next update may remove this **fixed in V5**
V7 -- Hassome permission changes in boot.img that were found in logcat, for "SMI"
still not working videocamera
To install:
1. Must be bootloader unlocked
.
How to Unlock Bootloader via Fastboot
1. Setup ADB and Fastboot on your PC.
2. Enable USB debugging and OEM Unlock on your Android device.
3. Connect your device to the PC with a USB cable.
4. Open a command window on your PC.
5. Boot your device into bootloader mode using the following command:
Code:
adb reboot bootloader
└ You may get a request to authorize USB debugging on the device, accept it.
6. Once your device is in bootloader mode, issue the following command to unlock bootloader:
Code:
fastboot oem unlock
You get a confirmation screen on your device. Press Volume Up button to highlight Yes and press Power button to select it.
This will begin bootloader unlocking process, which shouldn’t last more than couple of minutes.
7. Once bootloader is unlocked, your device will reboot into bootloader mode. You need to boot it into system now using the command below:
Code:
fastboot reboot
During reboot, your device will go through a factory reset and then finally boot into system.
2. Install included twrp(New kernel for recovery allows touchscreen to work)
***PRIOR RELEASES NEED TO USE LOPESTOM RECOVERY TO INSTALL***
Due to different moint point descriptions Future versions(If they come) will use block number moints to be compatible with both
******V-7-Block is compatible with both recoveries
1. make sure developer options is enabled
2. Reboot to bootloader
Code:
adb reboot bootloader
3. Test recovery works for your device
(example commands assume you have the vampirefo version of recovery downloaded to the desktop)
Code:
Fastboot boot Desktop/recovery-TWRP-3.1.1-Vampirefo-studio-xl-2.img
4. If recovery boots good, then return to bootloader and flash (commands work from in booted twrp)
These steps are what I find to be best order to prevent the stock rom from replacing the stock recovery on boot.
Code:
fastboot flash recovery Desktop/recovery-TWRP-3.1.1-Vampirefo-studio-xl-2.img
fastboot boot Desktop/recovery-TWRP-3.1.1-Vampirefo-studio-xl-2.img
adb wait-for-device
adb reboot recovery
3. If first install. do wipe and wipe system too. If Updating no wipe needed
Sources:
Rom not built for this device Built for Blu Life-Max --no thread to link, sorry
Rom uses the stock kernel, pulled from oem device (studio_XL_2)
keeping a git of files swapped to make rom work
https://github.com/mrmazakblu/BLU_Studio-XL-2_port_from_Life-Max
kernel source for recovery:
https://github.com/mrmazakblu/Blu_studio-XL_2_kernel_source
Other projects for Studio_XL_2:
Reserrection Remix Port
XDA:DevDB Information
blu-studio-xl-2, ROM for all devices (see above for details)
Contributors
mrmazak, Thanks to vampirefo --building donor rom
ROM OS Version: 6.0.x Marshmallow
ROM Kernel: Linux 3.10.x
ROM Firmware Required: BLU-Studio-XL-2--BLU_S0270UU_V09_GENERIC
Based On: Lineage OS
Version Information
Status: Testing
Created 2017-10-30
Last Updated 2017-11-30
New TWPR kernel
Reserved
TWRP touchscreen
new kernel for TWRP allows touchscreen to work when recovery is flashed to device.
thanks to @vampirefo for finding a fix for Life-Max. Same fix worked here too.
New kernel is also put into @lopestom twrp.
Choose either one they both work.
Thanks for porting. I'm looking forward to testing it with my Studio XL2
killer13666 said:
I tried flashing it like you said and this is what happened....
Code:
Installing zip file '/external_sd/BLU_Studio-XL-2_port_from_Life-Max-V-7.zip'
Checking for MD5 file...
Skipping MD5 check: no MD5 file found
I:Update binary zip
I:Zip contains SELinux file_contexts file in its root. Extracting to /file_contexts
I:Legacy property environment initialized.
Target: Blu Studio XL 2
Target: Blu Studio XL 2Check if system is already mounted
Check if system is already mountedcould not detect filesystem for /dev/block/platform/mtk-msdc.0/11230000.msdc0/by-name/system, assuming ext4could not detect filesystem for /dev/block/platform/mtk-msdc.0/11230000.msdc0/by-name/system, assuming ext4
mount: failed to mount /dev/block/platform/mtk-msdc.0/11230000.msdc0/by-name/system at /system: No such file or directorymount: failed to mount /dev/block/platform/mtk-msdc.0/11230000.msdc0/by-name/system at /system: No such file or directoryRunning backup script for update installsabout to run program [/tmp/install/bin/backuptool.sh] with 2 args
Running backup script for update installs
run_program: child exited with status 127
unmount of /system failed; no such volumeChecking if Data is compatableunmount of /system failed; no such volume
Checking if Data is compatable
about to run program [/tmp/install/bin/otasigcheck.sh] with 1 args
You have an installed system that isn't signed with this build's key, aborting...
run_program: child exited with status 124
script aborted: Can't install this package on top of incompatible data. Please try another package or run a factory reset
Can't install this package on top of incompatible data. Please try another package or run a factory reset
Updater process ended with ERROR: 7
I:Legacy property environment disabled.
I:Install took 14 second(s).
Error installing zip file '/external_sd/BLU_Studio-XL-2_port_from_Life-Max-V-7.zip'
Updating partition details...
Click to expand...
Click to collapse
Do not know why you have failed to mount /system error could be because you have /system set to be read only.
In install directions it says need to wipe /data
and
also advanvance wipe /system
second error says imcompatable /data == this means you did not wipe data before installing.
Please continue here in the rom thread.
mrmazak said:
Do not know why you have failed to mount /system error could be because you have /system set to be read only.
In install directions it says need to wipe /data
and
also advanvance wipe /system
second error says imcompatable /data == this means you did not wipe data before installing.
Please continue here in the rom thread.
Click to expand...
Click to collapse
I figured out what the problem was. For some reason, the recovery image you supplied wasn't mounting the system partition properly. I used a different image and the ROM flashed perfectly
killer13666 said:
I figured out what the problem was. For some reason, the recovery image you supplied wasn't mounting the system partition properly. I used a different image and the ROM flashed perfectly
Click to expand...
Click to collapse
please let me know which one worked for you and which one did not.
I think I was using the one marked 3.1.1 (vampirefo) but now I am not sure.
I may do independet testing again on both, but would appreciate your input.
Just confirmed there is a problem with the combination of the update-binary used in these install zips and the vampirefo recovery. The fix can be either i use different update-binary file or you use lopestom recovery.
**EDIT**
Problem was with the my updateer-script. I put fixed install packages up.
Thanks for the port my version is v06.0.04.00_generic 16/06/2017
I have a unlocked phone from best buy
I keep seeing everyone say v09 mine has updated twice wondering if it will work on mine or if I need to update somehow
ahnuts72 said:
Thanks for the port my version is v06.0.04.00_generic 16/06/2017
I have a unlocked phone from best buy
I keep seeing everyone say v09 mine has updated twice wondering if it will work on mine or if I need to update somehow
Click to expand...
Click to collapse
I dont see any version of my stock OS that is similar to that number you have.
When I had stock installed, In the settings screen, about phone listed the build version as
Code:
BLU_S0270UU_V09_GENERIC
This port is for Blu_Studio_XL_2 make sure that is device you have.
If you look in the build.prop you will get more information about the device.
if you want to , you can pull the build.prop and post it , so I can see
Code:
adb pull /system/build.prop Desktop\build-prop.txt
then attach the file here.
According to the device in about phone mine is studio xl 2 and that was what the box said when I purchased the phone at best buy
And this one shows the version
And this one shows the version
Wrong pic
ahnuts72 said:
Wrong pic
Click to expand...
Click to collapse
The dates show it is a newer software than what I had, but this should still work, as long as you are still able to unlock the bootloader.
In the developer options I have a setting that says oem unlocking allow the bootloader to be unlocked will that work or will I have to still do it from adb
ahnuts72 said:
In the developer options I have a setting that says oem unlocking allow the bootloader to be unlocked will that work or will I have to still do it from adb
Click to expand...
Click to collapse
here is guide.
https://www.theandroidsoul.com/unlock-bootloader-via-fastboot-android/
the unlocking does do a complete wpe on the data part of the phone. so if you have pictures or music or any files you want to keep , make sure to copy first. Also to be safe , if you have external sdcard in , take it out before doing unlock
****
****
Must complete the unlock as the guide shows includeing the reboot, so stock recovery does its wipe, I t is important part of the unlock.
**
**
after unlocked,
to flash recovery, enable developer options again, enable usb debugging. authorize adb connection to your pc-
Code:
adb reboot bootloader
fastboot boot recovery.img
**recovery.img = "full path to the downloaded recovery"
**example if you downloaded the vampire based recovery and you downloaded to the desktop**
Code:
fastboot boot Desktop/recovery-TWRP-3.1.1-Vampirefo-studio-xl-2.img
after booted to recovery and it works return to bootloader and flash it to phone. I allways recomend this boot first method to verify it recovery works. You cant be certain every od will work on every device. Better safe than sorry.
select reboot menu from recovery and then select reboot bootloader.
Due to a securety measure android has (recovery-from-boot) when replacing recvoery to need to boot directly to new recovery to prevent the android system from replacing it with stock version. so I use the steps below
Code:
fastboot flash recovery Desktop/recovery-TWRP-3.1.1-Vampirefo-studio-xl-2.img
fastboot boot Desktop/recovery-TWRP-3.1.1-Vampirefo-studio-xl-2.img
adb wait-for-device
adb reboot recovery
.
Android 6 or 7, plus install questions
Hi, I have rooted several phones but the procedure keeps getting more difficult. I see the instructions for installing recovery-TWRP-3.1.1-Vampirefo-studio-xl-2.img but I am curious what is on this image .... will it be rooted and if so, what version of Android is bundled? Will the phone then support Xposed and Xprivacy?
From what I can determine, the video camera is not working with your most recent release, V8, is this correct?
Thank you for your assistance!
Donphillipe said:
Hi, I have rooted several phones but the procedure keeps getting more difficult. I see the instructions for installing recovery-TWRP-3.1.1-Vampirefo-studio-xl-2.img but I am curious what is on this image .... will it be rooted and if so, what version of Android is bundled? Will the phone then support Xposed and Xprivacy?
From what I can determine, the video camera is not working with your most recent release, V8, is this correct?
Thank you for your assistance!
Click to expand...
Click to collapse
LineageOS 13 is android 6
there is no V8 only upto V7
video recording does not work
Lineage has root built in. Enable it in developer options
I do not know about xposed I not use it
Donphillipe said:
" I see the instructions for installing recovery-TWRP-3.1.1-Vampirefo-studio-xl-2.img but I am curious what is on this image "
Click to expand...
Click to collapse
That image is TWRP recovery only
I have not been working on this anymore.
I have ported "better" Resurection rom based on android 7 , have been using it as a daily use phone for just over a month now
https://forum.xda-developers.com/android/development/-t3699638
I appreciate your patience with someone who only dabbles in this hobby. When you say that the install image is TWRP only, what exactly does this mean?
I know I have owned several BLU phones and each time I tried to install a high-end recovery tool in the past, the list of supported phones on the recovery software list would never include my BLU device, saying something to the order of the source needing to be recompiled (as I recall) or something to that order which never seemed to happen. So are there additional steps for getting the phone to the point it will take this image other than the steps you outlined for unlocking the boot loader? Or what do I need to be aware of?
Also, do you have a backup of the factory image available in case something goes wrong, with basic instructions on how to recover the phone back to the factory version? Or is there something I can install or do on this phone to create a backup copy on my own?
Again I am sorry to have to ask for what to some appears a simple procedure. I do appreciate your going to the effort when you have already contributed so much with your images. Thank you!
Donphillipe said:
I appreciate your patience with someone who only dabbles in this hobby. When you say that the install image is TWRP only, what exactly does this mean?
I know I have owned several BLU phones and each time I tried to install a high-end recovery tool in the past, the list of supported phones on the recovery software list would never include my BLU device, saying something to the order of the source needing to be recompiled (as I recall) or something to that order which never seemed to happen. So are there additional steps for getting the phone to the point it will take this image other than the steps you outlined for unlocking the boot loader? Or what do I need to be aware of?
Also, do you have a backup of the factory image available in case something goes wrong, with basic instructions on how to recover the phone back to the factory version? Or is there something I can install or do on this phone to create a backup copy on my own?
Again I am sorry to have to ask for what to some appears a simple procedure. I do appreciate your going to the effort when you have already contributed so much with your images. Thank you!
Click to expand...
Click to collapse
The recovery image (TWRP) works for this device.
Yes recovery images, just like android roms are specific to each different device. This one has been edited to work for Studio XL 2
The TWRP is a custum recovery needed to install the custom ROM
The steps are complete, you shouldn't need anything else (need adb and fastboot)
Yes stock recovery image is available. Installing back to stock recovery is same steps as installing custom recovery.
both can be done as described with fastboot. Or both can be installed using SPFT (smart phone flash tool)

[RECOVERY] TWRP for Onn Android Tablets (unofficial) - 2019-11-30

TWRP Custom Recovery for the Onn Android Tablet series​
This is the first fully-featured custom recovery for Walmart's MediaTek-based Onn tablets: ONA19TB002, ONA19TB003 and ONA19TB007. TWRP needs no introduction. If you have come here, you probably have some idea of what it is and what it's used for. This TWRP build does not need the bootloader unlocked or VBMeta verification disabled, although it's recommended that you at least unlock the bootloader.
DISCLAIMER
Everything described in this thread is done at your own risk. No one else will be responsible for any data loss, corruption or damage of your device, including that which results from bugs in this software.
FEATURES
Decrypted data partition
All USB modes functional: MTP, ADB, Mass Storage, OTG, Charging
Fast boot time
Adoptable storage mounting
Firmware image backup and restore
Works under locked bootloader
Android 9 build fits within the 16MB recovery partition -- no compromises or partition resizing necessary
INSTALLATION METHOD 1
Download the recovery to your PC and unzip the image
Unlock the bootloader (skip if you have already done this)
Enable OEM Unlock in Developer Options in Android Settings
Boot into fastboot mode either by holding vol. up+power to power it on and selecting "Fastboot mode", or by running the 'adb reboot bootloader' command from within Android.
Install fastboot and appropriate drivers on your PC if you have not set those up
Unlock the bootloader with the command
Code:
fastboot flashing unlock
...and follow the instructions on the screen. This will wipe your data.
Flash the custom recovery with
Code:
fastboot flash recovery twrp-3.3.1-ONA19TB002.img
(use the right file name path for your device)
Reboot to recovery with
Code:
fastboot oem reboot-recovery
INSTALLATION METHOD 2
This assumes you are familiar with SP Flash Tool or can figure it out on your own
Download the recovery to your PC and unzip the image
Get the appropriate scatter file for your device. The scatter file may be found in the device's firmware under /system/data/misc.
Set up SPFT Download tab as Download Only. Load your scatter file.
Under the recovery line, double-click Location and open your TWRP image.
Click Download and connect your powered-off tablet to your PC. SPFT will automatically flash the recovery to the emmc and disconnect when finished.
INSTALLATION METHOD 3
Head over to Amazing Temp Root for MediaTek ARMv8, read the requirements and directions, and grab the latest mtk-su.
Open a root shell with mtk-su
Flash the (unzipped) recovery with the command:
Code:
dd bs=1048576 if=twrp-3.3.1-0-ONA19TB002.img of=/dev/block/by-name/recovery
(replace the if= file name with your appropriate recovery image path)
Exit root shell
START RECOVERY
Three methods:
On a powered off tablet, hold Vol. up+power for about 3 seconds. In the menu that appears, select "Recovery mode"
With Android ADB, use the command 'adb reboot recovery'
From Android root shell, use the command 'reboot recovery' or just use any root app with OS reboot features
NOTES
Kind of important: Make a backup of your Crypto Footer as soon as you can. This is the encryption key to your data partition. When accessed from TWRP, this key can get "upgraded" so that you will get locked out of Android. TWRP uses a hacky workaround that saves and restores the original footer on every /data decrypt. But that method is not what I would call 100% reliable.
Make sure you have a backup of the untouched stock system and vendor images. There are no official firmware packages available to download.
Only mount system/vendor partitions in read/write mode if you have unlocked the bootloader. It is recommended to choose to leave system read-only at the startup prompt unless you have a specific reason to modify it. If the bootloader is locked, then dm-verity is enforced.* So merely mounting it once in r/w will cause a boot loop.
It's currently not possible to install incremental OTA updates using this TWRP. Use the stock recovery to update the FW. That will only work if you have never mounted system/vendor in write mode.
DOWNLOAD (Nov. 30, 2019)
Current version: 3.3.1-1
ONA19TB002 - Onn 8" model
ONA19TB003 - Onn 10.1" model
ONA19TB007 - Onn 10.1" w/keyboard model
Source code
ONA19TB002 | ONA19TB003 | ONA19TB007
ACKNOWLEDGEMENTS
The team behind TWRP & OmniROM
@tek3195 for testing and feedback on the 8" model
Please post feedback since these are still pretty new and not exhaustively tested. Let me know if I should port it to other models in the series.
Reserved also
grabbing this one too cuz why not
Very nice! I'll download and test the 003 one soon.
I also have a 007 model to experiment with.
I tried about a dozen times to build TWRP and failed miserably LOL. Closest I got was one that would boot but the rotation was all messed up, USB wouldn't work, didn't mount some partitions... Yeah, it was a hot mess.
Do you happen to have sources available?
Hi @NFSP G35,
I'll have the source code soon. Most of the tricks involved patching bootable/recovery. So I need to commit those changes and include the proper patch set from my tree....
Amazing!! Gonna install and test 8" right now.
Has anyone tried a GSI on these tablets yet?
MishaalRahman said:
Has anyone tried a GSI on these tablets yet?
Click to expand...
Click to collapse
I do know @tek3195 , the Onn 8 thread starter, has tried many of them as well as others here, somewhere on that thread he listed his tests and opinion of several of them.
I'm pretty sure others on that thread have also tried GSI's.
MishaalRahman said:
Has anyone tried a GSI on these tablets yet?
Click to expand...
Click to collapse
I did try both Phhuson vanilla and also Liquid Remix (I'm keeping this one for now). I didn't flash them through twrp, but using fastboot via bootloader.
WoW! AwEsOmE! I cannot wait to try this! THANK YOU!!!!!!
Hey,
This is a neat thing to see for the Onn tablets. I have a question though. I own a device based on the mt8163, and am trying to help people with another device I don't own (the powkiddy x18 which also uses the mt8163). One of the things I wanted to do was to make a custom rom for the x18, since it's stock firmware is horrible. And of course, one of the first steps to custom roms is twrp. So I have a question for you that I hope you can answer for me. How did you make this build of twrp? I have seen no device trees for this device so I was kinda curious. If you can help me in any way, I'd be so grateful, and I'm sure the other people with the x18 would be grateful for help.
@diplomatic
Is there a different procedure for installing TWRP on a locked bootloader?
I can confirm that using SP Flash to load your TWRP.img will produce a bootloop when installing to a device with the BL locked. Reflashing the original recovery.img makes the problem go away. You mentioned in the OP that this TWRP will work on a locked BL so I thought I would share my case study with you in following the procedure you defined.
MY SINCERE GRATITUDE FOR YOUR EFFORTS IN PORTING THIS TO THE ONN!
You're welcome, @Spatry.... Can you describe how you ended up with a locked BL? Was it unlocked before? Have you ever tweaked vbmeta? Also, when you say bootloop, do you mean for Android or just for recovery? I'm not going to insist that it works under locked BL. I tested it once and it did boot up...
diplomatic said:
You're welcome, @Spatry.... Can you describe how you ended up with a locked BL? Was it unlocked before? Have you ever tweaked vbmeta? Also, when you say bootloop, do you mean for Android or just for recovery? I'm not going to insist that it works under locked BL. I tested it once and it did boot up...
Click to expand...
Click to collapse
Presently, I am running stock with Magisk patched BOOT on locked bootloader, stock vbmeta. The boot loop was at the ONN Android screen, I could not get it to even boot into recovery.
At one time I did run with the bootloader unlocked (with --disable-verification on stock vbmeta) and I ran Phusson's AOSP, Liquid Remix and Bliss. I found there was no benefit to me in running the other mods so I reverted back to stock courtesy of @CaffeinePizza and the bootloader re-locked to get rid of that annoying 5 second orange state.
In each instance, I always used SP Flash tools to load all .img files. I only used fastboot to install magisk_patched.img onto the stock installation. Unlocking the bootloader erases all data and I did not feel like reinstalling everything again, so I figured I would try to install TWRP per your instruction to see if it would work while the BL was still locked... Restoring the original recovery got rid of the bootloop. I do want to try your TWRP so I will try it with BL unlocked when I get some free time to do so.
Spatry said:
Presently, I am running stock with Magisk patched BOOT on locked bootloader, stock vbmeta. The boot loop was at the ONN Android screen, I could not get it to even boot into recovery.
Click to expand...
Click to collapse
This sounds like you might have flashed a wrong/corrupt image to recovery. It may have to do with AVB checks rather than bootloader lock. But those conditions might be interdependent somehow so I can't tell you for sure. The fact that you are able to boot a patched image on a locked BL says it doesn't care too much about verification. I can tell you for sure that any recovery image must have avb metadata, not necessarily the required hash, for both Android and recovery to boot. Can you try to unzip the image file and flash it over again?
Hmm, the situation with the bootloader lock sounds eerily similar to the Nabi SE. The latter also had a similar implementation where there's not much in the way of locking things down, other than an (easily circumvented) SP Flash Tool signature check and different preloader keys. And here's the real kicker: the nearly-identical Fisher Price Nabi also ran on the MT8163, so it makes me wonder if it's possible to boot Pie on it, or perhaps a GSI assuming that Treble can be tacked onto it.
Also, do you have the source repo to this TWRP port of yours?
If anyone here gave me an XDA ad-free subscription, thanks a lot! I didn't get a notification of who it was. Using this site is a lot more bearable now.
diplomatic said:
If anyone here gave me an XDA ad-free subscription, thanks a lot! I didn't get a notification of who it was. Using this site is a lot more bearable now.
Click to expand...
Click to collapse
Where do I find crypto footer to backup
diplomatic said:
If anyone here gave me an XDA ad-free subscription, thanks a lot! I didn't get a notification of who it was. Using this site is a lot more bearable now.
Click to expand...
Click to collapse
Kinda cool without the ads isn't it. I know I sent one about a week ago or so. I think everybody ought to send you one, you deserve it. THANKS and AWESOME work.

5S/5G Roms and Root Mega thread [Updated November 2022]

Nubia Red Magic 5G and 5S Roms and Root support Thread
Second post for TWRP and Magisk installation. Mirror for all roms and tools at end of post
Latest Official Rom updates
Android 11
US/Asia - V8.70 Nubia Link MD%: will update soon
EU - V7.70 Nubia Link MD5: will update soon
China - V9.50 Nubia Link MD5: 361AC13CA52AB83C239783FBAB088CEA
Android 10
US/Asia - V8.12 Nubia Link MD5: 6e930fc2431b3daeae2d94145926a6c1
EU - V7.15 Nubia Link MD5: bb9e3153716851e87f196ae6b4f44a2e
China - V6.23 Nubia Link MD5: BD447840ACA4D48F9443B94D2EAD890F
Change Log - 8.70 / 7.70 Android 11
- Security Patch October 2022
- Game Space enhancements
- Game space Gyro sensitivity menu
- game space touch sample rate improvement
- Fixed: corner of screen non-touchable in some cases
- Fixed: issue where game would fail to close
- Fixed: location of caller display
-Fixed: screen tearing when using 144hz
-
Bugs -
in Testing
- Always on display notification not showing
- memory leak in nubia launcher (requires forced close often to stop phone from lagging)
- small window mode for telegram and discord have wrong zoom/ aspect levels.
_____________________________________________________________________________________________________________
UNBRICK TOOL for 5S - Courtesy of @johnny886
Use this tool, with directions on the thread to restore your device to USA/Asia 8.07
you can then install TWRP and after flash any region rom after creating a somewhat universal unbrick tool for those in different regions.
Follow directions on the thread. but here is a link to the Thread. A Mirror for the tool is in my Personal Mirror at the bottom of this thread post.
Link to Thread
Confirmed working with 5G devices - but its recommended to update as soon as you unbrick.
_____________________________________________________________________________________________________________
For unlocked bootloader
Fix your fingerprint sensor.
here Link
--------------------------------
Update Instructions.
Note
for Android 11 do not flash through TWRP you will softbrick.
____________________________________________________________________
For Stock devices without root
- disable security. No pin, no face unlock, no finger print, no pattern. remove all security.
-download zip file
-go to system update tap three dots and select local update
-Navigate to update.zip and select.
-your phone will reboot and install new rom
- you phone will reboot once more and you will be greeted with your lock screen
- setup Phone with security options as before flash.
For devices with "LOCKED bootloader" Root / TWRP (not tested on A11)
- take backup of vbmeta and recovery partitions in TWRP
- change the name of both files to vbmeta.img and recovery.img
(VBmeta is often 64kb big and Recovery is often 90+mb big.)
- copy and paste these new img files into the update zip.
- flash through TWRP
- go back to main menu, select advanced, then select option
"disable replace TWRP" to keep TWRP as your recovery.
for devices with "Unlocked bootloader" (not tested on A11)
-make full backup
-download zip
-install zip through TWRP
-reboot
__________________________________________________________________________________
Custom Roms and Kernels
Kernel
Mattofthedead's Redmagic 5S kernel for LOS and Stock roms LINK
Roms
Rom Builder Ra's Custom Roms - Please post any bugs or issues in the related threads.
Pixel Experience Plus
Ressurection Remix
NOTE : to boot any Custom rom on the 5S device. Flash the Rom following the directions. then flash Matts LOS kernel Version 3
__________________________________________________________________________________
------------------------------
Old roms
Android 11
V8.65 Nubia Link MD5: 3d52e18c66366d3d23744184425d3926
V8.64 Nubia Link MD5: a7e61f5e2f7c377a6850cf6ac3a62aa7
V7.65 Nubia Link MD5: 746dad5b6145dfba1108355095a6ad46
V7.64 Nubia Link MD5: 55371ee8e5728aee2bc7df5b3a7d6585
V9.42 Nubia Link MD5: D492B92DD83B366508CDD74DE7D152A3
V9.40 Nubia Link MD5: D28F26289A9B75F771EF4F623F0BB367
V8.57 Nubia Link MD5: 266819d4b09c2c52aadb39e948dc84bc
V8.59 Nubia Link MD5: d7e32b7a3e833adc57fcf734aa47f5a3
V7.57 Nubia Link MD5: 81ee71869f660a28b631d871ffb59524
V7.60 Nubia Link MD5:
V9.26 Nubia Link MD5: 8997375CD97D8F7F261F21121FC8EFAA
Android 10
v6.18 Link MD5: 9AC5EA5F64835C1995E4A81D4973FB71
V6.13 Link MD5: F38ED2D7CB58252D308B29D1D4517DB9
V7.07 Link MD5: ffc3fdaf4afc522aa3a084d9275f2cb6
V7.14 Link MD5: 0f879160fbf8b556de5303207b93d0d1
V8.07 Link MD5: b30dab221be73292c5da7884afc0363f
V8.11 Link MD5: 85d9366a3017112cb68d66041e725ce6
________________________________________________________
Personal Mirror - Located in Eastern Canada
________________________________________________________
TWRP and root guide for 5S and 5G on Android 10 only - (these steps will NOT unlock your bootloader) - these steps use a bypass method to install a recovery without unlocking bootloader. the command below is to allow flashing of partitions. bootloader status is still locked during and after process is complete.
Note. if you already have ADB and fastboot drivers installed, this folder will work as is. if not I put an installer in the folder too to install a mini adb fastboot setup. which needs windows driver signing turned off (windows 8-10) this can be done by going to advanced startup and choosing to boot without driver signing.
1. Download zip file found at the end of this post
2. Extract to root of C: drive
3. open CMD prompt with admin privileges
4. CD to the ADB folder you extracted. (CD = Change Directory)
5. Connect your device in Fastboot mode (power off. hold volume down +Power until it vibrates. then release power but continue to hold volume down)
6. Once in fastboot mode, with cable connected to the computer run these commands
7. fastboot oem nubia_unlock NUBIA_NX659J (this allows you to flash the device partitions)
8. fastboot flash recovery TWRP-xxx.img (xxx being the version number of the TWRP image you choose to install)
9. fastboot flash vbmeta vbmeta_skip.img
10. reboot to recovery (from the fastboot menu) it should load TWRP
11. if TWRP does not ask you to keep recovery from being over written, go to advanced and choose disable replace TWRP. to keep TWRP as your recovery, and stop the system from re writing the stock recovery.
12. Reboot to system for the first time and complete the initial setup. this is to create the user space partitions data/media ( preferably do not make a pin or pattern at this stage)
13. once in the rom, connect to PC and copy over the Magisk zip to the internal memory. then reboot holding Volume up
14. once back into TWRP (if you created a pin during setup TWRP will ask you for your pin to access data) go into install and flash the Magisk.zip you moved in step 13 then reboot. once back into the rom, you will see a Magisk app, tap it and allow to update, the APK will install latest version of the manager.
More NOTES.
this must be done on a clean system. you need to wipe all data partitions to boot to system. re writing VBMETA causes encryption to break. until you reboot. so you lose everything Make a backup of your data partition on to your PC before doing anything.
its also recommended to have an update.zip of your current rom (which you can download from the post above), incase you need to reinstall the rom after flashing the new recovery or VBmeta.
OEM unlocking in the developer options is NOT needed. since you are not unlocking your bootloader. this step can be ignored.
I'll update this tutorial with newer steps if needed.
Thanks to those that created all these great tools.
@wzsx150 - for their version of TWRP
John Wu - for Magisk
@mslezak vbmeta_skip
If i've helped you root your device, please hit thanks.
Link ADBmini - zip updated with Magisk 21.4 zip
MD5 for ADBfastbootmini.zip: 0ad97a9ae1539b26ef78c849b169e807
I'm working on a process that will update to Android 11, through TWRP and root, without losing data. Much like a stock update.
I will update the thread once my tests are complete.
Hello. I can not flash (i cant even copy) the zip via TWRP. I see the storage device on my windows laptop. I have wipe data cache and dalvik, but it does not copy it and i can not restore my device. Help will be appreciated
josehdx said:
Hello. I can not flash (i cant even copy) the zip via TWRP. I see the storage device on my windows laptop. I have wipe data cache and dalvik, but it does not copy it and i can not restore my device. Help will be appreciated
Click to expand...
Click to collapse
Try putting update zip on a USB key and connect via OTG and flash this way. Moving files with TWRP for some reason corrupts or does not complete transfer.
Make sure to factory reset. If you're coming from a used update, backup your data partition and wipe everything. Then check to see if the partition is in fact empty. ( I noticed sometime my data partition did not erase)
Patrick Morgan said:
Try putting update zip on a USB key and connect via OTG and flash this way. Moving files with TWRP for some reason corrupts or does not complete transfer.
Make sure to factory reset. If you're coming from a used update, backup your data partition and wipe everything. Then check to see if the partition is in fact empty. ( I noticed sometime my data partition did not erase)
Click to expand...
Click to collapse
Thanks
Working fine after full data partition wipe.
I have an additioal question regarding further updates, and i would not want to open a new topic. so, after flashing the zip, i "lost" TWRP but i already have root access. I wonder if is possible to flash upcoming updates with the default recovery built in on the phone, if not, i would assume i need to install TWRP again.in any case, will side loading update make any problem with the current system? i hope my question and context is clear
As these are official ROMs, they will replace the recovery and remove root from the phone.
If you do not have root, flashing these zips from the system menu local update should work. But if you have root or TWRP it's better to flash through TWRP.
You could just flash TWRP again after flash, but I personally modify the zip and add the recovery to it to save me going into fastboot after each update.
Is it possible to install the US rom on a device with EU rom?
in the EU version I can't set the frame rate to 144 hz.
Darkvenum79 said:
Is it possible to install the US rom on a device with EU rom?
in the EU version I can't set the frame rate to 144 hz.
Click to expand...
Click to collapse
I've spoken with another EU rom user, that has the same issue before. it seems it was an error in the stock rom.
reinstalling 7.07 from the links above should fix your problem.
both 7.07 (the EU rom) and 8.07 (the US rom) are exactly the same. the only difference is the languages from what I can tell.
I have a silly question. Unfortunately i unlocked bootloader and i lost the fingerprint capability. I have tried many times to do the calibration without success. I wonder if a factory flash (EDM or any nubia tool) can restore the capability and then use this guide to do the rooting? Thanks
josehdx said:
I have a silly question. Unfortunately i unlocked bootloader and i lost the fingerprint capability. I have tried many times to do the calibration without success. I wonder if a factory flash (EDM or any nubia tool) can restore the capability and then use this guide to do the rooting? Thanks
Click to expand...
Click to collapse
No it wont.
There is a specific step by step that is required to get it functioning again. And it only survives until your next full wipe, which i assume you will do more often flashing non official roms.
I can grab the steps and edit this post for you.
Edit -
Prep.
have a black / very dark brown leather. (belt, wallet, etc)
a soft gel plaster / Bandaid
(something skin textured and in a pink / light beige colour) texture and colour are important.
First step is clear data in the infingerprint app in app info and remove permissionfor data memory - (you need to show system apps to find it)
- digit in call phone code:
*#9959#
(android 11 use Activity launcher (playstore) to enter fingerprint menu)
- uncheck performance checkbox , check only calibration checkbox
Steps -
1. Press start then wait.
2.Press next and with plaster / bandaid press on circle
3.Press next and use wallet / belt ( the display becomes black for black calibration)
4.Press next and use gel plaster / bandaid again but pinch it in so only the part with your finger touches the circle.
If you are lucky see success alert in green color
In system app in setting In-Display-Fingerprint allow access to data memory then reboot device.
Enjoy your Finger Print once more!
P.S. = do this procedure in a very dark room to improve the chances of it succeeding.
Thanks to qtr1st (Salem) and mikekrunk (Mike) for the steps and information.
josehdx said:
I have a silly question. Unfortunately i unlocked bootloader and i lost the fingerprint capability. I have tried many times to do the calibration without success. I wonder if a factory flash (EDM or any nubia tool) can restore the capability and then use this guide to do the rooting? Thanks
Click to expand...
Click to collapse
esy re-lock bootloader fingrperint work fine without calibration
---------- Post added at 12:13 PM ---------- Previous post was at 12:08 PM ----------
Patrick Morgan said:
TWRP and root guide for 5S - (these steps will NOT unlock your bootloader) - these steps use a bypass method to install a recovery without unlocking bootloader. the command below is to allow flashing of partitions. bootloader status is still locked after process is complete.
Pretty short step by step to get twrp and Magisk if you want, on your phone. (Red Magic 5S)
Note. if you already have ADB and fastboot drivers installed, this folder will work as is. if not I put a installer in the folder too to install a mini adb fastboot setup. which needs windows driver signing turned off (windows 8-10) this can be done by going to advanced startup and choosing to boot without driver signing.
1. Download zip file attached or mirrored
2. Extract to root of C: drive
3. open CMD prompt with admin privileges
4. CD to the ADB folder you extracted.
5. Connect your device in Fastboot mode (power off. hold volume down +Power until it vibrates. then release power but continue to hold volume down)
6. Once in fastboot mode, with cable connected to the computer run these commands
7. fastboot oem nubia_unlock NUBIA_NX659J (this allows you to flash the device partitions)
8. fastboot flash recovery TWRP-xxx.img (xxx being the version number of the TWRP image you choose to install)
9. fastboot flash vbmeta vbmeta_skip.img
10. reboot to recovery (from the fastboot menu) it should load TWRP
11. if TWRP does not ask you to keep recovery from being over written, go to advanced and choose disable overwrite TWRP. to keep TWRP as your recovery, and stop the system from re writing the stock recovery.
12. Magisk zips files are in the folder. copy to device and flash through twrp. and install the apk after boot. done twrp and root.
More NOTES.
this must be done on a clean system. you need to wipe all data partitions to boot to system. re writing VBMETA causes encryption to break. until you reboot. so you lose everything Make a backup of your data partition on to your PC before doing anything.
its also recommended to have a update.zip of your current rom (which you can download from the post above), incase you need to reinstall the rom after flashing the new recovery or VBmeta.
OEM unlocking in the developer options is NOT needed. since you are not unlocking your bootloader. this step can be ignored.
I'll update this tutorial with newer steps if needed.
Thanks to those that created all these great tools.
@wzsx150 - for their version of TWRP
John Wu - for Magisk
@mslezak vbmeta_skip
If i've helped you root your device, please hit thanks.
Link ADBmini
MD5 for ADBfastbootmini.zip: e49f162080c6a2124c243716546ad710
Click to expand...
Click to collapse
where is the link of twrp.img
sansha1211 said:
where is the link of twrp.img
Click to expand...
Click to collapse
Patrick Morgan said:
Link ADBmini
MD5 for ADBfastbootmini.zip: e49f162080c6a2124c243716546ad710
Click to expand...
Click to collapse
that file called Link ADBmini has all you need
Is it ok to flash Eu rom to my NA/asia rom?
After reboot it ask me for verify pin and now I can't load the TWRP.img Partition volume Full error help me please
Rai972 said:
After reboot it ask me for verify pin and now I can't load the TWRP.img Partition volume Full error help me please
Click to expand...
Click to collapse
reboot to bootloader by... power off device -> press and hold volume down and power button until you see the logo -> connect device to your computer then do the steps 7 to 12
also once you are in TWRP make sure you ... this must be done on a clean system. you need to wipe all data partitions to boot to system. re writing VBMETA causes encryption to break. until you reboot. so you lose everything Make a backup of your data partition on to your PC before doing anything.
7. fastboot oem nubia_unlock NUBIA_NX659J (this allows you to flash the device partitions)
8. fastboot flash recovery TWRP-xxx.img (xxx being the version number of the TWRP image you choose to install)
9. fastboot flash vbmeta vbmeta_skip.img
10. reboot to recovery (from the fastboot menu) it should load TWRP
11. if TWRP does not ask you to keep recovery from being over written, go to advanced and choose disable overwrite TWRP. to keep TWRP as your recovery, and stop the system from re writing the stock recovery.
12. Magisk zips files are in the folder. copy to device and flash through twrp. and install the apk after boot. done twrp and root.
Rai972 said:
After reboot it ask me for verify pin and now I can't load the TWRP.img Partition volume Full error help me please
Click to expand...
Click to collapse
if you have not removed your pin before flashing any of the roms. it asks you for YOUR own pin that you made when you setup the phone. so use your own pin.
the process of rooting your device, clears a security partition. (the VBmeta partiton)
this deletes the encryption you had on your phone. so the devices partitions are unaccessable and need to be wiped before you can boot to system.
you need to clear data. all data. then check in TWRP file browser if your data partition is clear. .. if you see folders with random letters its not been formatted correctly.
so, in the wipe menu on TWRP you should go into advanced and change the partition type to ext4 then back to f2fs to clear the partition of data.
once your phone is clear you should be able to wipe cache and davik then reboot to system for it to start like a factory reset.
sansha1211 said:
esy re-lock bootloader fingrperint work fine without calibration
---------- Post added at 12:13 PM ---------- Previous post was at 12:08 PM ----------
where is the link of twrp.img
Click to expand...
Click to collapse
How should i relock the bootloader? Via cmd, command doesn't work. Should i lock also via developer options?
josehdx said:
How should i relock the bootloader? Via cmd, command doesn't work. Should i lock also via developer options?
Click to expand...
Click to collapse
adb devices
adb reboot bootloader
fastboot devices
fastboot flashing lock
josehdx said:
How should i relock the bootloader? Via cmd, command doesn't work. Should i lock also via developer options?
Click to expand...
Click to collapse
via cmd -- fastboot flashing lock
After i reboot in TWRP and disable replace TWRP, i install magisk from a USB otg, and then i wipe all data, then i reboot system but it keeps opening TWRP in every reboot, i had to install Stock Rom to have my phone back but without root, what im doing wrong?? thanks
Edit: now it worked, tried a few times and worked don't know what failed

Categories

Resources