How To Guide [GUIDE][GSI] Installing LineageOS or GSI ROMs for A127F Binary U7

Search This thread

TheWorldYT

Senior Member
Oct 23, 2021
235
28
HTC Wildfire S
Samsung Galaxy A20
Did you download the correct firmware? Did you try the method at post #2? It might work for you. Did you follow the steps closely? Here's a quick summary of it:

1. Unlock the bootloader.
2. Patch the firmware with Magisk.
3. Flash the Magisk-patched firmware in the AP slot.
4. Factory reset in the stock recovery.
5. Flash the TWRP binary (only works for A12 U7 Binary)
6. Boot to TWRP.
7. Go to Advance > Terminal and type multidisabler
8. Push the .img file to your /sdcard/
Do either one of these:
9a: Select flash image in the TWRP and then select System partition.
or:
9b. Rename the .img file to system.img then copy the ChonDoe_Flasher.zip file at post #2 in the directory where the .img file is, then flash the ChonDoe_Flasher.zip as a zip file.
10: Wipe data (not Format Data) in TWRP. Then waila, see if it works.
Here is a tutorial that worked perfectly, and is probably useful for people having errors (especially for new people).

1. Unlock the bootloader.
2. Patch the firmware with Magisk 25.1 Patched APK.
3. Flash the Magisk-patched firmware in the AP slot.
4. Boot the phone and set up minimally (Without wifi)
5. Factory reset in the stock recovery.
6. Flash the TWRP binary (only works for A12 U7 Binary)
7. Boot to TWRP.
8. Go to Advanced > Terminal and type multidisabler (sometimes you need to do it twice if it tells you to)
9. Push the .img file to your /sdcard/ or Internal storage
10. Rename the .img file to system.img then copy the ChonDoe_Flasher.zip file at post #2 in the directory where the .img file is, then flash the ChonDoe_Flasher.zip as a zip file.
11. Wipe data (not Format Data) in TWRP. (Optional but recommended)

12: Done! Reboot your phone now.

Patched Magisk 25.1 APK:
 

Attachments

  • 25.1-delta.apk
    10.7 MB · Views: 6
Last edited:
  • Like
Reactions: [email protected]

MozNoor

New member
Jan 25, 2023
3
0
Can you guide me on how can I install LineageOS or other GSI ROMs on SM-A127F/DS, Android 12, Model=A127FXXU7BVI1
Unfortunately, the twrp you have shared here, didn't work on my device and according to my best knowledge no official TWRP has been provided on Samsung official site
Kindly guide me the complete process of downgrading my Samsung Device and then installation of TWRP following the installation of GSI ROM
 

TheWorldYT

Senior Member
Oct 23, 2021
235
28
HTC Wildfire S
Samsung Galaxy A20
Can you guide me on how can I install LineageOS or other GSI ROMs on SM-A127F/DS, Android 12, Model=A127FXXU7BVI1
Unfortunately, the twrp you have shared here, didn't work on my device and according to my best knowledge no official TWRP has been provided on Samsung official site
Kindly guide me the complete process of downgrading my Samsung Device and then installation of TWRP following the installation of GSI ROM
Did you unlock the bootloader yet? It should most definitely work for your model as it is the same listed here for this TWRP and Kernel.
 

MozNoor

New member
Jan 25, 2023
3
0
Did you unlock the bootloader yet? It should most definitely work for your model as it is the same listed here for this TWRP and Kernel.
I have already unlocked the bootloader and successfully flashed "Samfw.com_SM-A127F_XSG_A127FXXU7BVI4_fac" many times on my Samsung A12 SM-a127f Binary 7.
By following your guide, I have successfully patched the AP file with the Magisk listed here in the thread but the flashed of magisk_patched file failed at step number 5. What is the problem here that I am not getting. kindly guide me in this matter
 

Aunonno

New member
Jan 28, 2023
4
0
Dhaka
Hello, today I'll be guiding you to how to install LineageOS or other GSI ROMs on your A127F U7 device.

First, some precaution:
Rich (BB code):
/*
* knox_warranty_void: 0x01
*
* Your warranty is now void.
* I am not responsible for bricked devices, dead SD cards,
* thermonuclear war, or your getting fired because the alarm app failed. Please
* do some research if you have any concerns about features included in this ROM
* before flashing it! YOU are choosing to make these modifications, and if
* you point the finger at me for messing up your device, I will laugh at you.
*/

Requirements:
Code:
* Unlocked bootloader
* Your device's firmware
* Android's platform tools.
* Magisk
* Odin
* U5, U6, U7 TWRP
* GSIs Image for the ROM you want to download
* physwizz's kernel

1) The first step you want to do is, unlock your bootloader. You can simply do that by enabling OEM Unlocking in Developer settings, (Can be unlocked by going to Settings > About Phone > Software Information > tapping "Build Number" 5 times then booting to download mode. (Connect to PC, shutdown your phone, then hold volume up and down buttons, then when you're on the download screen, hold volume up., then press volume up again) WARNING: THIS WILL ERASE YOUR DATA AND PERFORM A FACTORY RESET, SO BACKUP YOUR DATA WHEN NECESSARY.

2) Then, download the firmware you have for your firmware. How? Try visiting sites like samfw and find your firmware by searching A-127F and finding your country's baseband. Then download through your preferred method of downloading. Mine I login to Google, and downloaded through Google Drive, which is faster. (Though it will personally copy the firmware's file to you Google Drive and occupy space on it, so beware of that and delete the file afterwards, the file is in DRIVE > samfw_temporary_folder_dont_delete I assume it's safe to delete after download, so there's that.)

3) Extract the file, and adb push the AP_XXXXX file to your device. How? Download the Android platform tools to the above hyperlink, then extract it, go to the file and then type: e.g adb push [DIRECTORY WHERE YOU EXTRACTED YOUR FIRMWARE FILE]\AP_XXXXXX, [FILL IN THE FILE NAME] /sdcard/

4) Then boot up your device, set it up (minimally), download the magisk from below, (25.1-delta file) then install it. Then from the app, select Install Magisk > Patch from File then select the AP_XXXX file you've extracted from your firmware. Wait, for some minutes, and then see what is the file name.

5) Then pull the file and flash with Odin. (Download below) Use adb pull /sdcard/Download/magisk_patched-XXXX [See the magisk log for the file name] C:\Users\[your user]\Downloads\. Open Odin, select okay, when prompted, select AP, select the magisk_patched-XXXX file you've extracted from your phone, untick auto-reboot, then hit flash.

6) Go to stock recovery, again by pressing Volume Down +Power, then while connected to the PC, press Volume Up + Power then navigate via volume buttons and then press with power button, Wipe data/factory Reset

7) Turn off the phone (while connected to the PC) by pressing Volume Down + Power, then when turned off immediately press Volume Up + Volume Down. Go back to Odin, download the TWRP image below, and put it in AP slot and untick auto reboot. Then flash

8) Boot to recovery, by again Volume Down + Power, when turned off, Volume Up + Power, whilst connected to PC. ( See 6.) Now you've booted to TWRP Recovery. Go to Advance > Terminal then type multidisabler twice. (Very important)

9) Then download the GSI ROM you want to flash, extract it, then adb push it to your /sdcard/, just as you did with 3. (Here is a list of GSI's you can download) (Optional) Either use MTP or adb push to get into your device physwizz's kernel, and GApps (the guide will be in the second post, yet to find a way how to install it)

10) In the recovery, select Install > Install Image > select the GSI ROM's .img file you have, and select System Partition. (Optional) Then select Install Zip Then install physwizz's kernel.

11) Then, reboot, WAILA! There you have it, your own GSI ROM on your A127F U7 device. Enjoy

Credits: @physwizz, for his recovery and kernel ports. Without his hardwork, it wouldn't even be possible to install GSI for U7
Do i need to Root my device? Or is it possible to flash twrp and GSI only by bootloader unlocking?
 

Aunonno

New member
Jan 28, 2023
4
0
Dhaka
Thank you but i am worry to brick my phone. I unlocked my bootloader and try to flash twrp.img using adb fastboot but sadly it's stuck in "Sending files" on terminal i waited for an 1 hour but nothing happend it's just stuck in the same place. By the way i am using linux so Unfortunately Odin not gonna work i can use "Heimdall and Heimdall-Front" but problem is that it's way too much advance i mean for example let's say you wanna update this or any samsung model device firmware so you just have to goto Download Mood then in Odin you have to add [BL,AP,CP,CSC,HOME_CSC] and then flash.

I don't know you guys flash home_CSC or not but i used to did that when i use windows a long time ago. And for experiment purpose once upon a time i didn't add the Home_CSC file and Odin just factory Reset my Device. After that i always add that file Home_CSC.

I am not sure but i believe......
BL stands for Bootloader
AP stands for Android Partition.

But i don't know what the rest do i just want to use the latest Android OS without changing the Device. But anyway in heimdall things are not that easy you know you have change the ".tar.md5" file to ".tar" and then extract the files to folders now that's where i screwed up in youtube videos they are showing to flash custom rom so they just flash 1 file but as you know i have 5 ".tar.md5" files in 1 zip file what i am gonna do no tutorial for newer galaxy devices in both youtube and google. They only have information about "Galaxy S3". Which i never use but i believe that maybe that requires 1 file to flash to update the firmware not sure.

Anyway please let me know why it's stuck? And if you have any tutorial for heimdall based on newer samsung devices please let me know. "Thank You" :) :)

And i wish another thing which is in Computer World the way people move from one os to another if the same way we can switch in our mobile devices that would be go good i mean google release android 14 beta for their pixel phones and they also have a "Web Based Installer" where you can just connect your pixel phone and just flash google's next android but imagine what would happen if you and i can flash that same os on our device too? I mean if OEM create there hardware like Computers no matter which brand of smartphone you use pixel phone's one system for all device and then we don't need to worry about the bugs or for partition because when google release the update for their device we can update our phone with the same update. Oh and Galaxy A12 Nacho have "A" partition and most GSI out their support "A/B" partition so. :-(
 

TheWorldYT

Senior Member
Oct 23, 2021
235
28
HTC Wildfire S
Samsung Galaxy A20
Thank you but i am worry to brick my phone. I unlocked my bootloader and try to flash twrp.img using adb fastboot but sadly it's stuck in "Sending files" on terminal i waited for an 1 hour but nothing happend it's just stuck in the same place. By the way i am using linux so Unfortunately Odin not gonna work i can use "Heimdall and Heimdall-Front" but problem is that it's way too much advance i mean for example let's say you wanna update this or any samsung model device firmware so you just have to goto Download Mood then in Odin you have to add [BL,AP,CP,CSC,HOME_CSC] and then flash.

I don't know you guys flash home_CSC or not but i used to did that when i use windows a long time ago. And for experiment purpose once upon a time i didn't add the Home_CSC file and Odin just factory Reset my Device. After that i always add that file Home_CSC.

I am not sure but i believe......
BL stands for Bootloader
AP stands for Android Partition.

But i don't know what the rest do i just want to use the latest Android OS without changing the Device. But anyway in heimdall things are not that easy you know you have change the ".tar.md5" file to ".tar" and then extract the files to folders now that's where i screwed up in youtube videos they are showing to flash custom rom so they just flash 1 file but as you know i have 5 ".tar.md5" files in 1 zip file what i am gonna do no tutorial for newer galaxy devices in both youtube and google. They only have information about "Galaxy S3". Which i never use but i believe that maybe that requires 1 file to flash to update the firmware not sure.

Anyway please let me know why it's stuck? And if you have any tutorial for heimdall based on newer samsung devices please let me know. "Thank You" :) :)

And i wish another thing which is in Computer World the way people move from one os to another if the same way we can switch in our mobile devices that would be go good i mean google release android 14 beta for their pixel phones and they also have a "Web Based Installer" where you can just connect your pixel phone and just flash google's next android but imagine what would happen if you and i can flash that same os on our device too? I mean if OEM create there hardware like Computers no matter which brand of smartphone you use pixel phone's one system for all device and then we don't need to worry about the bugs or for partition because when google release the update for their device we can update our phone with the same update. Oh and Galaxy A12 Nacho have "A" partition and most GSI out their support "A/B" partition so. :-(
A/B GSI works fine. I can't help with heimdall as I don't have any knowledge on heimdall but I do on Odin, use the tutorial, it should work flawlessly, if not you could try my modified version and if it still doesn't work then you can always just revert to stock because this thankfully isn't mediatek, so it is hard to brick.
 
  • Love
Reactions: Aunonno
Jan 5, 2018
19
2
Here is a tutorial that worked perfectly, and is probably useful for people having errors (especially for new people).

1. Unlock the bootloader.
2. Patch the firmware with Magisk 25.1 Patched APK.
3. Flash the Magisk-patched firmware in the AP slot.
4. Boot the phone and set up minimally (Without wifi)
5. Factory reset in the stock recovery.
6. Flash the TWRP binary (only works for A12 U7 Binary)
7. Boot to TWRP.
8. Go to Advanced > Terminal and type multidisabler (sometimes you need to do it twice if it tells you to)
9. Push the .img file to your /sdcard/ or Internal storage
10. Rename the .img file to system.img then copy the ChonDoe_Flasher.zip file at post #2 in the directory where the .img file is, then flash the ChonDoe_Flasher.zip as a zip file.
11. Wipe data (not Format Data) in TWRP. (Optional but recommended)

12: Done! Reboot your phone now.

Patched Magisk 25.1 APK:
Will this solve the touch issue on a127f?
 
  • Love
Reactions: Aunonno

Top Liked Posts

  • There are no posts matching your filters.
  • 1
    Here is a tutorial that worked perfectly, and is probably useful for people having errors (especially for new people).

    1. Unlock the bootloader.
    2. Patch the firmware with Magisk 25.1 Patched APK.
    3. Flash the Magisk-patched firmware in the AP slot.
    4. Boot the phone and set up minimally (Without wifi)
    5. Factory reset in the stock recovery.
    6. Flash the TWRP binary (only works for A12 U7 Binary)
    7. Boot to TWRP.
    8. Go to Advanced > Terminal and type multidisabler (sometimes you need to do it twice if it tells you to)
    9. Push the .img file to your /sdcard/ or Internal storage
    10. Rename the .img file to system.img then copy the ChonDoe_Flasher.zip file at post #2 in the directory where the .img file is, then flash the ChonDoe_Flasher.zip as a zip file.
    11. Wipe data (not Format Data) in TWRP. (Optional but recommended)

    12: Done! Reboot your phone now.

    Patched Magisk 25.1 APK:
    Will this solve the touch issue on a127f?
  • 1
    Hello, today I'll be guiding you to how to install LineageOS or other GSI ROMs on your A127F U7 device.

    First, some precaution:
    Rich (BB code):
    /*
    * knox_warranty_void: 0x01
    *
    * Your warranty is now void.
    * I am not responsible for bricked devices, dead SD cards,
    * thermonuclear war, or your getting fired because the alarm app failed. Please
    * do some research if you have any concerns about features included in this ROM
    * before flashing it! YOU are choosing to make these modifications, and if
    * you point the finger at me for messing up your device, I will laugh at you.
    */

    Requirements:
    Code:
    * Unlocked bootloader
    * Your device's firmware
    * Android's platform tools.
    * Magisk
    * Odin
    * U5, U6, U7 TWRP
    * GSIs Image for the ROM you want to download
    * physwizz's kernel

    1) The first step you want to do is, unlock your bootloader. You can simply do that by enabling OEM Unlocking in Developer settings, (Can be unlocked by going to Settings > About Phone > Software Information > tapping "Build Number" 5 times then booting to download mode. (Connect to PC, shutdown your phone, then hold volume up and down buttons, then when you're on the download screen, hold volume up., then press volume up again) WARNING: THIS WILL ERASE YOUR DATA AND PERFORM A FACTORY RESET, SO BACKUP YOUR DATA WHEN NECESSARY.

    2) Then, download the firmware you have for your firmware. How? Try visiting sites like samfw and find your firmware by searching A-127F and finding your country's baseband. Then download through your preferred method of downloading. Mine I login to Google, and downloaded through Google Drive, which is faster. (Though it will personally copy the firmware's file to you Google Drive and occupy space on it, so beware of that and delete the file afterwards, the file is in DRIVE > samfw_temporary_folder_dont_delete I assume it's safe to delete after download, so there's that.)

    3) Extract the file, and adb push the AP_XXXXX file to your device. How? Download the Android platform tools to the above hyperlink, then extract it, go to the file and then type: e.g adb push [DIRECTORY WHERE YOU EXTRACTED YOUR FIRMWARE FILE]\AP_XXXXXX, [FILL IN THE FILE NAME] /sdcard/

    4) Then boot up your device, set it up (minimally), download the magisk from below, (25.1-delta file) then install it. Then from the app, select Install Magisk > Patch from File then select the AP_XXXX file you've extracted from your firmware. Wait, for some minutes, and then see what is the file name.

    5) Then pull the file and flash with Odin. (Download below) Use adb pull /sdcard/Download/magisk_patched-XXXX [See the magisk log for the file name] C:\Users\[your user]\Downloads\. Open Odin, select okay, when prompted, select AP, select the magisk_patched-XXXX file you've extracted from your phone, untick auto-reboot, then hit flash.

    6) Go to stock recovery, again by pressing Volume Down +Power, then while connected to the PC, press Volume Up + Power then navigate via volume buttons and then press with power button, Wipe data/factory Reset

    7) Turn off the phone (while connected to the PC) by pressing Volume Down + Power, then when turned off immediately press Volume Up + Volume Down. Go back to Odin, download the TWRP image below, and put it in AP slot and untick auto reboot. Then flash

    8) Boot to recovery, by again Volume Down + Power, when turned off, Volume Up + Power, whilst connected to PC. ( See 6.) Now you've booted to TWRP Recovery. Go to Advance > Terminal then type multidisabler twice. (Very important)

    9) Then download the GSI ROM you want to flash, extract it, then adb push it to your /sdcard/, just as you did with 3. (Here is a list of GSI's you can download) (Optional) Either use MTP or adb push to get into your device physwizz's kernel, and GApps (the guide will be in the second post, yet to find a way how to install it)

    10) In the recovery, select Install > Install Image > select the GSI ROM's .img file you have, and select System Partition. (Optional) Then select Install Zip Then install physwizz's kernel.

    11) Then, reboot, WAILA! There you have it, your own GSI ROM on your A127F U7 device. Enjoy

    Credits: @physwizz, for his recovery and kernel ports. Without his hardwork, it wouldn't even be possible to install GSI for U7
    1
    How to install GApps.

    Method 1 (tested and worked):

    Download the A/B Google Apps VNDK Secure variant of Lineage. (In AndyYan's sourceforge page it would be bgS-vndk-secure):

    extract the file as usual, and then rename the file as system.img.

    Download the attachment below.

    adb push both files to your /sdcard/ or any folder you prefer within /sdcard. (Though the files must be in the same directory) i.e. adb push system.img ChonDoe_Flasher.zip /sdcard

    Go to TWRP > Install then select the ChonDoe_Flasher.zip,

    and WAILA, you have now a working LineageOS with Gapps, it might work with other ROMs too!

    Method 2, will post when I have tested it.

    Credits: @chondoe for his flasher


    --- Theory for flashing twice (disproven, you only need to flash once, here for archive purposes, you don't need to read it if you're not interested):
    Go to TWRP > Install then select the ChonDoe_Flasher.zip, TWICE. Do not reboot only doing it once, or else it might bootloop. After flashing once, go back and then do it again. (If you accidentally did it once, tell me if it worked and I'll post the results)

    (EXPLAINED: This is a theory of mine, though, I didn't test doing it only once, I'll try to do it once if I ever go back to stock ROM and see if it only requires once, but as of now I tried doing it twice and it worked [the logic behind this is, if you install the .img alone, it will boot-loop due to lack of storage, but the flasher uses e2fsck and resize2fs so along the process, it expands the file system and thereby allowing more space for installation. I theorize doing this once will not work because the script first installs/flash the .img before using e2fsck and resize2fs and therefore still lacks the file system space that it needs to boot, but if you do it twice, you will have already executed the two binaries and thereby allow space for a proper installation of the .img, so it will now boot and not get stuck on an infinite bootloop.])
    1
    and if i have one ui 4.1 and u7 brinary i still can install it, and in the downloads it says twrp-a127f-u5 brinary?
    yes, the U5 binary TWRP is compatible with U6 and U7
    1
    and in this TWRP can i install zip file custom rom?
    Yes, but the custom ROM is in .img format. See post #2 if you want to install a ROM