• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!

Development [ROOT] [TWRP] [KERNEL] [GSI] for SM-A127f (a12s)

Search This thread

physwizz

Senior Member
Sep 16, 2013
3,307
724
Sydney
Didn't try all the intricate ways yet (reflashing the stock firmware, then Magisk-patch it all, etc.) but the simplest, which is use Odin over whatever I have (LineageOS that is with the stock recovery) and flash, fails for me. It just hangs forever on the Sam logo screen. Interesting thing: LineageOS hangs on the boot animation if I am using the "purged" vbmeta (and I have to use it to flash TWRP, of course, otherwise Download gets excited over missing signatures). Theoretically it shouldn't affect anything at this stage of the booting process but it does.
Thanks.
Is your device made in Vietnam or India?
There seems to be some difference.
 

physwizz

Senior Member
Sep 16, 2013
3,307
724
Sydney
@uluruman
2 more versions here.
 

uluruman

Senior Member
Oct 23, 2021
82
8
Thanks.
Is your device made in Vietnam or India?
There seems to be some difference.
It's Vietnam. I have flashed the stock firmware and tried all the three versions in a row, so summing it all up:
  1. afaneh-u3-vt-test: freezes on the Sam logo screen
  2. afaneh-u3-vt2: reboots on the Sam logo screen
  3. afaneh-u3-in3: starts okay
What works for me in "afaneh-u3-in3":
  1. Mounting "System" (at last!), "Vendor", "Product", "ODM", "Metadata", "Cache"
  2. MTP (in Linux, at last!)
What does not work:
  1. Mounting "Data" (!)
  2. Screen freezes after wake-up (as usual, is there a solution?)
  3. Installing "multidisabler-samsung-3.1" is all the same: freeze on the Sam logo screen, recovery becomes inaccessible
 
  • Like
Reactions: ANDARXapi

physwizz

Senior Member
Sep 16, 2013
3,307
724
Sydney
It's Vietnam. I have flashed the stock firmware and tried all the three versions in a row, so summing it all up:
  1. afaneh-u3-vt-test: freezes on the Sam logo screen
  2. afaneh-u3-vt2: reboots on the Sam logo screen
  3. afaneh-u3-in3: starts okay
What works for me in "afaneh-u3-in3":
  1. Mounting "System" (at last!), "Vendor", "Product", "ODM", "Metadata", "Cache"
  2. MTP (in Linux, at last!)
What does not work:
  1. Mounting "Data" (!)
  2. Screen freezes after wake-up (as usual, is there a solution?)
  3. Installing "multidisabler-samsung-3.1" is all the same: freeze on the Sam logo screen, recovery becomes inaccessible
can you send me your stock recovery.img? (zip it first)
 

physwizz

Senior Member
Sep 16, 2013
3,307
724
Sydney
It's Vietnam. I have flashed the stock firmware and tried all the three versions in a row, so summing it all up:
  1. afaneh-u3-vt-test: freezes on the Sam logo screen
  2. afaneh-u3-vt2: reboots on the Sam logo screen
  3. afaneh-u3-in3: starts okay
What works for me in "afaneh-u3-in3":
  1. Mounting "System" (at last!), "Vendor", "Product", "ODM", "Metadata", "Cache"
  2. MTP (in Linux, at last!)
What does not work:
  1. Mounting "Data" (!)
  2. Screen freezes after wake-up (as usual, is there a solution?)
  3. Installing "multidisabler-samsung-3.1" is all the same: freeze on the Sam logo screen, recovery becomes inaccessible
Data is not supposed to be on the mount list.
8. Wipe, format data, type YES.
9. Advanced, terminal.
10.Type multidisabler (twice).
11.Reboot to recovery
 

physwizz

Senior Member
Sep 16, 2013
3,307
724
Sydney
U3 and U4 kernel here for testing


@uluruman
 
Last edited:

ANDARXapi

Member
Nov 30, 2021
20
2
Samsung has posted the kernel sources for the U3 loader, please make TWRP for the U3 version of the loader
 

physwizz

Senior Member
Sep 16, 2013
3,307
724
Sydney
Working TWRP for u3/u4

 
Last edited:

physwizz

Senior Member
Sep 16, 2013
3,307
724
Sydney
Orange Fox recovery

 

TheWorldYT

Member
Oct 23, 2021
48
4
physwizz a12s kernel version 4
Based on a127f U1 binary

For OneUI 3.1
( also works for GSIs)


Samsung securities disabled
More CPU governors
Conservative, On-demand, Userspace, powersave, performance, energy_step, shedutil
Optimised for performance
Overclocked for performance
Underclocked for battery
CPU: 130MHz - 2210MHz
lz4 compression added to zram
Ready for spectrum installation

Installation
Method 1
Install from TWRP


Method 2
Install adb tools on pc
Connect to PC
Copy zip file to adb folder on pc
Open terminal on pc
Navigate to adb folder
Type
adb sideload name.zip


For Zram
Go to HKtweaks- virtual memory
Turn off zram
increase swappiness to 200
choose lz4
increase size to 4096
turn on Zram


Kernel

@physwizz
for a127f/dsn u4 is there any way to get Resurrection Remix OS, or CrDroid, etc?
 

TheWorldYT

Member
Oct 23, 2021
48
4
I can now totally confirm that the afaneh92's TWRP image, as well as edward0181's, does not work on the Vietnam-made SM-A127F/DSN: I've rooted it, installed TWRP app, flashed the recovery.img from the app and rebooted into recovery using adb. I'm still getting just endless reboots. So this time the experiment was clean and the "wrong key pressed at wrong time" factor was completely excluded. I'm just curious why any stock firmware and the stock recovery tools works just fine? I've already tried many different country-specific versions from that list and they all flash and work perfectly.

P.S.: By the way, I've built the latest Magisk from the git master and it works great, so no patched version needed.
i have the same device as you. it works perfectly for me, maybe you did something wrong.
 

uluruman

Senior Member
Oct 23, 2021
82
8
i have the same device as you. it works perfectly for me, maybe you did something wrong.
I have already solved all the problems and installed everything. Although it was a long and winding way. The main problem was that I have the U3 baseband version. Now thanks to physwizz there are versions of the recovery and kernels for U3 and U4 available, and those work great, plus there is my own script for repackaging super.img with any GSI OS.
 

uluruman

Senior Member
Oct 23, 2021
82
8
I installed pixel experience and lineages but I found them slow
Well, people install LineageOS mostly not for performance but for freedom from bloatware and spyware components. But I personally don't find it sluggish either, in fact for me it's definitely more responsive than the stock firmware and does not have several annoying issues, such as non-removable pop-ups in the stock messaging app.
 
Last edited:

Top Liked Posts

  • There are no posts matching your filters.
  • 2
    Thanks physwizz! With these new recoveries I finally got TWRP booting! I've formatted data okay, have the sdcard accessible after that and a reboot, but now the next problem: a lot of "Unable to find partition for path '/system_root'" messages. And indeed, there is no "system_root" partition entry in fstab. Also the "Mount system partition read-only" checkbox in the Mount section is unresponsive and remains always checked. Any ideas?
    Agh, finally, I found combination, that works for me.
    I have spent days and physwizz hours PMing with me to double, triple check, if I missed some point. It still remain mysterious, why steps leads to different results, as a novice, I can just speculate, if there is some tiny important difference between A127F/DS and A127F/DSN. Or, well.... what about starting "Stock ROM" we are different.

    But there have been some clues.
    Afaneh92's TWRP, it can boot for me, but there has been two things that stink for me. Select Storage - shown Internal storage 0MB capacity and unmountable Data partition, that even if it reports 0MB size, cannot as an empty be backuped, for example. Reboots after proper steps (Format data) leads to slow bootlooping (10mins, I guess Android factory reset trying to finish with some bug in the end).

    Newest TWRP - that one reported lasttime, Srilanka user, it can in some point (physwizz remount command) starts to report Storage size, even Data partition, but installing multidisabler didnt worked for me, leads to Cannot install zip file error. So, not surprise, after data format and reboot, it lead to nothing, well I can just speculate it that un-disabled encryption. Physwizz advice to remount solves part of red colors anout system root.

    I combine those TWRP, using both for part of the job.
    1. Rebooted to Afaneh92 TWRP,
    2. run remount command
    3. run multidisable twice
    4. Reboot directly to download mode
    5. flash SriLankas TWPR, and boot it
    6. Remount command, Format data
    7. Reboot

    voila, system starts, initiate standard default process. Srilankas TWRP can backup all partition I want (including /data). All done.

    I have no idea, if this procedure will help others and will work in other conditions, thats the task for you guys, much much advanced than me. I have just some unclear imagination, whats those steps are about, but there has to be something unfinished with afanehs twrp, that prevent it to work OK in some conditions (hardware, original but regional stock rom)

    Let others know, if it worked for ya.
    HzK
    1
    I can now totally confirm that the afaneh92's TWRP image, as well as edward0181's, does not work on the Vietnam-made SM-A127F/DSN: I've rooted it, installed TWRP app, flashed the recovery.img from the app and rebooted into recovery using adb. I'm still getting just endless reboots. So this time the experiment was clean and the "wrong key pressed at wrong time" factor was completely excluded. I'm just curious why any stock firmware and the stock recovery tools works just fine? I've already tried many different country-specific versions from that list and they all flash and work perfectly.

    P.S.: By the way, I've built the latest Magisk from the git master and it works great, so no patched version needed.
    1
    Orange Fox
    From @(Sri Lanka)

    (MTP not working)

    Installation
    Unzip files
    Extract recovery.img

    Method 1.
    If you have already installed afaneh92 TWRP and decrypted.
    1. Boot to recovery.
    2. Install recovery.img
    3. Choose recovery partition
    4. Reboot to recovery

    Method 2.
    From the start

    1. Download firmware
    2. Extract ap file.
    3. Patch with magisk
    4. Flash with Odin
    5. Download recovery.img
    6. Install TWRP app
    7. Install TWRP
    8. Choose file to flash.(don't select device)
    9. Select recovery.img.
    10. Reboot to recovery.
    11. Format data
    12. Install multidisabler zip
    Or dmverity
    13. Reboot to recovery
    Done


    @physwizz
    1
    Agh, finally, I found combination, that works for me.
    I have spent days and physwizz hours PMing with me to double, triple check, if I missed some point. It still remain mysterious, why steps leads to different results, as a novice, I can just speculate, if there is some tiny important difference between A127F/DS and A127F/DSN. Or, well.... what about starting "Stock ROM" we are different.

    But there have been some clues.
    Afaneh92's TWRP, it can boot for me, but there has been two things that stink for me. Select Storage - shown Internal storage 0MB capacity and unmountable Data partition, that even if it reports 0MB size, cannot as an empty be backuped, for example. Reboots after proper steps (Format data) leads to slow bootlooping (10mins, I guess Android factory reset trying to finish with some bug in the end).

    Newest TWRP - that one reported lasttime, Srilanka user, it can in some point (physwizz remount command) starts to report Storage size, even Data partition, but installing multidisabler didnt worked for me, leads to Cannot install zip file error. So, not surprise, after data format and reboot, it lead to nothing, well I can just speculate it that un-disabled encryption. Physwizz advice to remount solves part of red colors anout system root.

    I combine those TWRP, using both for part of the job.
    1. Rebooted to Afaneh92 TWRP,
    2. run remount command
    3. run multidisable twice
    4. Reboot directly to download mode
    5. flash SriLankas TWPR, and boot it
    6. Remount command, Format data
    7. Reboot

    voila, system starts, initiate standard default process. Srilankas TWRP can backup all partition I want (including /data). All done.

    I have no idea, if this procedure will help others and will work in other conditions, thats the task for you guys, much much advanced than me. I have just some unclear imagination, whats those steps are about, but there has to be something unfinished with afanehs twrp, that prevent it to work OK in some conditions (hardware, original but regional stock rom)

    Let others know, if it worked for ya.
    HzK
    Glad it now works.
    What a mammoth effort.
    The a127f/DSN is different in some way from a127f (I have a single Sim)

    Now see if you can install my kernel v4
    1
    I'll try the honzazkrumlova method. But I can't use the Afaneh92's TWRP anyway.