General Realme C25s Root (For Advanced Users) - Realme C25 / C25s

Open phone app dial *#899#
Tap on software version
Check if it matches with mine.
First create a backup folder and move these images
1)Patch boot.img with Magisk app.
2)Unlock your bootloader. (In depth test
Link: https://drive.google.com/file/d/1F43p7WggEYIIKe8CwilTg41su3W8S3du/view)
3)Disable dm verity.
4)Flash patched boot image.

Related

[UPDATE / KEEP ROOT GUIDE] MAY 2021 (RQ2A.210505.002) - "FLAME" Magisk & Stock Boot / DTBO Images

(Sorry guys, this would have been up sooner, but Android File Host hasn't been letting me upload all day for some reason, so I just temporarily uploaded May 2021's files to my Google Drive for now instead. Enjoy! --- moved back to AFH )
IMPORTANT!! THESE FILES / THIS THREAD IS FOR PIXEL 4 "FLAME" ONLY, NOT PIXEL 4 XL "CORAL"!!
**IT IS HIGHLY RECOMMENDED TO PATCH THE STOCK BOOT IMAGE YOURSELF, FROM YOUR OWN DEVICE, USING MAGISK MANAGER. WHILE THERE'S A GOOD CHANCE THE FILE I PROVIDED BELOW WILL BE IDENTICAL (USE A FILE HASH CHECKSUM TOOL IF YOU'RE CURIOUS), THERE IS ALSO A CHANCE THEY MAY HAVE SMALL, BUT SIGNIFICANT, VARIANCES**
Thanks for the info and link, @wrongway213
Link to @topjohnwu's post: twitter dot com /topjohnwu/status/1272136975022084097?s=19 (until I figure out how to stop new XDA from forcing the URL to embed a giant twitter posting in the middle of the post...)
ALL FILES BELOW ARE FOR "RQ2A.210505.002, May 2021"!
Magisk v22.1 Patched Boot Image: https://www.androidfilehost.com/?fid=2188818919693794194
Factory Untouched Boot Image: https://www.androidfilehost.com/?fid=2188818919693794193
Factory Untouched DTBO Image: https://www.androidfilehost.com/?fid=2188818919693794195
----------------------------------------------
-------------UPDATE PROCESS BELOW-------------
----------------------------------------------​
EASY UPDATE / SEAMLESS KEEP-ROOT UPDATE PROCESS (using a PC - a very intuitive, effective, and relatively safe method).
** You can only follow this guide verbatim if coming EXACTLY from build "11.0.0 (RQ2A.210405.005, Apr 2021". But the general idea is the same for other builds, you just need the correct files for your device.
flame-rq2a.210405.005-factory-dtbo.img: https://www.androidfilehost.com/?fid=2188818919693776329
flame-rq2a.210405.005-factory-boot.img: https://www.androidfilehost.com/?fid=2188818919693776333
May 2021 sideload OTA zip: https://dl.google.com/dl/android/aosp/flame-ota-rq2a.210505.002-6509c4b3.zip
DO NOT BOOT BACK INTO O/S UNTIL ALL STEPS ARE COMPLETED - THIS ENSURES EVERYTHING BOOTS BACK UP WITH MAGISK / EDXPOSED ALL RUNNING PROPERLY RIGHT AWAY
1. boot into bootloader
----------------
** I was on custom kernel, so I needed to flash BOTH the stock boot and dtbo images
2. fastboot flash boot flame-rq2a.210405.005-factory-boot.img
3. fastboot flash dtbo flame-rq2a.210405.005-factory-dtbo.img
......* these steps to restore stock recovery; dtbo.img also necessary for some kernel installations.
......* won't hurt to flash both anyway, so if you're unsure, go ahead and do both.
-----------------
4. use volume keys to change selection to boot to Recovery Mode
......- when you reach the android symbol with No Command, hold power button, tap volume up, in case you've forgotten
5. choose option "Apply update from ADB"
6. adb sideload flame-ota-rq2a.210505.002-6509c4b3.zip
7. Once the OTA sideload is done, Reboot to bootloader (you'll also notice it's now on the other slot after OTA flashed)
8. fastboot flash boot flame-rq2a.210505.002-magisk_patched-22100.img
9. done, start the phone
(Optional - Flash custom kernel. If you had a custom kernel, you need to re-flash it)
This is a 100% seamless update that requires no additional / re-setup of any of my Magisk or EdX/LSposed setups. All of the factory files can be found here https://developers.google.com/android/images. boot.img and dtbo.img are in their corresponding full Factory Image zips, and the ota zip is under Full OTA Images.
-------------------------------------------------
-------------------TROUBLESHOOTING-------------------
-------------------------------------------------​
Issues after updating?
If you end up unable to boot or bootlooping afterwards, you most likely have an old Magisk module that isn't playing nice with the new build. There are 2 main things you can do:
1. Flash the new factory untouched boot image. You will of course lose root, and all modules will be disabled. However, it should at least get you able to boot back up quickly and have a working phone if you're in a bind.
2. I would recommend checking Tulsadiver's thread: https://forum.xda-developers.com/pixel-4-xl/how-to/magisk-modules-disabler-booting-magisk-t3990557
Instead of reverting to stock boot image, fastboot boot (NOT FLASH) Tulsadiver's boot image. This will boot your phone in Magisk Core-Only Mode, with all modules disabled but root retained. From here you can open Magisk Manager and disable suspect modules. Before rebooting, go to Magisk Manager's settings and disable Magisk Core-Only Mode. Once you disable the incompatible module, the phone should boot back up.
- See this post (or thread) for more tips / context / an example: https://forum.xda-developers.com/showpost.php?p=82509691&postcount=16
Since Magisk v21.x, Core Only mode has been replaced by using Android's built-in Safe Mode. Booting into Safe Mode should essentially boot you back into your system but with all modules disabled (as well as Magisk Hide). Keep in mind that even after you reboot, modules will remain disabled, unless you re-enable them first. Also remember to re-enable Magisk Hide if you had it enabled before.
Please see @Didgeridoohan's guide for more details: https://www.didgeridoohan.com/magisk/MagiskModuleIssues#hn_Core_Only_Mode
It's also worth mentioning, his guide is extremely well-made and contains a lot of useful information that could benefit all Magisk users and modders. I highly recommend looking through it anyway!
Thanks for sharing

[CLOSED][UPDATE / KEEP ROOT GUIDE] JULY 2021 (RQ3A.210705.001) - "FLAME" Magisk-Patched & Stock Boot / DTBO Images

IMPORTANT!! THESE FILES / THIS THREAD IS FOR PIXEL 4 "FLAME" ONLY, NOT PIXEL 4 XL "CORAL"!!
==========> USEFUL LINKS ==========>
==> DOWNLOAD LATEST SDK PLATFORM TOOLS HERE: https://developer.android.com/studio/releases/platform-tools
==> Official Factory Image / OTA - Downloads / Flashing Guide Here (recommend reading): https://developers.google.com/android/images
==> topjohnwu's Official Magisk GitHub Repo - "Useful Links" Section includes installation instructions, FAQ's, documentations, and more: https://github.com/topjohnwu/Magisk#useful-links
==> @Didgeridoohan's excellent Magisk Troubleshooting / FAQ / Installation Guide (also linked from topjohnwu's GitHub!): https://www.didgeridoohan.com/magisk/HomePage
==> Universal SafetyNet Fix Magisk Module by kdrag0n - Use this module by kdrag0n (make sure to donate / give thanks to him for his amazing work!): https://github.com/kdrag0n/safetynet-fix/releases
==> SafetyNet w/ Xposed - I recommend LSposed over EdXposed (better hooking mechanism, less likely to trigger SafetyNet violation, overall more efficient with handling resources anyway).
<========== USEFUL LINKS <==========
**IT IS HIGHLY RECOMMENDED TO PATCH THE STOCK BOOT IMAGE YOURSELF, FROM YOUR OWN DEVICE, USING MAGISK MANAGER. WHILE THERE'S A GOOD CHANCE THE FILE I PROVIDED BELOW WILL BE IDENTICAL (USE A FILE HASH CHECKSUM TOOL IF YOU'RE CURIOUS), THERE IS ALSO A CHANCE THEY MAY HAVE SMALL, BUT SIGNIFICANT, VARIANCES**
Thanks for the info and link, @wrongway213
Link to @topjohnwu's post: twitter dot com /topjohnwu/status/1272136975022084097?s=19 (until I figure out how to stop new XDA from forcing the URL to embed a giant twitter posting in the middle of the post...)
ALL FILES BELOW ARE FOR "RQ3A.210705.001, Jul 2021"!
Magisk v23.0 Patched Boot Image: https://www.androidfilehost.com/?fid=14943124697586362389
Factory Untouched Boot Image: https://www.androidfilehost.com/?fid=14943124697586362371
Factory Untouched DTBO Image: https://www.androidfilehost.com/?fid=14943124697586362372
----------------------------------------------
-------------UPDATE PROCESS BELOW-------------
----------------------------------------------​
EASY UPDATE / SEAMLESS KEEP-ROOT UPDATE PROCESS (using a PC - a very intuitive, effective, and relatively safe method).
** You can only follow this guide verbatim if coming EXACTLY from build "11.0.0 (RQ3A.210605.005, June 2021". But the general idea is the same for other builds, you just need the correct files for your device.
flame-rq3a.210605.005-factory-dtbo.img: https://www.androidfilehost.com/?fid=14943124697586345562
flame-rq3a.210605.005-factory-boot.img: https://www.androidfilehost.com/?fid=14943124697586345561
July 2021 sideload OTA zip: https://dl.google.com/dl/android/aosp/flame-ota-rq3a.210705.001-b0145b66.zip
DO NOT BOOT BACK INTO O/S UNTIL ALL STEPS ARE COMPLETED - THIS ENSURES EVERYTHING BOOTS BACK UP WITH MAGISK / EDXPOSED ALL RUNNING PROPERLY RIGHT AWAY
*. make sure installed Magisk (Manager) app version is equal to or greater than the Magisk pre-patched version boot image provided
1. boot into bootloader
----------------
** I was on custom kernel, so I needed to flash BOTH the stock boot and dtbo images
2. fastboot flash boot flame-rq3a.210605.005-factory-boot.img
3. fastboot flash dtbo flame-rq3a.210605.005-factory-dtbo.img
......* these steps to restore stock recovery; dtbo.img also necessary for some kernel installations.
......* won't hurt to flash both anyway, so if you're unsure, go ahead and do both.
-----------------
4. use volume keys to change selection to boot to Recovery Mode
......- when you reach the android symbol with No Command, hold power button, tap volume up, in case you've forgotten
5. choose option "Apply update from ADB"
6. adb sideload flame-ota-rq3a.210705.001-b0145b66.zip
7. Once the OTA sideload is done, Reboot to bootloader (you'll also notice it's now on the other slot after OTA flashed)
8. fastboot flash boot flame-rq3a.210705.001-magisk_patched-23000.img
9. done, start the phone
(Optional - Flash custom kernel. If you had a custom kernel, you need to re-flash it)
This is a 100% seamless update that requires no additional / re-setup of any of my Magisk or EdX/LSposed setups. All of the factory files can be found here https://developers.google.com/android/images. boot.img and dtbo.img are in their corresponding full Factory Image zips, and the ota zip is under Full OTA Images.
-------------------------------------------------
-------------------TROUBLESHOOTING-------------------
-------------------------------------------------​
Issues after updating?
If you end up unable to boot or bootlooping afterwards, you most likely have an old Magisk module that isn't playing nice with the new build. There are 2 main things you can do:
1. Flash the new factory untouched boot image. You will of course lose root, and all modules will be disabled. However, it should at least get you able to boot back up quickly and have a working phone if you're in a bind.
2. I would recommend checking Tulsadiver's thread: https://forum.xda-developers.com/pixel-4-xl/how-to/magisk-modules-disabler-booting-magisk-t3990557
Instead of reverting to stock boot image, fastboot boot (NOT FLASH) Tulsadiver's boot image. This will boot your phone in Magisk Core-Only Mode, with all modules disabled but root retained. From here you can open Magisk Manager and disable suspect modules. Before rebooting, go to Magisk Manager's settings and disable Magisk Core-Only Mode. Once you disable the incompatible module, the phone should boot back up.
- See this post (or thread) for more tips / context / an example: https://forum.xda-developers.com/showpost.php?p=82509691&postcount=16
Since Magisk v21.x, Core Only mode has been replaced by using Android's built-in Safe Mode. Booting into Safe Mode should essentially boot you back into your system but with all modules disabled (as well as Magisk Hide). Keep in mind that even after you reboot, modules will remain disabled, unless you re-enable them first. Also remember to re-enable Magisk Hide if you had it enabled before.
Please see @Didgeridoohan's guide for more details: https://www.didgeridoohan.com/magisk/MagiskModuleIssues#hn_Core_Only_Mode
It's also worth mentioning, his guide is extremely well-made and contains a lot of useful information that could benefit all Magisk users and modders. I highly recommend looking through it anyway!
Duplicate thread closed

Lenovo K12 - Another (GUAMP) guides (Stock ROM, GSI roms, TWRP and root)

Hi
I was struggling through the past 4 days since I Bricked my device. And as they say "The charity of knowledge is spreading it"
this will not be a real guide. only links and referral to other guides with some noop-friendly (Such as me) notes (As some people doesn't know that lenovo K12 is the same device as Moto G9 play)
1st: Unlocking bootloader -> The process for unlocking the bootloader is similar to that of a Moto device. You can find detailed instructions on how to unlock the bootloader for Motorola devices at GetDroidTips.The process is similar to the Moto device, you can search getdroidtips for how to unlock bootloader for motorolla devices, it is really a well specified described there
2nd:
In case you are on Stock ROM and want to install Custom ROM
- Unfortunately, there is no single custom ROM available for Guamp devices (Lenovo k12 or Moto G9)
- Although, there Guamp devices supports GSI roms (They are non-specific roms. you can consider them a custom roms without specification to our device)
Here is the guide How to install them: Here - Thanks to michaelmelita1
Notes:
1. You can install any GSI from this link, It only should support the a/b partitions
Here is an example: https://github.com/ponces/treble_build_pe/releases/
If you read the package name (Arm64-ab) any GSI containing them name means it is compatible with our devices
2. From the previous link, always install the biggest package (Do NOT install package contating "Slim" or "Vndklite"
3. Some packages have letter written in the name such as (bvN = Vanilla/No Google apps ||||| bgN=contains Google apps)
Up to the moment, I have tried (And I can confirm it works) the following GSI ROMS (Android 13 only)
Pixel Experience Plus 13.0 v2023.04.21
OctaviOS
Miku UI
3rd: How to root
- You should do these steps just after installing the new ROM, and before booting into the system (after finishing the installation process reboot into recovery directly and install Magisk)
- If you booted to your system, you need to wipe your FULL DATA and everything. enter recovery (TWRP) -> Reset -> Format data -> write yes and then confirm
1. Install TWRP - Discussed in this mechaelmelita1 thread also: here
2. Install Magisk APK file from here
3. Rename the magisk file into (Magisk.ZIP) -> Just change the .APK to .ZIP
4. Move the Magisk.ZIP to your device by a laptop using whatever method, then through TWRP screen -> Install -> Choose the Magisk.ZIP and install it
5. Reboot and starts your system
6. If you faced the issue (Abnormal state - "su" binary not from Magisk has been detected) -> then install this module (Link) through magisk
4th: You want to go back to stock ROM:
- Here is the trick, I spent days to find the proper ROM
- First you should connect your device to a fastboot -> Write this code:
Code:
Fastboot getvar all
this code will reveal a lot of details
- Look for your device version (The retail)
You will find it in Fingerprint line
Mine was: RPXS31.Q2-58-17-7-3
1. Go to this website: Here
2. Copy you device version and Search for your ROM in this website (It has to be specifically the same, I mean a ROM with the name RPXS31.Q2-58-17-7 will not work, because the last 3 isn't there which means it is not specific to your device)
3. Enter bootloader (Bootloader, not fastboot) and follow the steps here - thanks to jitendrapingale35 (Check the next step, there is 2 additional commands you need to add)
4. After executing the command
Code:
fastboot flash super super.img_sparsechunk.16
, add the following two commands and then continue with the instructions in the thread:
Code:
fastboot flash super super.img_sparsechunk.17
fastboot erase carrier
That is all for now
I will post anything new I can add
This is my first guide, so accept any mistakes or misunderstandings
Thank you

How To Guide [MAGISK] Root your Realme GT 2

Pre requisites
• Unlocked Bootloader (probably only Indian variant?)
• ADB and Fastboot drivers (I'm assuming you've set that up since you unlocked bootloader)
• Python (used to extract boot image)
• Your stock rom (I found it here: https://realmefirmware.com/)
• time (need some time to download your stock rom and get a hold of your boot image)
Steps:
1) Download Oppo_Decrypt tool from here:
https://github.com/bkerler/oppo_decrypt
2) Extract the contents and place in a folder
3) go to that folder and open a command prompt/power shell in the folder
4) Use commands accordingly
If you've added pip to path:
pip install -r requirements.txt
If you've not added pip to path:
Python -m pip install -r requirements.txt
done? Everything installed?
now get your rom zip file, inside it you'll find a big .ofp file, extract that ofp file and place in the folder where you've extracted your tools
now inside this very folder where ur tools are, create another folder and name it "extract" (tbh u can name the folder anything you want but for the sake of explanation I named it that)
now open a command prompt in the folder where the tools are kept
type: Python
Press space
drag and drop the "ofp_qc_decrypt.py" file in the command prompt
Press space
Drag and drop the large .ofp file you extracted
Press space
Drag and drop the extract folder
Press enter
Wait for a while till there's a message saying
"Extracting super.img" or something along the lines
Exit out of command prompt
Go to the extract folder you'll see a file called "boot.img"
Send this boot.img file to your phone
(Also recommend keeping a copy of the boot.img on your PC for safety)
Install Magisk Manager Apk from the official website on your phone
Open Magisk manager
Click on Install
Click on select and patch a file
Choose the boot.img file you just sent from your PC
after done send the magisk_patched.img to your PC
Now boot your phone into Fastboot mode
(I'll assume you know how to since you've unlocked bootloader)
Connect your phone to your PC using USB cable
open a command prompt and check if your device is connected by typing:
fastboot devices
if it shows up then proceed
type:
fastboot flash boot magisk_patched.img
(Your file name can be different you can just drag and drop the file)
after it says success, type:
fastboot reboot
after reboot open Magisk manager app (might ask u to download?)
and reboot if it asks you to
Congratulations you now have root access!
How to extract images from OTA zip files:
Extract the OTA zip file
Download and extract payload-dumper-go
Drag and drop payload.bin on payload-dumper-go executable
Spoiler: Video instructions
//seems to work for others, i thought it's only for indian roms, because of other posts and EU was locked out for so long, seems to work for EU, too.
IMEI and Baseband only get lost if you unlock the bootloader with the wrong version or boot.img.
smashda said:
BEWARE:​Only Indian variant, you lose your IMEI and Baseband!
Click to expand...
Click to collapse
I test it on RMX3311 EU and work fine.
Deleted
Can we make a boot.IMG for the RMX3311 so we can flash in Magisk ?
Hello,
Is there a easy way to hide banking apps some function don't work because my device is unlocked.
karayemis said:
Can we make a boot.IMG for the RMX3311 so we can flash in Magisk ?
Click to expand...
Click to collapse
It is the same method to extract boot image just get your corresponding rom and either use oppo decrypt tool if on version the phone ships with otherwise use payload dumper with correct ota
karayemis said:
Hello,
Is there a easy way to hide banking apps some function don't work because my device is unlocked.
Click to expand...
Click to collapse
Safetynet fix may help but you need root
BR4UTAL said:
It is the same method to extract boot image just get your corresponding rom and either use oppo decrypt tool if on version the phone ships with otherwise use payload dumper with correct ota
Click to expand...
Click to collapse
Hi,
Thanks, worked for me my device it is rooted now and banking apps are working now.
Device: RMX3311 EU
2 more questions:
1. is there a module i can use to activate call recorder on google dialer ?
2. When there is a new OTA can I just install and repeat all above ?
karayemis said:
2 more questions:
1. is there a module i can use to activate call recorder on google dialer ?
2. When there is a new OTA can I just install and repeat all above ?
Click to expand...
Click to collapse
When there is an ota update download it from software update and wait for it to finish extracting
DO NOT CLICK ON INSTALL
Go into Magisk
Do Uninstall Magisk > Restore System Images
Now Click on Install Magisk > Click Install to Inactive slot (after ota)
click ok and let's go
DO NOT CLICK ON THE REBOOT BUTTON
Now go to software update and click Install, your phone will reboot with root available still and ota update applied
For the model 3311 (EU) is there a step by step guide for root? Please, if exists, drop it here. Thank you
geovision said:
For the model 3311 (EU) is there a step by step guide for root? Please, if exists, drop it here. Thank you
Click to expand...
Click to collapse
The process is the same but instead of IN rom you need to get boot image from EU rom
karayemis said:
Hi,
Thanks, worked for me my device it is rooted now and banking apps are working now.
Device: RMX3311 EU
Click to expand...
Click to collapse
Banking app stops working after a while, this is the second time it stopped working.
karayemis said:
Banking app stops working after a while, this is the second time it stopped working.
Click to expand...
Click to collapse
Here's the Thread for it, you can just use the search on top of the page for things you want to fix, the banking issues come with root and you can find the appropriate Threads when searching for Magisk.
MAGISK MODULE ❯ Universal SafetyNet Fix 2.4.0
Universal SafetyNet Fix Magisk module Magisk module to work around Google's SafetyNet attestation. This module works around hardware attestation and recent updates to SafetyNet CTS profile checks. You must already be able to pass basic CTS...
forum.xda-developers.com
Currently iam on this version rmx3312_11_A.20 of realme ui so how can i get the boot image of this version
_PsyDuck_ said:
Currently iam on this version rmx3312_11_A.20 of realme ui so how can i get the boot image of this version
Click to expand...
Click to collapse
The Ota server only offers the latest version of Android 12 with the A.22 software

How To Guide [Android13] Custom GSI ROM Installation - Full Process

I'm going to explain the complete process for getting up and running on a custom GSI ROM as the guides so far seem to either have only parts of information or incorrect information.
Following this process will wipe your data and alter your phone. I am not responsible for any bricked or damaged devices.
For the purpose of this thread I'm going to assume the installation of an Android 13 GSI image which you can get from the GSI images site. I like to use crDroid.
Make sure you read and understand all instructions before beginning!
1 - Unlock the bootloader
Important things to note:
One Xiaomi account can unlock one device per month. If you need to unlock multiple devices create an account for each one.
Unlocking the bootloader requires a wait time of 1 week after adding your Xiaomi account to the device before it can be unlocked
Create a Xiaomi account to use during this process here: https://account.xiaomi.com
Download the MI Unlock tool from here: https://en.miui.com/unlock/download_en.html
Procedure:
Ensure a SIM card is in with mobile data working and disable Wifi (required when associating your device with your Xiaomi account)
Enable developer mode by going into "About Phone" and tapping on the MIUI Version until it unlocks the setting
In Settings go to Additional Settings > Developer Options
Enable "OEM Unlocking" option
Select the "Add Account" option and enter your Xiaomi account details to link your device to your account
Open the Mi Unlock tool on your PC and log in with your Xiaomi account
If you get asked for a phone number when you log in the tool may get stuck as it doesn't allow you to click on the country code drop down correctly.
To avoid this, use the QR code icon on the first sign in page and from your phone go into the Xiaomi Account settings and click the scan icon on the top right
Log your account in with your phone to set the phone number there and you should be able to log in through the Mi Unlock tool next time without a problem.
Boot your phone into fastboot mode by holding Volume Down & Power buttons
Connect your phone to your PC with a USB cable
Click Unlock on the Mi Unlock tool and it should check your device and then give you a wait timer (generally 168 hours)
After that time is up (you can use your phone normally while waiting but don't mess with the Xiaomi Account settings) connect your phone in fastboot mode again and click Unlock in the Mi Unlock tool to unlock the bootloader.
2 - Install TWRP Recovery (or alternative)
Important things to note:
This phone does not have a dedicated recovery partition, the recovery is a ramdisk that resides within the boot partition
You cannot flash a recovery partition directly to the boot partition as it will then fail to boot
Make sure you use a current version of fastboot: https://provider.xiaomi.eu/tools/fastboot.zip
All commands written below are to be used without the apostrophes within a command prompt (powershell will require .\ placed in front of the command)
Download a TWRP image from here: https://sourceforge.net/projects/recovery-for-xiaomi-devices/files/vili/ Use the A13 image for Android 13 ROMs.
Procedure:
Boot your phone into fastboot mode by holding Volume Down & Power buttons
Connect your phone to your PC with a USB cable
Run command "fastboot boot twrp.img" to reboot phone into TWRP recovery
If this is the first time using TWRP it will likely be in Chinese language. Click the 2nd to last button on the right side of the menu, then the globe icon on the top right to change language.
Go to Advanced and choose Flash Current TWRP to install TWRP into the boot image
Choose Reboot to Recovery to test the image is installed
3 - Install Latest Xiaomi.eu ROM (optional)
Important things to note:
I like to use the xiaomi.eu ROM as a base before installing a GSI image as it seems to be more stable and functional afterwards
This step is optional as you can continue with the global ROM base instead
Additionally, you can stop after this step if you would prefer to use a MIUI based ROM instead of a custom GSI image
The Xiaomi.eu ROM can be downloaded from here: https://xiaomi.eu/community/threads/miui-14-stable-release.67685/
The bootloader must be unlocked and TWRP recovery installed
Procedure:
Boot your phone into TWRP recovery by holding Volume Up & Power buttons
Click the Wipe button and then Format Data. Enter yes to wipe the data partition. (This will erase all data as well as the internal storage)
Connect your phone to PC and copy the xiaomi.eu ROM onto the phone
Click the Install button on the main menu in TWRP and select the ROM zip file to install
Go to Advanced and choose Flash Current TWRP to install TWRP back into the boot image
4 - Install Custom GSI Image
Important things to note:
This phone has a Super partition which dynamically contains system, system_ext and vendor partitions
This means that you cannot flash a GSI image directly to the system partition from TWRP so it must be installed via fastbootd
fastbootd is an enhanced version of fastboot that works with the dynamic Super partition
fastbootd mode looks like TWRP but it will say "Entered fastboot mode..." on the screen
Make sure you use a current version of fastboot: https://provider.xiaomi.eu/tools/fastboot.zip
All commands written below are to be used without the apostrophes within a command prompt (powershell will require .\ placed in front of the command)
Extract vbmeta.img file from the Xiaomi.eu ROM (or global ROM if using that) and place it in same folder as fastboot
Download your custom GSI image of choice from here or other source: https://github.com/phhusson/treble_experimentations/wiki/Generic-System-Image-(GSI)-list
Extract the GSI image, rename it system.img and place it in the same folder as fastboot
Procedure:
Enter fastbootd mode on your phone using one of the following methods:
boot phone into fastboot mode and from your PC run command "fastboot reboot fastboot"
boot phone into TWRP and choose Reboot and then Fastboot
From your PC run the command "fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img" to disable the boot image hash checks to avoid boot loops
Run the command "fastboot erase system" to wipe the existing system image
Run the command "fastboot flash system system.img" to install your custom GSI image
NOTE: If you get an error saying "Not enough space to resize partition" run the command "fastboot delete-logical-partition product_a" and repeat the install again
5 - Install Magisk and Root
Important things to note:
Using the TWRP installation method by renaming the magisk apk to zip is not very reliable and the lastest versions require installation to be performed from within the OS
Download the lastest magisk from here: https://github.com/topjohnwu/Magisk/releases
We use a backup of the installed boot image rather than one from the xiaomi ROM as it has TWRP recovery installed in the ramdisk
Procedure:
Boot your phone into TWRP recovery
Enter the Backup menu, select the boot partition and run the backup
Copy the boot.emmc.win file out of the TWRP backup folder into the Download folder on your phone and rename it boot.img
Reboot your phone into System
Install the magisk apk file
Open magisk and click Install on the top right (in the Magisk section, not the App section)
For the Method choose Select and Patch a File then click Lets Go
Find the boot.img backup file copied to the Download folder and select it (after patching it will tell you the filename of the patched image)
Reboot your phone into TWRP recovery
Choose Install, then Install Image, select the file Magisk created above, select the Boot partition and then swipe to flash
Reboot to system and check in Magisk that it shows as installed (you may also want to reboot to recovery to ensure TWRP is still installed)
6 - Fixing Safetynet
Important things to Note:
The Shamiko magisk module is used to hide root status from apps that detect root/magisk. This can be used to make any app work that fails due to root status.
Shamiko uses the Denylist in Magisk settings to block root settings for those apps enabled but you should NOT have the denylist enforced in Magisk settings
You can find the Shamiko module here: https://github.com/LSPosed/LSPosed.github.io/releases
The default Universal Safetynet Fix can be found here however due to problems in a previous phone, I used the modded version from here (I'm not sure if that's still required for A13)
Procedure:
In Magisk settings choose to hide the magisk app to reinstall it with a different name and app id
In Magisk settings enable Zygisk and reboot phone
In Magisk settings choose Configure Denylist, show system apps from the top menu and enable Google Play Services, Google Play Store & Google Service Framework
In Magisk install the following modules: Shamiko, Universal Safetynet Fix
Install a Safetynet Checker from Google Play (SafetyNet Device Check) and verify safetynet tests pass successfully
7 - Post installation Fixes
Below are some fixes to common problems after installing a custom ROM.
Phh Settings Tweaks:
Qualcomm features - Use alternate audio policy -> fix audio in whatsapp
Qualcomm features - Disable soundvolume -> fix broken audio
Xiaomi features - Enable DT2W -> to enable double tap to wake
Misc features - Force alternative backlight scale -> fix auto brightness
IMS Features - Install IMS APK for Qualcomm -> allows SMS to work

Categories

Resources