• We are moving to xdaforums.com!

    Posts made between now and when the migration is complete will not be carried over.
    You will be automatically redirected once the migration is complete.

[GUIDE] Repair, Unbrick, Unroot, Re-lock Bootloader and Flash stock firmware in Samsung Devices

Was this guide helpful to you?


  • Total voters
    22
Search This thread

thankyouxda

Senior Member
Aug 18, 2011
129
19
Thank you ExileTM. Was able to re-lock the bootloader on a used Galaxy Tab S8 plus I bought with this guide. Appreciate it. Seller made no mention of unlocked bootloader and I failed to check before purchase. Power on warning message is gone. Device status is now official vs. custom. Think updates will now download without issues.. Knox is still 0x1 though but no big deal.


Welcome to this easy guide.

Time needed: 15 / 60min (depends on your internet connection)
Ease of operation: Very easy
Don't be fooled by the length of this guide ... the operations to be done are quick and easy.
 

kaju666

Senior Member
Aug 16, 2008
133
13
My got thank you for this guide!

I downlaoded latest rom and odin from sammobile.
Extracted .pit - mine was BEYOND1LTE_EUR_OPEN.pit
Flashed also with HOME_CSC in USERDATA.

Phone restarted in Android Recovery with error "Cant load your Android system. Your data may be corrupt..."
On this screen i selected "Factory Data reset"
After that phone restarted normally and everything is working :)

Also i do not have any warning that BOOTLAODER is unlocked.
 
Last edited:

the_ccm

Member
May 25, 2008
5
0
Hello, @Macusercom said Here that we must not flash original boot.img :

Do not restore the stock boot image!
topjohnwu also states to not flash the stock boot image (stock AP) as it could brick your device. There should be no reason to unroot (you can leave Magisk and simply not use it). If you flash the stock AP, your device won't boot (probably because it fails to verify the unmodified system).

So I don’t know what to think about this …
Can I replace boot.img with a patched one in AP file without risk ?
 

blackhawk_LA

Senior Member
Dec 27, 2010
1,547
651
HTC One (m7)
Sony Xperia XZ1 Compact
After following this guide I still can't get OTA updates (it keeps saying "error while registering your phone", and the same happens when I try with smart switch from my laptop)
I thought that tripping know to 1 won't break OTAs forever. Was I wrong?
 

jrdef

Member
Mar 23, 2023
23
4
Samsung Galaxy S20 FE
Could you help with my issue please?

My got thank you for this guide!

I downlaoded latest rom and odin from sammobile.
Extracted .pit - mine was BEYOND1LTE_EUR_OPEN.pit
Flashed also with HOME_CSC in USERDATA.

Phone restarted in Android Recovery with error "Cant load your Android system. Your data may be corrupt..."
On this screen i selected "Factory Data reset"
After that phone restarted normally and everything is working :)

Also i do not have any warning that BOOTLAODER is unlocked.
any tips here please? https://forum.xda-developers.com/t/s20-fe-bootloop-after-security-update.4568331/#post-88352797
 

CuBz90

Senior Member
Sep 27, 2010
2,224
1,034
Fantastic guide. Got my phone back to stock without a hitch. Thanks.
 

rentofer

Member
Jan 22, 2017
12
4
I've done it and the phone works nice. But unable to use S Health and Pay...is it because Knox ? Anything else? Thanks a lot
 

florof

Member
Dec 9, 2008
15
1
Hi ..ive done all the steps like your guide but my banking app dont work correctly..like the phone was still rooted. But nothing else.
How fix it?
 

LUCID_DREE

Senior Member
May 4, 2020
72
10
Welcome to this easy guide.

Time needed: 15 / 60min (depends on your internet connection)
Ease of operation: Very easy
Don't be fooled by the length of this guide ... the operations to be done are quick and easy.

NB: I state immediately that this procedure does not restore the state of Knox to 0x0 if by chance you have brought it to 0x1.
To date, this is an irreversible process.

In the next lines we will see how to restore our Samsung device to its original factory conditions, after unlocking the Bootloader, rooting and installing various types of custom installations, such as custom OneUI, AOSP or Google ROM.
It may happen that you want to go back to the original firmware of our Samsung, after trying various custom ROMs, after having rooted and modified the recovery, missing with the phone partitions, lost EFS folder or corrupt IMEI. The reasons can be many. This guide is aimed at all those who, with the classic Odin procedure to install the stock rom, are unable to restore the phone to normal operating conditions.

But it can happen to fail in this thing, even using Odin to put back the original software, Odin himself or the phone can crash to the BOOT partition or generate other errors, with VBMeta or generic errors, including partition ones.
So let's see how to solve all the inconveniences due to modding on our Samsungs to 99%. Let's begin!

- MATERIAL REQUIRED:
Latest version of Frija link
Latest version of Odin link
Samsung USB Driver link
File Manager zip (example 7zip) link

PC with Microsoft Windows 7-8-8.1-10-11
USB type C cable

1 - Download the latest stock firmware for our Samsung:
Download the latest version of Frija and once the program has started, enter the model code of your device and the abbreviation of your CSC.
Make sure the "Auto" checkbox is checked.
Once you have checked everything, click on "Check Update" and click on "Download". Wait for it to download.
View attachment 5628035

Once you have downloaded the zip containing the various parts that make up the stock software (see image below), extract it to a folder of your choice. We will have 5 files in total.
View attachment 5629259

2 - Retrieve the original PIT file
To recover the PIT file (partition list) for our device, go to the firmware folder you just downloaded with Frija, locate the "tar.md5" file with the words CSC_OXM_N............., right click on the it and select rename, adding ".zip" at the end to "transform" it into a compressed file that can be opened. This way you will have something like
"CSC_OXM_N975...............REV01_user_low_ship.tar.md5.zip"
Give the Ok and confirm the change of the file extension.
You should now have the same situation as you see in the image below. Total 5 files of which one is a ".zip" files.
View attachment 5629261

Now open the file you just renamed with 7zip, the main window of the 7zip program will open with various files inside:
View attachment 5628037

Now copy the "D2S_EUR_OPEN.pit" file by right clicking and selecting the "copy to ..." item and giving the ok without changing anything. The .PIT file will be copied to the same folder as the previously downloaded firmware.
View attachment 5629463

Once this is done, the folder that appears will look like this (Now, the total files are 6 of which one is a ".zip" files):
View attachment 5629465

Now just put the CSC_OXM ... file back to the previous condition, renaming it one more time and eliminating the ".zip" extension at the end of the name, in order to find an MD5 file again. This will be the file we will have:
"CSC_OXM_N975...............REV01_user_low_ship.tar.md5."

Now we have everything we need. If we have done everything correctly this is the final result (Total 6 files).
View attachment 5629265

3 - Prepare and Configure Odin
Now open the latest version of Odin (as of May 2022 the latest version is 3.14.4), load the corresponding downloaded firmware files in the various slots (BL, AP, CP and CSC) as usual.
In the CSC box, upload the file labeled "CSC_OXM_N975 ............... REV01_user_low_ship.tar.md5."



Once this is done, move (still in Odin) to the "Option" tab and check the following items:
Auto Reboot
Nand Erase
Re-partition
F. Reset time

The rest of the items MUST NOT BE SELECTED!
View attachment 5628039


Again in Odin, this time go to the PIT tab, a warning message will appear, give the ok and select the first extracted file which has the unique name "D2S_EUR_OPEN.pit"
If you have done everything right you should have the same situation as the image below:
View attachment 5628043

View attachment 5628045

4 - Return the phone to the original firmware
Connect the USB type C cable to your phone and restart your phone in "Download mode" (check the right combination for your model), or use the Custom Rom to do this, usually all coustom roms or custom recovery offer reboot in Download mode (or Booloader).
In odin in the "Log" tab, you should see the word "Added" with the number of the port to which it is connected (example "0: [COM3]"), if so, press the START key of Odin and wait for the restart (this procedure will delete all data on your device).
If nothing appears, install the Samsung USB drivers and repeat step 4.
View attachment 5628041

5 - Relock the BootLoader
To get rid of that fatal warning message when starting the phone that tells us that the BootLoader is unlocked once and for all, let's put it back in place, relocking the BootLoader.
View attachment 5629449
(Image for demonstration purposes)

Turn off the phone, reconnect the USB cable and immediately press the Volume + and Volume- keys at the same time.
Return to Download mode (albeit a little different), with various options (actually only 3).
In this case, follow the second option (Volume up long press: Device unlock mode) hold down the Volume + key for a few moments until the message "Lock Bootloader?" Appears. To confirm everything, make a single click on Volume + (also in this case the phone will be formatted by the system again) and wait for a complete restart.

6 - Relock OEM (optional but recommended if you want to stick with the Samsung ROM)
Once your phone has restarted and the initial setup is complete, you can also disable the OEM unlock capability and reuse the security features.
To do this, go to Settings / Phone Information / Software Information and tap several times on the wording "Build version" in order to unlock the "Developer options". If prompted, unlock your smartphone with your PIN or sign.
Now go back to the main Settings page, open the Developer Options and check that the "OEM Unlock" item is disabled, otherwise disable it and restart the device.
View attachment 5629493

Well now you have your Samsung with Original firmware again. Enjoy
Can we go from s4 binary to s3 binary SW version using this method?
 

ExileTM

Senior Member
Apr 4, 2012
135
33
Montefano
Can we go from s4 binary to s3 binary SW version using this method?
Unfortunately not. You cannot downgrade the firmware by changing the sw binary. It seems to me that perhaps the only working method is to modify the original firmware by unpacking the firmware and eliminating some parts inside that control the binary value, such as modem.bin, kernel.bin, and others that I don't remember.
 
  • Love
Reactions: LUCID_DREE

LUCID_DREE

Senior Member
May 4, 2020
72
10
Unfortunately not. You cannot downgrade the firmware by changing the sw binary. It seems to me that perhaps the only working method is to modify the original firmware by unpacking the firmware and eliminating some parts inside that control the binary value, such as modem.bin, kernel.bin, and others that I don't remember.
Any help in this method ?
 

VITMAD

Senior Member
Nov 12, 2012
116
8
Sintra
Sorry by that but Frija can't download right now the Samsung Firmware's it said UNABLE TO FIND FIRMWARE TO ....
Can anybody help me with a application to download the official firmware's to Samsung Phone?s
Thanks in advance
 

rvmphoenix

Member
May 21, 2023
6
4
Thanks for the guide. Unfortunately, don't works with my device. I'm stock in An PIT error.
I can't enter in recovery Mode because marks an "MMC read fail".
I don't know what else to do to fix this... 😪
 

Attachments

  • 20230611_140423.jpg
    20230611_140423.jpg
    9 MB · Views: 18
  • 20230611_140955.jpg
    20230611_140955.jpg
    1.3 MB · Views: 17

Moha.E KURDI

Member
Jul 13, 2023
13
3
Hi, i'm confused because i have "SM-A528B/DS" model and i can only download "SM-A528B" i'm scared that this transition to A HARD BRICK.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 12
    Welcome to this easy guide.

    Time needed: 15 / 60min (depends on your internet connection)
    Ease of operation: Very easy
    Don't be fooled by the length of this guide ... the operations to be done are quick and easy.

    NB: I state immediately that this procedure does not restore the state of Knox to 0x0 if by chance you have brought it to 0x1.
    To date, this is an irreversible process.

    In the next lines we will see how to restore our Samsung device to its original factory conditions, after unlocking the Bootloader, rooting and installing various types of custom installations, such as custom OneUI, AOSP or Google ROM.
    It may happen that you want to go back to the original firmware of our Samsung, after trying various custom ROMs, after having rooted and modified the recovery, missing with the phone partitions, lost EFS folder or corrupt IMEI. The reasons can be many. This guide is aimed at all those who, with the classic Odin procedure to install the stock rom, are unable to restore the phone to normal operating conditions.

    But it can happen to fail in this thing, even using Odin to put back the original software, Odin himself or the phone can crash to the BOOT partition or generate other errors, with VBMeta or generic errors, including partition ones.
    So let's see how to solve all the inconveniences due to modding on our Samsungs to 99%. Let's begin!

    - MATERIAL REQUIRED:
    Latest version of Frija link
    Latest version of Odin link
    Samsung USB Driver link
    File Manager zip (example 7zip) link

    PC with Microsoft Windows 7-8-8.1-10-11
    USB type C cable

    1 - Download the latest stock firmware for our Samsung:
    Download the latest version of Frija and once the program has started, enter the model code of your device and the abbreviation of your CSC.
    Make sure the "Auto" checkbox is checked.
    Once you have checked everything, click on "Check Update" and click on "Download". Wait for it to download.
    Immagine 2022-06-01 171858.png


    Once you have downloaded the zip containing the various parts that make up the stock software (see image below), extract it to a folder of your choice. We will have 5 files in total.
    Immagine 2022-06-03 095805.png


    2 - Retrieve the original PIT file
    To recover the PIT file (partition list) for our device, go to the firmware folder you just downloaded with Frija, locate the "tar.md5" file with the words CSC_OXM_N............., right click on the it and select rename, adding ".zip" at the end to "transform" it into a compressed file that can be opened. This way you will have something like
    "CSC_OXM_N975...............REV01_user_low_ship.tar.md5.zip"
    Give the Ok and confirm the change of the file extension.
    You should now have the same situation as you see in the image below. Total 5 files of which one is a ".zip" files.
    Immagine 2022-06-03 100700.png


    Now open the file you just renamed with 7zip, the main window of the 7zip program will open with various files inside:
    Immagine 2022-06-01 164656.png


    Now copy the "D2S_EUR_OPEN.pit" file by right clicking and selecting the "copy to ..." item and giving the ok without changing anything. The .PIT file will be copied to the same folder as the previously downloaded firmware.
    Immagine 2022-06-03 144208.png


    Once this is done, the folder that appears will look like this (Now, the total files are 6 of which one is a ".zip" files):
    Immagine 2022-06-03 144301.png


    Now just put the CSC_OXM ... file back to the previous condition, renaming it one more time and eliminating the ".zip" extension at the end of the name, in order to find an MD5 file again. This will be the file we will have:
    "CSC_OXM_N975...............REV01_user_low_ship.tar.md5."

    Now we have everything we need. If we have done everything correctly this is the final result (Total 6 files).
    Immagine 2022-06-03 101134.png


    3 - Prepare and Configure Odin
    Now open the latest version of Odin (as of May 2022 the latest version is 3.14.4), load the corresponding downloaded firmware files in the various slots (BL, AP, CP and CSC) as usual.
    In the CSC box, upload the file labeled "CSC_OXM_N975 ............... REV01_user_low_ship.tar.md5."

    Did you know that....
    The CSC_OXM file is used to restore the internal memory as factory, this will delete all personal data in the phone memory, all applications and data associated with it.
    The HOME_CSC_OXM file, on the other hand, will not act in any way on the internal memory. Useful if you want to update while remaining in the same type of ROM. Not recommended if your phone has a Custom ROM installed, as it may not start or give errors in previously installed applications.
    If you want to do a clean install of the original ROM, always use the CSC_OMX file!

    Once this is done, move (still in Odin) to the "Option" tab and check the following items:
    Auto Reboot
    Nand Erase
    Re-partition
    F. Reset time

    The rest of the items MUST NOT BE SELECTED!
    Immagine 2022-06-01 165607.png


    Again in Odin, this time go to the PIT tab, a warning message will appear, give the ok and select the first extracted file which has the unique name "D2S_EUR_OPEN.pit"
    If you have done everything right you should have the same situation as the image below:
    Immagine 2022-06-01 165643.png


    Immagine 2022-06-01 165724.png


    4 - Return the phone to the original firmware
    Connect the USB type C cable to your phone and restart your phone in "Download mode" (check the right combination for your model), or use the Custom Rom to do this, usually all coustom roms or custom recovery offer reboot in Download mode (or Booloader).
    In odin in the "Log" tab, you should see the word "Added" with the number of the port to which it is connected (example "0: [COM3]"), if so, press the START key of Odin and wait for the restart (this procedure will delete all data on your device).
    If nothing appears, install the Samsung USB drivers and repeat step 4.
    Immagine 2022-06-01 165804.png


    5 - Relock the BootLoader
    To get rid of that fatal warning message when starting the phone that tells us that the BootLoader is unlocked once and for all, let's put it back in place, relocking the BootLoader.
    galaxy-magisk-bootloader-513x1024.jpg

    (Image for demonstration purposes)

    Turn off the phone, reconnect the USB cable and immediately press the Volume + and Volume- keys at the same time.
    Return to Download mode (albeit a little different), with various options (actually only 3).
    In this case, follow the second option (Volume up long press: Device unlock mode) hold down the Volume + key for a few moments until the message "Lock Bootloader?" Appears. To confirm everything, make a single click on Volume + (also in this case the phone will be formatted by the system again) and wait for a complete restart.

    6 - Relock OEM (optional but recommended if you want to stick with the Samsung ROM)
    Once your phone has restarted and the initial setup is complete, you can also disable the OEM unlock capability and reuse the security features.
    To do this, go to Settings / Phone Information / Software Information and tap several times on the wording "Build version" in order to unlock the "Developer options". If prompted, unlock your smartphone with your PIN or sign.
    Now go back to the main Settings page, open the Developer Options and check that the "OEM Unlock" item is disabled, otherwise disable it and restart the device.
    OEM.png


    Well now you have your Samsung with Original firmware again. Enjoy
    3
    Welcome to this easy guide.

    Time needed: 15 / 60min (depends on your internet connection)
    Ease of operation: Very easy
    Don't be fooled by the length of this guide ... the operations to be done are quick and easy.

    NB: I state immediately that this procedure does not restore the state of Knox to 0x0 if by chance you have brought it to 0x1.
    To date, this is an irreversible process.

    In the next lines we will see how to restore our Samsung device to its original factory conditions, after unlocking the Bootloader, rooting and installing various types of custom installations, such as custom OneUI, AOSP or Google ROM.
    It may happen that you want to go back to the original firmware of our Samsung, after trying various custom ROMs, after having rooted and modified the recovery, missing with the phone partitions, lost EFS folder or corrupt IMEI. The reasons can be many. This guide is aimed at all those who, with the classic Odin procedure to install the stock rom, are unable to restore the phone to normal operating conditions.

    But it can happen to fail in this thing, even using Odin to put back the original software, Odin himself or the phone can crash to the BOOT partition or generate other errors, with VBMeta or generic errors, including partition ones.
    So let's see how to solve all the inconveniences due to modding on our Samsungs to 99%. Let's begin!

    - MATERIAL REQUIRED:
    Latest version of Frija link
    Latest version of Odin link
    Samsung USB Driver link
    File Manager zip (example 7zip) link

    PC with Microsoft Windows 7-8-8.1-10-11
    USB type C cable

    1 - Download the latest stock firmware for our Samsung:
    Download the latest version of Frija and once the program has started, enter the model code of your device and the abbreviation of your CSC.
    Make sure the "Auto" checkbox is checked.
    Once you have checked everything, click on "Check Update" and click on "Download". Wait for it to download.
    View attachment 5628035

    Once you have downloaded the zip containing the various parts that make up the stock software (see image below), extract it to a folder of your choice. We will have 5 files in total.
    View attachment 5629259

    2 - Retrieve the original PIT file
    To recover the PIT file (partition list) for our device, go to the firmware folder you just downloaded with Frija, locate the "tar.md5" file with the words CSC_OXM_N............., right click on the it and select rename, adding ".zip" at the end to "transform" it into a compressed file that can be opened. This way you will have something like
    "CSC_OXM_N975...............REV01_user_low_ship.tar.md5.zip"
    Give the Ok and confirm the change of the file extension.
    You should now have the same situation as you see in the image below. Total 5 files of which one is a ".zip" files.
    View attachment 5629261

    Now open the file you just renamed with 7zip, the main window of the 7zip program will open with various files inside:
    View attachment 5628037

    Now copy the "D2S_EUR_OPEN.pit" file by right clicking and selecting the "copy to ..." item and giving the ok without changing anything. The .PIT file will be copied to the same folder as the previously downloaded firmware.
    View attachment 5629463

    Once this is done, the folder that appears will look like this (Now, the total files are 6 of which one is a ".zip" files):
    View attachment 5629465

    Now just put the CSC_OXM ... file back to the previous condition, renaming it one more time and eliminating the ".zip" extension at the end of the name, in order to find an MD5 file again. This will be the file we will have:
    "CSC_OXM_N975...............REV01_user_low_ship.tar.md5."

    Now we have everything we need. If we have done everything correctly this is the final result (Total 6 files).
    View attachment 5629265

    3 - Prepare and Configure Odin
    Now open the latest version of Odin (as of May 2022 the latest version is 3.14.4), load the corresponding downloaded firmware files in the various slots (BL, AP, CP and CSC) as usual.
    In the CSC box, upload the file labeled "CSC_OXM_N975 ............... REV01_user_low_ship.tar.md5."



    Once this is done, move (still in Odin) to the "Option" tab and check the following items:
    Auto Reboot
    Nand Erase
    Re-partition
    F. Reset time

    The rest of the items MUST NOT BE SELECTED!
    View attachment 5628039


    Again in Odin, this time go to the PIT tab, a warning message will appear, give the ok and select the first extracted file which has the unique name "D2S_EUR_OPEN.pit"
    If you have done everything right you should have the same situation as the image below:
    View attachment 5628043

    View attachment 5628045

    4 - Return the phone to the original firmware
    Connect the USB type C cable to your phone and restart your phone in "Download mode" (check the right combination for your model), or use the Custom Rom to do this, usually all coustom roms or custom recovery offer reboot in Download mode (or Booloader).
    In odin in the "Log" tab, you should see the word "Added" with the number of the port to which it is connected (example "0: [COM3]"), if so, press the START key of Odin and wait for the restart (this procedure will delete all data on your device).
    If nothing appears, install the Samsung USB drivers and repeat step 4.
    View attachment 5628041

    5 - Relock the BootLoader
    To get rid of that fatal warning message when starting the phone that tells us that the BootLoader is unlocked once and for all, let's put it back in place, relocking the BootLoader.
    View attachment 5629449
    (Image for demonstration purposes)

    Turn off the phone, reconnect the USB cable and immediately press the Volume + and Volume- keys at the same time.
    Return to Download mode (albeit a little different), with various options (actually only 3).
    In this case, follow the second option (Volume up long press: Device unlock mode) hold down the Volume + key for a few moments until the message "Lock Bootloader?" Appears. To confirm everything, make a single click on Volume + (also in this case the phone will be formatted by the system again) and wait for a complete restart.

    6 - Relock OEM (optional but recommended if you want to stick with the Samsung ROM)
    Once your phone has restarted and the initial setup is complete, you can also disable the OEM unlock capability and reuse the security features.
    To do this, go to Settings / Phone Information / Software Information and tap several times on the wording "Build version" in order to unlock the "Developer options". If prompted, unlock your smartphone with your PIN or sign.
    Now go back to the main Settings page, open the Developer Options and check that the "OEM Unlock" item is disabled, otherwise disable it and restart the device.
    View attachment 5629493

    Well now you have your Samsung with Original firmware again. Enjoy
    I tested on S22 Snapdragon version and restored to factory firmware successfully. Thanks for the effort.
    1
    Welcome to this easy guide.

    Time needed: 15 / 60min (depends on your internet connection)
    Ease of operation: Very easy
    Don't be fooled by the length of this guide ... the operations to be done are quick and easy.

    NB: I state immediately that this procedure does not restore the state of Knox to 0x0 if by chance you have brought it to 0x1.
    To date, this is an irreversible process.

    In the next lines we will see how to restore our Samsung device to its original factory conditions, after unlocking the Bootloader, rooting and installing various types of custom installations, such as custom OneUI, AOSP or Google ROM.
    It may happen that you want to go back to the original firmware of our Samsung, after trying various custom ROMs, after having rooted and modified the recovery, missing with the phone partitions, lost EFS folder or corrupt IMEI. The reasons can be many. This guide is aimed at all those who, with the classic Odin procedure to install the stock rom, are unable to restore the phone to normal operating conditions.

    But it can happen to fail in this thing, even using Odin to put back the original software, Odin himself or the phone can crash to the BOOT partition or generate other errors, with VBMeta or generic errors, including partition ones.
    So let's see how to solve all the inconveniences due to modding on our Samsungs to 99%. Let's begin!

    - MATERIAL REQUIRED:
    Latest version of Frija link
    Latest version of Odin link
    Samsung USB Driver link
    File Manager zip (example 7zip) link

    PC with Microsoft Windows 7-8-8.1-10-11
    USB type C cable

    1 - Download the latest stock firmware for our Samsung:
    Download the latest version of Frija and once the program has started, enter the model code of your device and the abbreviation of your CSC.
    Make sure the "Auto" checkbox is checked.
    Once you have checked everything, click on "Check Update" and click on "Download". Wait for it to download.
    View attachment 5628035

    Once you have downloaded the zip containing the various parts that make up the stock software (see image below), extract it to a folder of your choice. We will have 5 files in total.
    View attachment 5629259

    2 - Retrieve the original PIT file
    To recover the PIT file (partition list) for our device, go to the firmware folder you just downloaded with Frija, locate the "tar.md5" file with the words CSC_OXM_N............., right click on the it and select rename, adding ".zip" at the end to "transform" it into a compressed file that can be opened. This way you will have something like
    "CSC_OXM_N975...............REV01_user_low_ship.tar.md5.zip"
    Give the Ok and confirm the change of the file extension.
    You should now have the same situation as you see in the image below. Total 5 files of which one is a ".zip" files.
    View attachment 5629261

    Now open the file you just renamed with 7zip, the main window of the 7zip program will open with various files inside:
    View attachment 5628037

    Now copy the "D2S_EUR_OPEN.pit" file by right clicking and selecting the "copy to ..." item and giving the ok without changing anything. The .PIT file will be copied to the same folder as the previously downloaded firmware.
    View attachment 5629463

    Once this is done, the folder that appears will look like this (Now, the total files are 6 of which one is a ".zip" files):
    View attachment 5629465

    Now just put the CSC_OXM ... file back to the previous condition, renaming it one more time and eliminating the ".zip" extension at the end of the name, in order to find an MD5 file again. This will be the file we will have:
    "CSC_OXM_N975...............REV01_user_low_ship.tar.md5."
    Now we have everything we need. If we have done everything correctly this is the final result (Total 6 files).
    View attachment 5629265

    3 - Prepare and Configure Odin
    Now open the latest version of Odin (as of May 2022 the latest version is 3.14.4), load the corresponding downloaded firmware files in the various slots (BL, AP, CP and CSC) as usual.
    In the CSC box, upload the file labeled "CSC_OXM_N975 ............... REV01_user_low_ship.tar.md5."



    Once this is done, move (still in Odin) to the "Option" tab and check the following items:
    Auto Reboot
    Nand Erase
    Re-partition
    F. Reset time

    The rest of the items MUST NOT BE SELECTED!
    View attachment 5628039


    Again in Odin, this time go to the PIT tab, a warning message will appear, give the ok and select the first extracted file which has the unique name "D2S_EUR_OPEN.pit"
    If you have done everything right you should have the same situation as the image below:
    View attachment 5628043

    View attachment 5628045

    4 - Return the phone to the original firmware
    Connect the USB type C cable to your phone and restart your phone in "Download mode" (check the right combination for your model), or use the Custom Rom to do this, usually all coustom roms or custom recovery offer reboot in Download mode (or Booloader).
    In odin in the "Log" tab, you should see the word "Added" with the number of the port to which it is connected (example "0: [COM3]"), if so, press the START key of Odin and wait for the restart (this procedure will delete all data on your device).
    If nothing appears, install the Samsung USB drivers and repeat step 4.
    View attachment 5628041

    5 - Relock the BootLoader
    To get rid of that fatal warning message when starting the phone that tells us that the BootLoader is unlocked once and for all, let's put it back in place, relocking the BootLoader.
    View attachment 5629449
    (Image for demonstration purposes)

    Turn off the phone, reconnect the USB cable and immediately press the Volume + and Volume- keys at the same time.
    Return to Download mode (albeit a little different), with various options (actually only 3).
    In this case, follow the second option (Volume up long press: Device unlock mode) hold down the Volume + key for a few moments until the message "Lock Bootloader?" Appears. To confirm everything, make a single click on Volume + (also in this case the phone will be formatted by the system again) and wait for a complete restart.

    6 - Relock OEM (optional but recommended if you want to stick with the Samsung ROM)
    Once your phone has restarted and the initial setup is complete, you can also disable the OEM unlock capability and reuse the security features.
    To do this, go to Settings / Phone Information / Software Information and tap several times on the wording "Build version" in order to unlock the "Developer options". If prompted, unlock your smartphone with your PIN or sign.
    Now go back to the main Settings page, open the Developer Options and check that the "OEM Unlock" item is disabled, otherwise disable it and restart the device.
    View attachment 5629493

    Well now you have your Samsung with Original firmware again. Enjoy
    Hi there. I tried it and didn't work for me.
    Tried with differents CSC too, but my phone doesn't start the system. Just starts the download and recovery mode
    It doesn't even show up the charging screen when powered off

    Tried so many things and I can't boot my system...
    I made a post with the info about what happened:


    Please help...
    1
    Ok so with Odin it didn't give you any problem. Let's say he freezes when he does the first boot that does the factory reset. Right?
    Well odd, because once the original firmware is installed, I don't see why it should crash on boot ... unless there is a hardware problem in the phone's internal memory.
    I know it may sound trivial, but the usb cable you use is good and did you use the latest version of Odin?
    Have you checked maybe if the internal memory is right for you. If it is 256Gb or 512Gb
    The USB it's the original from Samsung.
    The device is 256GB
    You could try this, if you see that it does not start try to enter the recovery (the original one) and delete everything you can, like cache and do a reset data directly from the recovery. Then try restarting and see if it starts.
    Tried this already. Didn't work
    If it still doesn't boot, try this thing.
    Install TWRP custom recovery and enter once installed.
    Go to Wipe Section in TWRP, Repair or Change partition, System and Data, and Changed Ext4 to EXTFAT. And changed back to Ext4. Eventually rerun the guide again.
    I tried this but not in the process of "Do the format and then do the Odin process" so I can try

    I'm trying now with USB OTG to know if I can flash the system.img (and know if from there I can solve this)
    1
    Can we go from s4 binary to s3 binary SW version using this method?
    Unfortunately not. You cannot downgrade the firmware by changing the sw binary. It seems to me that perhaps the only working method is to modify the original firmware by unpacking the firmware and eliminating some parts inside that control the binary value, such as modem.bin, kernel.bin, and others that I don't remember.