[RECOVERY][OFFICIAL] TWRP for Galaxy A40 [A405FN]

Search This thread

Lada333

Senior Member
Feb 7, 2016
1,280
418
22
Budapest
OnePlus 3T
Google Pixel 4a
I kinda feel lost.
I have a A405FN, on Android 10.

Ticked OEM unlocking, went to download mode, unlocked bootloader. Everything worked fine until step 6 - fastboot couldn't find my device (I read in some other thread that Samsung may have done something in an update that broke this), so I flashed TWRP tar to AP in Odin.
I managed to get into TWRP, flash TWRP img to recovery, kernel img to boot, however I'm not sure to which partition do I flash vbmeta.img (is it even possible to do via TWRP?)

And this is where I'm stuck. I can get into TWRP no problem, but it seems like it doesn't have write permission? No matter what ROM I try to flash, it says it succeeded, but then when I try to reboot, I get and error saying "no OS installed."

I also tried creating a .tar with recovery, kernel and vbmeta in it, and flash that to AP in Odin, but it would just get stuck.

Could anybody help me out?
 

Lada333

Senior Member
Feb 7, 2016
1,280
418
22
Budapest
OnePlus 3T
Google Pixel 4a
excuse me, why you're talking about fastboot?
step7 is download mode...

Isn't it the same thing? I've installed custom ROMs and recoveries on a few phones, I figured the terms can be used interchangeably.
I assumed I'd have to use "fastboot flash <filename>," I also saw the line "fastboot --disable-verity --disable-verification flash vbmeta vbmeta.img" in another thread.

Either way, how am I supposed to flash those 3 things mentioned @ step 7 then?
 

Lada333

Senior Member
Feb 7, 2016
1,280
418
22
Budapest
OnePlus 3T
Google Pixel 4a
you can change a few files with '7-Zip ZS' into only one .tar and flash it via odin into AP
I did that though? I ran a search in this thread, and based on this reply from OP, I compressed recovery, kernel and vbmeta
into one .tar file, but when I tried to flash it to AP in Odin, the process got stock?

In the log window, it told me that it's installing boot.img, but it was stuck at 0% in Odin, and there was no progress bar on the phone in download mode.
 

Lada333

Senior Member
Feb 7, 2016
1,280
418
22
Budapest
OnePlus 3T
Google Pixel 4a
step 5 'internet connection' is very important.. have you done this?

(you can also do it within step 6)
After unlocking the bootloader, all data was wiped, then I let the phone boot back into Android - I connected to my WiFi (I'm not sure if there was a sim card in the phone (there was, iirc), either way, it had access to the internet via WiFi), didn't log into Google or Samsung Account or anything, I just finished up with the setup wizard, and rebooted after I was greeted with the homescreen.
So yes, I do believe I have done that step properly.
 

ghostdog111

Member
May 14, 2020
16
4
maybe it will help if you start all steps from 1.) again, exactly.
or someone else can help you with this..
sry,
kind regards and good luck🍀
 

Gliwusss

Member
Oct 13, 2013
16
1
Hi!
I was not messing with my phone since 3 years, cause i had mate 20 lite which bootloader cannot be unlocked so im kid in flashing android >5. I have sm-a405fn with newest android 10. I want to root it which is not possible without twrp as i know (method with patching vmbeta by magisk not work for me, magisk can't patch file). I have bootloader unlocked. How can i flash twrp and root my phone step by step?


Update: nevermind, somehow I did it myself. I have installed recovery from this thread, next messed with multidisabler, other DRM disabler and magish, I flashed one by one, when I turn on phone It was stuck,bootloop no even samsung logo. I thought i bricked it. Next i have installed ALT-F4 rom and everything is working. I flashed magisk via twrp and I have root too :)
Screenshot_20210223-014034.jpg
 
Last edited:

Pawelek94

New member
Mar 5, 2021
1
0
Hi everyone!
I have some problem. After doing everythink from post my soft stuck on samsung logo and i dont know why. I was trying 5 times to do that and in the end always system stuck on logo After flashing in twrp multidisabler and click reboot. Maybe i have bad multidisabler? Please help :) SOFT BTK4.
 
Last edited:

k44mos

Senior Member
Jun 28, 2015
92
3
Italy
linktr.ee
i have a big problem about twrp on my phone
I have followed this thread
But when i flash twrp (i have uncheck "reboot" on odin of course) i can't get access to the recovery mode, when i do power button + volume up it doesn't do nothing and show this :
https___i-postimg-cc_907fjwgk_booting-warning-jpg.5459

orig_svb_orange-jpg.5460

(I have already unlock my boot loader)
I think its DM VERITY who block the access to recovery mode but i can't disable this, cause i can't get access to twrp :/
Thanks for any answers c:

I have the same problem after installing twrp-3.5.0_9-0-a40.img via Odin.

I also tried other versions but failed.

Any help?
 

mr-browns

Member
Mar 15, 2021
13
0
Moto G 2015
Xiaomi Redmi Note 7
Team Win Recovery Project 3.5.1
View attachment 5254385

Special Notes:
  1. DON'T FORGET TO ENABLE "OEM UNLOCK" (located in Developers options)
  2. KNOX will be tripped once you flash custom binaries to your phone. Your warranty may be voided. However this may not affect you if your country forces Samsung to provide hardware warranty regardless of software status
  3. Samsung Firmware OTA (aka System Updates) will no longer work once you flash custom binaries. You can flash custom ROMs if you want to keep the OS up-to-date
  4. All apps that use KNOX like Samsung Pay, Secure Folder and maybe more will no longer work
Download:
Changelog:
  • 03.05.2020
    • Rebased kernel source to BTB8
  • 25.04.2020
    • Rebased kernel source to ATA4
    • MTP has been fixed!! Builds are now splitted into AOSP and Samsung. Choose yours based on the type of ROM you use for MTP to work properly
  • 07.12.2019
    • Initial Release
Guide:
  • If you already have a custom recovery installed:
    1. Boot to your custom recovery
    2. Flash the recovery image
  • If you are starting from scratch:
    1. Go to Developer Settings and enable "OEM Unlock" option
    2. Power off the device and boot in download mode
    3. In download mode, you will see the long press and volume up option to unlock the bootloader
    4. Unlock the bootloader. That will wipe your device so be sure you made a backup of your data
    5. After bootloader unlock, boot up the phone and make sure it is connected to the internet or it will trigger rmm prenormal
    6. Setup the phone without google account and others
    7. Reboot in download mode and flash the recovery and vbmeta images
    8. Boot to TWRP
    9. Format data in TWRP
    10. Flash the Multidisabler zip
    11. Now you can reboot
XDA:DevDB Information
Team Win Recovery Project, Tool/Utility for the Samsung Galaxy A Series

Contributors
ponces, geiti94, ianmacd
Source Code: https://github.com/TeamWin/android_device_samsung_a40
Kernel Source Code: https://github.com/ponces/android_kernel_samsung_universal7904

Version Information
Status:
Stable

Created 2019-12-26
Last Updated 2021-03-19
Hello!How did you flash the twrp recovery and vbmeta software?Are you using ODIN software and Windows PC? With the so called "fastboot mode" there is no way to flash the twrp recovery- no matter if I use Windows PC and terminal (cmd) or if I use Linux and terminal.
 

alexnonim

Member
May 2, 2021
12
3
I flash with Odin the twrp and now I have a error error validating footer (6) on download mode in lopp! Please help

PD: Flahed stock firmware and now working.
 
Last edited:

Top Liked Posts

  • There are no posts matching your filters.
  • 16
    Team Win Recovery Project 3.6.1
    TWRP-Feature-Image-810x298_c.png


    Special Notes:
    1. DON'T FORGET TO ENABLE "OEM UNLOCK" (located in Developers options)
    2. KNOX will be tripped once you flash custom binaries to your phone. Your warranty may be voided. However this may not affect you if your country forces Samsung to provide hardware warranty regardless of software status
    3. Samsung Firmware OTA (aka System Updates) will no longer work once you flash custom binaries. You can flash custom ROMs if you want to keep the OS up-to-date
    4. All apps that use KNOX like Samsung Pay, Secure Folder and maybe more will no longer work
    Download:
    Changelog:
    • 21.10.2021
      • Rebased kernel source to CUH4
    • 16.06.2021
      • Rebased kernel source to CUC2
    • 03.05.2020
      • Rebased kernel source to BTB8
    • 25.04.2020
      • Rebased kernel source to ATA4
    • 07.12.2019
      • Initial Release
    Guide:
    • If you already have a custom recovery installed:
      1. Boot to your custom recovery
      2. Flash the recovery image
    • If you are starting from scratch:
      1. Go to Developer Settings and enable "OEM Unlock" option
      2. Power off the device and boot in download mode
      3. In download mode, you will see the long press and volume up option to unlock the bootloader
      4. Unlock the bootloader. That will wipe your device so be sure you made a backup of your data
      5. After bootloader unlock, boot up the phone and make sure it is connected to the internet or it will trigger rmm prenormal
      6. Setup the phone without google account and others
      7. Reboot in download mode and flash the recovery and vbmeta images
      8. Boot to TWRP
      9. Format data in TWRP
      10. Flash the Multidisabler zip
      11. Now you can reboot

    Contributors
    ponces, geiti94, ianmacd
    Source Code: https://github.com/TeamWin/android_device_samsung_a40
    Kernel Source Code: https://github.com/ponces/android_kernel_samsung_universal7904
    6
    Good news everyone!
    I finally have a working build with a proper fix!

    I was so wrong and this all hapened because Samsung has decided to finally fix in their firmware files the name of the SoC that our devices has. So, due to this, exynos7885 is no longer mentioned but instead it is exynos7904. This name change affected some filenames in the kernel, boot and recovery. One of the examples is the fstab as @tys0n correctly mentioned. The file that exports the ANDROID_ROOT variable was also affected and this was the main problem.

    Go grab the new builds in the OP! The Multidisabler zip is also fixed as now we will be using ianmacd's version.
    4
    I made a file with TWRP + boot.img + vbmeta for the step 7, so if someone is interested, you can download it here .
    Just flash it with Odin in AP slot.
    Please make sure you are on the latest firmware (CUD3)
    4
    this is what i did ... create a tar file with twrp, boot and vbmeta inside.
    Go to Settings >> About phone >> Software version and then tap the build number for about 10 times to enable developer mode. Once enabled, you will see the message "You are now a developer" on the screen.
    Go back to the main Settings screen and look for Developer Options. Inside you will find OEM unlocking and USB debugging. Enable both options by tapping the switch.
    Now turn off your smartphone and start the download mode. You can do this by pressing the Volume Up and Volume Down buttons simultaneously for a couple of seconds.
    Note: While using the above combination, you need to connect your device to your computer via the USB cable.
    Another note: make sure all necessary drivers are already installed on your computer. If not, the desktop will not detect the smartphone.
    After step 3, you should now be able to see the download mode with a large warning text written at the top of the screen.
    Now, long press the Volume Up button to unlock the device bootloader. You will now be redirected to a confirmation screen. Press Volume Up to proceed with the unlock mode.
    Your smartphone will restart and a Bootloader unlock message will appear on the screen. Acknowledge it and continue further by pressing the power key.
    Note: All your data will now be deleted. Hopefully, you've followed our tip and created a full backup.
    You will now see the device setup screen. Complete it without linking any Google or Samsung account. You can also skip installing the app.
    Once you are on the home screen, enable Developer Options as mentioned in step 1 of the guide.
    Now open developer options and look for OEM unlock. The option should be disabled
    Make sure the USB Debugging option is enabled on your smartphone.
    Download the Odin software and extract it to your computer. You should now be able to see the Odin Exe file after extraction. Run it as an administrator.
    Note: You may receive a popup related to ADB drivers. Let the update process finish automatically.
    Now restart your phone in download mode and while doing this connect your smartphone to the desktop. You can follow step 3 of the Unlock Bootloader guide to do that.
    Once the phone is connected to the computer and is in Download mode, you will be able to see the blue mark on the Odin software. This means that the software has detected your smartphone.
    add the previously created .Tar file to the Odin software by pressing the AP button.
    Note: Make sure Re-Partition and Auto Reboot is unchecked. You can find it in the options menu.
    Now, hit the Start button to start the flashing process. This will take a couple of seconds so that you can sit back and relax.
    Once the whole flashing process is complete, you will see the Pass message on the screen somewhere.
    How to exit download mode and enter TWRP recovery?
    To exit download mode and access TWRP recovery, you can hold down the Volume Down and Power keys simultaneously. When the screen goes blank for a few seconds, ...you need to release the Volume Down key and then quickly switch to the Volume Up button. When TWRP recovery appears, you can release all keys at the same time.

    Once you are inside TWRP recovery, go to the Wipe option and then tap on the Format Data option. Type Yes to continue.
    Once the deletion is finished, go back to the main menu in TWRP recovery and tap the Restart button.
    Within the Restart option, tap on the Recovery option. This will reboot you into custom recovery.
    Now you need to install the multidisabler file using the Install option. Once the file has been updated, you can restart your smartphone.
    Note: You need to flash the Multidisabler file using TWRP recovery.
    3
    Just to let you all know that we now have official builds of TWRP !! :D