[GUIDE][VIDEO] Moto X - Return to 100% stock (using RSD Lite OR manual flash)

Search This thread

TechSavvy2

Senior Member
Sep 26, 2011
957
542
NOTE, YES, THIS IS A LONG DRAWN OUT VERSION OF WHAT IS ACTUALLY VERY VERY QUICK PROCESS. This is for reference only. I know there are a few people out there just like me who probably had a few small hickups getting back to stock with the firmware. This is to help "spoon-feed" the instructions to you.

Two Methods-
Method 1 - RSD Lite
Method 2 - Manual Flash

If you cannot get RSD Lite to recognize your device, try Method 2, it works like a charm!

Downloads:
I assume you already have adb drivers if you're even here.....otherwise get them from the latest sdk here: http://developer.android.com/sdk/index.html
Moto Drivers (Motorola Device Manager): https://motorola-global-portal.custhelp.com/app/answers/detail/a_id/88481
RSD Lite (I used version 6.1.5): https://dl.dropboxusercontent.com/u/42057363/RSDLite_v6.1.x.zip - Extract and use 6.1.5
Stock Firmware: http://sbf.droid-developers.org/ thanks to Skrilax_CZ and Firmware Team
Moto Fastboot exe: https://drive.google.com/file/d/0B0dUKGxGylgNTk43eU0xc3VLekE/edit?usp=sharing - NOTE - YOU MUST UNZIP AND USE THIS WHERE MANUAL FLASH SAYS "mfastboot"

My Setup: Windows 8 machine <--obvious driver issues as usual :p
My Device: VZW Moto X

METHOD 1 - RSD LITE

Step One - Download and install RSD Lite. At the moment, I can't find where I got mine from, so anyone who wants to add a proper link to it would be appreciated. I used version 6.1.5 and it worked fine.

Step Two - proper driver installation. If you're like me, you probably at one point got drivers quasi-working but here's what I did that worked - download and install "Motorola Device Manager" and it *should* give you the proper drivers. This was necessary (maybe) because I could get adb to recognize my device, as well as fastboot, however RSD refused to see it. This install fixed that.

Step Three - download and install the proper firmware for your device. NOTE: You MUST MUST MUST choose the right firmware for your device or you will FUBAR your phone.....not my responsibility.

Step Four - Unzip your firmware zip file, open it up through the layers and find the file "VZW_XT1060_4.2.2-13.9.0Q2.X-116-MX-17-53_CFC_1FF" or whatever version/carrier/build number file yours is, its the XML Document file. Right click -> Open with.. -> Notepad/word editor/XML Editor/wordpad and find the line:
<step operation="getvar" var="max-download-size" />
^^^You need to select this entire line and just delete it out of the file. This is the line that gives fastboot flash error. Select it, delete it, then resave the file an exit out of it. Done.
NOTE: This is required or the firmware flash will immediately fail giving a "failed flashing process. Unknown fastboot command. (getvar)"
-For the sake of security, and not messing with important files, I'd actually recommend zipping the file back up after this and keeping as your final version (once you've confirmed yours works correctly)

Step Five - Plug in phone, enable USB debugging, then "adb reboot bootloader" - this will boot you into fastboot mode so RSD will recognize your phone

Step Six - Run RSD Lite - note that some people have had trouble and have to right-click run as administrator. In RSD Lite, make sure phone shows up in slot 1 - mine shows up, under Model, just says fastboot, USB port type, info N/A, important part is that it shows as Connected in status. Select the three-dot browse file button, then you can go down into the unzipped file you created of the XML folder, and select the XML file that we just edited earlier (or select the rezipped package). Select open and flash. (or decompress and flash)

Step Eight - Profit

METHOD 2 - MANUAL FLASHING

Much easier AND don't have to deal with getting RSD Lite to work....

Note - this was done on VZW variant, and based on XML file of that particular firmware. Get these instructions from your firmware package XML file.

Note 2 - VERY IMPORTANT!!! - You MUST use mfastboot (Moto fastboot) for the system.img flash as its too large for standard Android fastboot to handle, your flash WILL fail if you use standard fastboot. Hence why it says "mfastboot" this is not a typo.


Code:
fastboot oem fb_mode_set
fastboot flash partition gpt.bin
fastboot flash motoboot motoboot.img
fastboot flash logo logo.bin
fastboot flash boot boot.img
fastboot flash recovery recovery.img
mfastboot flash system system.img
fastboot flash modem NON-HLOS.bin
fastboot erase modemst1
fastboot erase modemst2
fastboot flash fsg fsg.mbn
fastboot erase cache
fastboot erase userdata
fastboot erase customize
fastboot erase clogo
fastboot oem config carrier vzw
fastboot oem fb_mode_clear

 
Last edited:

gunnyman

Senior Member
Apr 12, 2010
7,998
2,668
Greenville SC
Yes

---------- Post added at 03:55 PM ---------- Previous post was at 03:54 PM ----------

Fastboot flash recovery, boot, and system for sure I have no idea what to do with the other image Moto boot or something
 
  • Like
Reactions: jnichols959

housry23

Senior Member
Sep 23, 2009
2,939
746
Springfield, OH
Yes

---------- Post added at 03:55 PM ---------- Previous post was at 03:54 PM ----------

Fastboot flash recovery, boot, and system for sure I have no idea what to do with the other image Moto boot or something

Thanks. I'm pretty sure I can just fastboot flash recovery and then do a factory reset and be back to 100% stock. That's what I'm going to try anyway.

Update, it worked. Just fastboot flash recovery recovery.img then factory reset and my phone is back to stock. Now to send it back to Motorola and get my new one!
 
Last edited:

gunnyman

Senior Member
Apr 12, 2010
7,998
2,668
Greenville SC
Thanks. I'm pretty sure I can just fastboot flash recovery and then do a factory reset and be back to 100% stock. That's what I'm going to try anyway.

Update, it worked. Just fastboot flash recovery recovery.img then factory reset and my phone is back to stock. Now to send it back to Motorola and get my new one!

so flashing JUST recovery removes root?
 

kornklown69

Senior Member
Jan 21, 2011
2,421
817
35
Springfield, Missouri
Thanks. I'm pretty sure I can just fastboot flash recovery and then do a factory reset and be back to 100% stock. That's what I'm going to try anyway.

Update, it worked. Just fastboot flash recovery recovery.img then factory reset and my phone is back to stock. Now to send it back to Motorola and get my new one!

Nvm

Sent from my XT1058 using XDA Premium 4 mobile app
 
Last edited:
Jul 15, 2011
12
0
College Station, TX
Thanks. I'm pretty sure I can just fastboot flash recovery and then do a factory reset and be back to 100% stock. That's what I'm going to try anyway.

Update, it worked. Just fastboot flash recovery recovery.img then factory reset and my phone is back to stock. Now to send it back to Motorola and get my new one!

I'm trying to do the same thing in linux and I keep getting preflash verification errors, are you using a specific recovery? I tried redownloading the img but no dice.
 

housry23

Senior Member
Sep 23, 2009
2,939
746
Springfield, OH
I'm trying to do the same thing in linux and I keep getting preflash verification errors, are you using a specific recovery? I tried redownloading the img but no dice.

I used the recovery from the att zip in the op. Do you have fastboot installed? There's a Linux android package that will install adb and fastboot so it can be used from any folder. Sudo apt-get install android-tools-adb and then replace adb with fastboot to install fastboot system wide. Unzip the folder you downloaded, cd into that folder and run sudo fastboot flash recovery recovery.img. make sure you're booted into the bootlaoder first, adb reboot bootloader.

Sent from my Nexus 4 using Tapatalk 4
 

TechSavvy2

Senior Member
Sep 26, 2011
957
542
Will this work on a Mac?

I've heard through the grapevine that you can open up the files and fastboot flash them while using a mac. Just look around for proper commands. Other than that, this is just simply a script that fastboot flashes everything after checking all the versions etc.
If you read the XML file you can actually see everything and all the commands.

But, polishguy said he had issues with fastboot flashing so....:confused: But give it a shot.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 114
    NOTE, YES, THIS IS A LONG DRAWN OUT VERSION OF WHAT IS ACTUALLY VERY VERY QUICK PROCESS. This is for reference only. I know there are a few people out there just like me who probably had a few small hickups getting back to stock with the firmware. This is to help "spoon-feed" the instructions to you.

    Two Methods-
    Method 1 - RSD Lite
    Method 2 - Manual Flash

    If you cannot get RSD Lite to recognize your device, try Method 2, it works like a charm!

    Downloads:
    I assume you already have adb drivers if you're even here.....otherwise get them from the latest sdk here: http://developer.android.com/sdk/index.html
    Moto Drivers (Motorola Device Manager): https://motorola-global-portal.custhelp.com/app/answers/detail/a_id/88481
    RSD Lite (I used version 6.1.5): https://dl.dropboxusercontent.com/u/42057363/RSDLite_v6.1.x.zip - Extract and use 6.1.5
    Stock Firmware: http://sbf.droid-developers.org/ thanks to Skrilax_CZ and Firmware Team
    Moto Fastboot exe: https://drive.google.com/file/d/0B0dUKGxGylgNTk43eU0xc3VLekE/edit?usp=sharing - NOTE - YOU MUST UNZIP AND USE THIS WHERE MANUAL FLASH SAYS "mfastboot"

    My Setup: Windows 8 machine <--obvious driver issues as usual :p
    My Device: VZW Moto X

    METHOD 1 - RSD LITE

    Step One - Download and install RSD Lite. At the moment, I can't find where I got mine from, so anyone who wants to add a proper link to it would be appreciated. I used version 6.1.5 and it worked fine.

    Step Two - proper driver installation. If you're like me, you probably at one point got drivers quasi-working but here's what I did that worked - download and install "Motorola Device Manager" and it *should* give you the proper drivers. This was necessary (maybe) because I could get adb to recognize my device, as well as fastboot, however RSD refused to see it. This install fixed that.

    Step Three - download and install the proper firmware for your device. NOTE: You MUST MUST MUST choose the right firmware for your device or you will FUBAR your phone.....not my responsibility.

    Step Four - Unzip your firmware zip file, open it up through the layers and find the file "VZW_XT1060_4.2.2-13.9.0Q2.X-116-MX-17-53_CFC_1FF" or whatever version/carrier/build number file yours is, its the XML Document file. Right click -> Open with.. -> Notepad/word editor/XML Editor/wordpad and find the line:
    <step operation="getvar" var="max-download-size" />
    ^^^You need to select this entire line and just delete it out of the file. This is the line that gives fastboot flash error. Select it, delete it, then resave the file an exit out of it. Done.
    NOTE: This is required or the firmware flash will immediately fail giving a "failed flashing process. Unknown fastboot command. (getvar)"
    -For the sake of security, and not messing with important files, I'd actually recommend zipping the file back up after this and keeping as your final version (once you've confirmed yours works correctly)

    Step Five - Plug in phone, enable USB debugging, then "adb reboot bootloader" - this will boot you into fastboot mode so RSD will recognize your phone

    Step Six - Run RSD Lite - note that some people have had trouble and have to right-click run as administrator. In RSD Lite, make sure phone shows up in slot 1 - mine shows up, under Model, just says fastboot, USB port type, info N/A, important part is that it shows as Connected in status. Select the three-dot browse file button, then you can go down into the unzipped file you created of the XML folder, and select the XML file that we just edited earlier (or select the rezipped package). Select open and flash. (or decompress and flash)

    Step Eight - Profit

    METHOD 2 - MANUAL FLASHING

    Much easier AND don't have to deal with getting RSD Lite to work....

    Note - this was done on VZW variant, and based on XML file of that particular firmware. Get these instructions from your firmware package XML file.

    Note 2 - VERY IMPORTANT!!! - You MUST use mfastboot (Moto fastboot) for the system.img flash as its too large for standard Android fastboot to handle, your flash WILL fail if you use standard fastboot. Hence why it says "mfastboot" this is not a typo.


    Code:
    fastboot oem fb_mode_set
    fastboot flash partition gpt.bin
    fastboot flash motoboot motoboot.img
    fastboot flash logo logo.bin
    fastboot flash boot boot.img
    fastboot flash recovery recovery.img
    mfastboot flash system system.img
    fastboot flash modem NON-HLOS.bin
    fastboot erase modemst1
    fastboot erase modemst2
    fastboot flash fsg fsg.mbn
    fastboot erase cache
    fastboot erase userdata
    fastboot erase customize
    fastboot erase clogo
    fastboot oem config carrier vzw
    fastboot oem fb_mode_clear

    4
    You forgot to mention that you need to have it charged enough or it won't flash. I think it needs a minimum 30% charge, but 50% or more is recommended.

    Sent from my XT1058 using Tapatalk 2

    Noted. Will add it.

    Sent from my Moto X using Tapatalk 4
    4
    I have a moto x 2013 GSM developer edition and I have a few questions about how to flash the stock/factory 4.4.4 image which is available on the motorola website for download for the developer editions moto x.

    On the motorola website it says that I need to follow the XML lines inside the downloaded file but there is no XML file inside of it.
    I downloaded and extracted it yesterday just to check what's inside of it and there is a bunch of files including a fastboot.exe and I don't know if that is the correct fastboot file that is needed to use in order to flash the firmware cause on the website there is a warning mentioning that we need to use mfastboot and not the standard fastboot from android so I really don't know if the fastboot included on the zip will work or not (I mean if it's actually the mfastboot file but just named fastboot) and I really don't want to break my phone.
    And the last one, there is a flash.bat file inside the zip after unzipping it, what if I just put my phone into fastboot mode and run that flash.bat file? Will it do all the flashing process automatically? Does anyone knows for sure if this could work? Thanks in advance for the help and sorry for my English...
    Moto did NOT include an XML in their latest images on their web site. They do include a bat file which flashes by calling fastboot to flash it. The XML is only needed when using RSDlite to flash. (yes, this means you can put your phone in bootloader mode and use the flash.bat file to flash it via fastboot).

    When you install the ADB and Platform Tools from the AndroidSDK, you will get a fastboot.exe. This standard fastboot.exe is compatible with most, if not all, Android devices to flash parts or partitions with. Unfortunately, that standard fastboot is limited on how big of files it can properly flash. In recent android devices, Motorola has surpassed the limits of fastboot, as such Moto has an "upgraded" or "tweaked" fastboot. This "upgraded" or "tweaked" fastboot from Moto is also known as mFastboot.

    The fastboot.exe included in the SBF's on Motorola's web site is "mFastboot" or the Moto version of Fastboot. It is just not "renamed" so it is easy to confuse, and/or not know the difference. If you are going to use the flash.bat file, you need to make sure the Moto Fastboot.exe is available either where the bat file is looking for it, or in the path BEFORE the Android SDK/Platformtools Fastboot.exe.

    For more on fastboot vs mfastboot see -> http://mark.cdmaforums.com/MotoX-mFastboot.htm

    If you really want to use RSDLite and need the XML file, then you can try downloading your rom from one of the 3rd party (not affiliated with Moto) sites that host All the 2013 Moto X SBF files, not just the Dev Editions. Or you can download the 4.4.2 SBF and use its XML but with the rest of the files from the 4.4.4 SBF.
    3
    Maybe "WE" should move on and work the problems and not each other or "YOU" will have to deal with "ME".

    Quit dwelling on semantics and help if you can. If not, then move on please.
    3
    I did everything well and got back to stock successfully and also relocked the bootloader but the unlocked bootloader warning screen is still shown to me on every startup. :silly:
    can anyone help me understand why it is so?
    I know it will go away by flashing custom logo but I don't want to do that, I mean if everything was successful, why doesn't the warning go away?
    Your phone is working as designed. Here is why....

    The Bootloader on the X has 3 different states and that status is displayed on the bootloader/fasboot screen of the phone.
    1. Locked (as it ships from factory)
    2. Unlocked (after doing mfastboot oem unlock <uniquecode>)
    3. Relocked (after doing mfastboot oem relock).
    We can only toggle it to Unlocked or Relocked, we can't get it back to LOCKED.

    The Unlocked bootloader warning graphic in the LOGO.BIN file will display when the bootloader status is Unlocked or Relocked.

    So once you've initially unlocked your bootloader, the only way to get rid of the "Unlocked Bootloader Warning" message is to flash a custom LOGO.BIN where the warning graphic has been replaced.

    ---------- Post added at 12:36 PM ---------- Previous post was at 12:20 PM ----------

    I tried to downgrade from 4.4.3 (really bad battery life being the reason) to 4.4.2 and couldn't do it. The bootloader is unlocked. Used the manual method and then used the RSD Lite method and got the same "preflash validation failed for GPT" error. Don't know how to get around it. Thankfully, in the fastboot, scrolled down to "factory" and upon clicking it was able to get back into my original 4.4.3 stock ROM. So does anyone know how to downgrade? I'd appreciate the help.

    Also, I am new to the Moto x, is the battery life better on 4.4.2 or on 4.4.3? I had a Moto G before this and the battery life was really good on that. I loose a lot of power in standby with airplane mode on :/
    (bold in quote added by me)

    For those who missed the side thread -> http://forum.xda-developers.com/moto-x/moto-x-qa/how-downgrade-4-4-3-to-4-4-2-xt1053-t2804206

    At least in the XT1053 GSM Dev Edition rom, the GPT.BIN has changed from 4.4.2 to 4.4.3. However, unlike with 4.4.2, motoboot (the bootloader) did NOT change. Never the less, this upgraded GPT.BIN in 4.4.3 will prevent successful downgrade to 4.4.2 using RSDLite.

    While it may be possible to downgrade everything but GPT.BIN using mFastboot with the 4.4.2 SBF, it is not advised since the "partition table" (GPT.BIN) will be different, and now you will end up having mixed matched files on your phone which could cause various issues (strange and intermittent issues, failures or bricking on future updates, etc).