I don't want to compare apples with oranges but:
Recovering from Xiaomi brick: 2 minutes (Xiaomi devices are literally unbrickable. You can fastboot flash any of your partitions thousands of times within minutes on any operating system that has fastboot. You can throw the Xiaomi device against a brick wall and it will still work just fine! The latter is not recommended though ; )
Recovering from the same kind of brick on a Samsung device: 48 - 72 hours.
Xiaomi device have fully working fastboot straight out of the box
Samsung device have empty crippled fake fastboot out of the box
Now you decide which manufacturer is more open source and developer friendly
I don't want to compare apples with oranges but:
Recovering from Xiaomi brick: 2 minutes (Xiaomi devices are literally unbrickable. You can throw it against a brick wall and it will still work just fine! Not recommended though ; )
Recovering from Samsung brick: 48 - 72 hours.
Xiaomi device have fully working fastboot straight out of the box
Samsung device have empty crippled fake fastboot out of the box
Now you decide which manufacturer is more open source and developer friendly
Thanks for the quick reply.
I finally got the phone back up and running by flashing the full firmware with Odin.
Thank god this nightmare is now finally over. What's the best way to root this thing without bricking your device? Thanks
Assuming you already unlocked your bootloader, flash the modified VBMeta @Cheese-ass provided here to disable Verified Boot (It's for a different phone but it works for the A22 5G, I tested). Reboot and your phone will ask you to factory reset, then set up your phone as you usually would, and install the Magisk app.
Back on your PC, use 7zip to open the AP.md5 file, and copy the boot.img.lz4, then download lz4 (Find out whether your PC is 32 bit or 64 bit then download the appropriate one) and extract the archive. Open the extract folder until you find lz4.exe, then click the Directory path (see attachment) and type in cmd to open a Command Prompt. Run lz4 boot.img.lz4 boot.img to extract the boot.img. The reason why you use lz4 and not a normal archiver like WinRar or 7zip is because you can't extract it using those, try it yourself.
Now transfer your boot.img to your phone using MTP, FTP or something, patching it using Magisk, then transfer the Magisk patched one to your PC. Rename it boot.img (IMPORTANT, or else Odin won't know what to flash it to). Right click on the Magisk patched boot image > 7zip > Add to archive... > and choose tar as the archive format. Reboot your phone to Odin mode, open Odin (or Heimdall), and select the boot image .tar and flash. Magisk should now be installed.
Turns out my bootloop problem was caused by Heimdall or by my lack of knowledge in using it properly. Is it still maintained or is it EOL ?
The Heimdall tutorials want me to write --VBMETA in capital letters when flashing but Heimdall says that partition VBMETA doesn't exist in my device's PIT file heimdall flash --VBMETA vbmeta.img --no-reboot
I can flash successfully if I type --vbmeta in small letters but then something gets corrupted somewhere along the process. heimdall flash --vbmeta vbmeta.img --no-reboot
Wait a second maybe I must flash the .tar file in Heimdall just like in Odin? So far I've only been flashing the raw .img files directly. Maybe that's where my bootloops come from?
I would definitely recommend flashing Samsung devices the official way with Odin
Rename the file to vbmeta.img and compress it as a tar and just flash in AP slot with Odin. Works great every time and it's a very straight forward process. Thanks to the guy who suggested this method to me
By the way can we use Odin in Linux through Wine?
To anyone out there who ended up in a tricky and very dark Samsung bootloop. Samsung made it especially difficult to get into Download mode when stuck in such a bootloop. Here's a quick tutorial:
Phone must be off for this to work!
The trick is to press both Volume Up & Volume Down & Power buttons & plug in USB cable (which is connected to pc) . YES! ALL AT THE SAME TIME! I KNOW IT'S CRAZY!
As soon as you feel the phone vibrate, let go of power button but keep vol+ and vol- buttons still pressed! Then when Download mode screen appears let go of both volume buttons and press vol up to get into flashing mode.
Out of all phone manufacturers out there this has got to be the most difficult und developer unfriendly way to get into flashing mode for flashing an android device.
This is how I turn device off if I'm stuck in a very nasty Samsung bootloop:
Plug in usb cable & at the same time press vol+ & vol- & power buttons for about 12 seconds!
If I don't feel the vibration I know phone is not off but I keep the button combination pressed anyways for about 12 seconds until the charger symbol appears (due to usb cable charging the device). In this very moment I let go of all buttons and immediately disconnect usb cable from device. Congratulations! Now your device is off! I know this sounds stupid but that's all the steps I must do to turn off device when stuck in such an annoying Samsung bootloop! I hope this helps someone out there to save some precious time!
Now you can proceed to get into Download mode the usual way by pressing all those aforementioned buttons together & plugging in usb cable simultaneously! Good luck!
Turns out my bootloop problem was caused by Heimdall or by my lack of knowledge in using it properly. Is it still maintained or is it EOL ?
The Heimdall tutorials say to write in capital letters --VBMETA when flashing but my device says that partition VBMETA doesn't exist in my PIT file heimdall flash --VBMETA vbmeta.img --no-reboot
I can flash successfully if I type in small letters --vbmeta but then something gets corrupted somewhere along the process. heimdall flash --vbmeta vbmeta.img --no-reboot
Wait a second maybe I must flash the .tar file in Heimdall just like in Odin? So far I've only been flashing the raw .img files directly. Maybe that's where my bootloops come from?
I would definitely recommend flashing Samsung devices the official way with Odin
Rename the file to vbmeta.img and compress it as a tar and just flash in AP slot with Odin. Works great every time and it's a very straight forward process. Can we use Odin in Linux through Wine?
To anyone out there who ended up in a tricky and very dark Samsung bootloop. Samsung made it especially difficult to get into Download mode when stuck in such a bootloop. Here's a quick tutorial:
Phone must be off for this to work!
The trick is to press both Volume Up & Volume Down & Power buttons & plug in USB cable (which is connected to pc) . YES! ALL AT THE SAME TIME! I KNOW IT'S CRAZY!
As soon as you feel the phone vibrate, let go of power button but keep vol+ and vol- buttons still pressed! Then when Download mode screen appears let go of both volume buttons and press vol up to get into flashing mode.
Out of all phone manufacturers out there this has got to be the most difficult und developer unfriendly way to get into flashing mode for flashing an android device.
This is how I turn device off if I'm stuck in a very nasty Samsung bootloop:
Plug in usb cable & at the same time press vol+ & vol- & power for about 12 seconds!
If I don't feel the vibration I know phone is not off but I keep the button combination pressed anyways for about 12 seconds until the charger symbol appears (due to usb cable charging the device). In this very moment I let go of all buttons and immediately disconnect usb cable from device. Congratulations! Now your device is off! I know this sounds stupid but that's all the steps I must do to turn off device when stuck in such an annoying Samsung bootloop! I hope this helps someone out there to save some precious time!
Now you can proceed to get into Download mode the usual way by pressing all those aforementioned buttons together & plugging in usb cable simultaneously! Good luck!
This isn't working for my SM-A226B. It works through step #9 (flash vbmeta & twrpa22, then restart)--ie, flash indicates 'pass' for both. But at step #10, vol+ and power, my phone never goes into TWRP. I've tried several versions of the twrp file, various combinations of having the USB plugged in while I do it, holding for different lengths of time, etc. It just gets stuck in the Samsung logo boot loop. I can't even turn it off with vol- and power. The only response I can get is moving it to download mode with vol+,vol-,usb. The phone is fully charged.
Hi. I tried flashing the twrp.img from first post of this thread to the recovery partition but unfortunately my phone ended up in a very slow, very tricky, annoying and very dark bootloop. Almost as dark as the black hole in the milky way galaxy. The sort of bootloop you don't want to find your device in. Xiaomi bootloops are so much easier to get out of let me tell you! Especially since they ship with a fully working , non-crippled fastboot! Ain't that right @samsung?
Ending session...
ERROR: Failed to receive session end confirmation!
Releasing device interface...
And on phone itself it give this error:
All these different Samsung firmware websites only offer slow download speed 300 KB/s max. and I don't got premium account!
And whole firmware is 5GB that means I must wait 6 hours +
Should I keep the phone in download mode until then? Then I must leave it plugged in because screen will drain battery fast. I guarantee you that I will never ever be able to get it back into download mode again if I turn it off now. Can I even turn it off?! Nope. I can force reboot with vol down + power (hold for 10 seconds) but there is no key combo for force power off or shutdown
Can someone reading this please upload only the stock recovery of their Samsung Galaxy A22 5G (SM-A226B)? Or upload only the official file that the stock recovery is contained in such as one of those AP, CP or CSC files.
Thank you very much!
I think the firmware my device was running was Android 11 and February 2022 security patch or something. That shouldn't really matter as long as it's stock Android 11.
Maybe it's somehow possible to fix this annoying bootloop without having to download the full 5 GB of the firmware. I only overwrote the recovery partition.
I think next time I will flash using Odin like everyone else and I'll leave Heimdall to the real pro's
Does anyone know how to flash only recovery with Odin? Do I flash the AP, CP or CSC file? I guess not the BL that sounds like BOOTLOADER!
Thanks
Now I am very confident that soon I will finally be able to get this phone out of this mess and back up and running!
Sorry you didn't get help immediately, I don't check my emails often unless I want a verification code from some website.
I also screwed up my A226B (different cause), I deleted an old copy of firmware files because they were outdated, so I went to Sammobile for a different one, spent 4 hours downloading an archive that turned out to be corrupted. It was already 1 AM at that point so I went to bed. The next day, I tried downloading it again, thinking my slow internet at the time corrupted the download, waited another 4 hours, but same result. I decided to take a risk and try out those sketchy websites. I tried out samfw.com and it worked good, so you might want to try that.
About which files to flash, flash BL, AP, CSC, and CP to do a restore. HOME_CSC is if you want to keep your files, CSC if you want to start out fresh.
Edit: BL is bootloader, CP is the modem, CSC is the region specific features, and AP is the main file. Usually flashing AP will make your phone work again, but you won't be able to get software updates unless you flash the others. Also samfw downloads pretty fast.