[Moto X General] whizinc:
Greetings XDA Members,

I am seeing alot of people repeating this same question again and again like "Hey, I have messed up I flashed this and this and now I want to get all setup to take the official Lollipop OTA of MOTO X, Please help" the same question over and over again in several other threads so I thought it might be a good idea to sum up everything in one thread and make this easier for other members to point any person having issue like these to this thread. Now keep in mind that I am not a professional developer, Im just here to tell the basics of flashing a stock firmware, IF I make any mistake please let me know and also this thread will be a long briefly explained one so please read carefully and consider everything before applying anything. :)

To start off, the point of this thread is to help our new members of XDA to have an idea of what to do and how to do, Now the main topic of this thread is to point our newbie fellows on how to flash a stock firmware on a messed up MOTO X (Any Model), By messed up I mean: Either the user corrupted or damaged or somehow got stuck between anything like bootloops,not getting signals,phone not working properly and all sorts of basic software problems. If you are having such problems with your phone and want to get back to the newly fresh Moto X like when you bought it, it was shiny and all the software was fresh etc And also you want to get all setup to receive the Lollipop OTA.. you are at the right place mate. Keep reading.

Have a look at this thread also for more useful information about getting ready to take the OTA its for the kitkat ota but still its all the same so this could be very useful! by [MENTION=1165307]KidJoe[/MENTION] http://xdaforums.com/moto-x/general/faq-kit-kat-how-to-prepare-carriers-t2536735

or If you have an unlocked bootloader and are rooted, and the only change you did to your phone was replacing recovery to root.. Here is another option to flash Stock Recovery back on your phone to get ready to install the latest OTA -> http://xdaforums.com/moto...ooted-t3027079 credits goes to [MENTION=1165307]KidJoe[/MENTION] .

PRECAUTIONS (A MUST READ BEFORE PROCEEDING ANY FURTHER)

I am not responsible if anything happens to your device during this process because I am just explaining here what to do I wont be the one who is applying the instructions on any phone so in no matter or aspect I am the responsible for damage caused to your device. So again do this on your own risk. I wont be responsible for any damage to your phone.

1: NEVER DOWNGRAED FIRMWARE/BOOTLOADER VERSION!

Okay so you want to downgrade to get the advantages of the previous android version of your phone. THE ANSWER IS A BIG NO! if you try to downgrade your phone and mess up with motoboot.img or gpt.bin you will get a hard brick! Never try to downgrade! Refer to this thread http://xdaforums.com/moto-x/general/info-warning-risks-downgrading-impacts-t3058202 by [MENTION=1165307]KidJoe[/MENTION] to know all the facts about downgrading.

2: Downlaod the exact and correct firmrware, before flashing

Flashing another carriers rom on your phone would be a stupidity. MAKE yourself 100% sure that you have downloaded the correct/exact firmware of your phone, never flash some random firmware on your particular moto x. Flashing another carriers rom would give you a hard brick probably.. Never play with different firmwares. (I will be mentioning further in the thread, how to make sure to download the correct firmware.)

3:You must consider of having an Unlocked Bootloader before proceeding any further, Or if you have a locked bootloader this method might work on the locked bootloaders also but, again flashing different carriers firmware on a locked bootloader device will get you more screwed up

This method should also work for the locked bootloaders but be 100% sure that you are flashing the correct signed firmware of your specific carrier. As for the Bootloader Unlock, There are not much of options for now, You can unlock your bootloader either from the motorola official site or use sunshine unlocker to unlock your bootloader. Refer to this thread : http://xdaforums.com/moto-x/general/request-help-exploit-moto-x-bl-t2828471 by [MENTION=2509024]samwathegreat[/MENTION] to have an idea about the sunshine unlocking method.

Also refer to this also for info about gaining root and unlocking bootloader http://xdaforums.com/moto-x/general/one-stop-shop-how-root-moto-x-confusion-t2826159 by [MENTION=1165307]KidJoe[/MENTION].

4:You messed up your stock rom and freezed some apps

If you have rooted, put xposed etc. Dont plan to revert back by restoring the freezed apps and Instead just flash the stock firmware from RSD. Restoring back freezed apps etc will cause more problems. But make sure you uninstall all of the frameworks of xposed before proceeding to flash stock firmware.

5:This method will wipe your data completely

As the Title says this method will obviously wipe every single piece of your personal data stored on this phone such as pictures,contacts,videos and pretty much everything. So be sure to backup your data on your pc or anywhere.

Grab Your Phones Its time to start the process. Make sure its charged more than 60%.

Okay enough theory, lets get this over with.

Download and install motorola drivers : https://motorola-global-portal.custhelp.com/app/answers/detail/a_id/88481 and restart you computer and proceed.

STEP 1: Identifying the correct name or model number of your Moto X

1: If the original motorola back cover is on the phone, there is some very fine/small print at the bottom of the back. It will have the FCC ID, Model number, etc. It could be hard to see, So you might have to tilt/twist the phone so the light shines off it just right and the model no appears. The Model No of your MOTO X should start with XT. Make a note of that. (credits goes to [MENTION=1165307]KidJoe[/MENTION] for explaining this in detail.)

2:Another way to find the model is by checking the Settings>About Phone of your X.

3:More ways to find out your model no, Connect the phone with the pc and see what does it shows on the pc when connected on USB MASS STORAGE. It should mention the XT10xx (Model name) of your phone on pc

NOTE:BEFORE you flash away from Stock, on the phone you first go App Drawer -> Settings -> About Phone... Make note of what is listed under System Version, Android Version, and build number. Then visit one (or all) of the sites until that host the leaked SBF files until you find the SBF that matches and down load the file to your PC for use later.. The file name will usually contain parts or all of that info listed under settings, and possibly the carrier name, or acronym for the carrier name (Verizon might be VZW, Rogers Canada might be RCI, etc).

So for example: If your phone model is XT1058 and under about phone it reports...

android version is 4.4.4

system version is 212.44.26. ghost_row.RCI.en.ca

build nunber is KXA21.12-L1.26

That tells me you have a Rogers Canada (RCI) XT1058 with 4.4.4 ROM on it. When you look at the file factory site for your SBF, you want to look for a file that contains some/all of that info, like... XT1058_RCI-CA_4.4.4_KXA21.12-L1.26_59_cid14_CFC_1FF.xml.zip

(notice the parts of the "about phone" info and file name which are highlighted in Bold to help illustrate the example)

IF you are already running a CUSTOM or 3Rd party rom, like CM, system version and build number will not match STOCK Moto SBF files. credits goes to [MENTION=1165307]KidJoe[/MENTION] for adding this additional info about figuring out what ROM is on your phone.

STEP 2: Identifying and downloading the correct firmware for your model of X

1:So now that you have identified, your Moto X is XT10xx, Now you will be downloading the correct firmware of your phone which should match the System/Build Version of your phone.

For Example: If your phone is from Rogers,ATT,Sprint,T-Mobile,US-CELLULAR,Europe etc. IT should be mentioned in the Settings>About Phone section below build version. Make a note of the whole build version/system version on a piece of paper or anything you like. Because the system/build version is the main key to have the proper knowledge about your phone before flashing any firmware.

Additional Info about bootloaders according to android version(This will give an idea about bootloaders, read it carefully and match the version of you bootloader in order with this dont downgrade):

(Android Version: Bootloader)

4.2.2: 30.70

4.2.2/camera patch OTA: 30.71

4.4: 30.B2

4.4.2: 30.B4

4.4.4: 30.B7

2:Now this part must get hard for the newbie guys but I will try my best to keep everything clear and easy. All The firmwares you need for your X is available at this site: http://www.filefactory.com/folder/dd05c058d3ff8dbe/?sort=created&order=DESC&show=100&page=1

Now start by searching the model no and system version of your moto x. For example: if your phone is from Rogers Canada it must have "XT1058 RCI_CA " in it.. XT1058:Model Name Rci: Rogers CA: Canada. You get this right? on the firmware there should be mentioned a little bit hint or info you need to identify your firmware. Go ahead and download it. Again for the newbie guys I cant explain much easier than i've explained above, Still if you cannot find the correct firmware let me know I will try to find it out. But please first try your best from your own side first, I cant spoonfeed you [emoji14] . ATTENTION: Please download the 4.4.4 Version of your carrier because it will be easy to receive the 5.1 OTA on a 4.4.4 rom.

STEP 3: Getting ready to flash through RSD LITENote: I wont be explaining a method to flash through fastboot as from my opinion I dont like fastboot it can cause you a serious problem if you type anything wrong. If you want to try the fastboot method there is also another similar guide on how to flash through fastboot refer to this thread http://xdaforums.com/moto-x/general/guide-moto-x-return-to-100-stock-using-t2446515 by [MENTION=4273261]TechSavvy2[/MENTION]

1: Download RSD LITE 6.1.5 (RSD LITE SETUP IS ATTACHED download from there) and install it in your PC Windows. (I dont have a mac dont know anything about mac.)

2:Make a new folder and unzip the firmware zip file in that new folder

3: Open the XML FILE and edit the .XML file and remove any lines with "getvar" written in them, Remove that whole line which has "getvar" in it, and (CTRL+S) save that edited file.

3: RUN RSD LITE IN ADMINISTRATIVE RIGHTS on rsd lite right click and run as administrator, IF you dont run as administrator rsd lite wont flash anything.

4: Now on rsd lite press the three dotted "..." button and select the XML File from the "new folder" you made moments ago.

STEP 4: Getting your phone in fastboot mode

If you are totally fine and running your software normally: Power off your phone, wait for 5 seconds then press and hold the power/lock button and volume down button simultaneously for 5 seconds, then release those buttons after 5 seconds. You will be in the fastboot mode of your phone now plugin your phone on usb cable of your computer make sure the bootloader says "USB CONNECTED." If it doesnt shows usb connected sign, Change the usb cable or try another usb slot.

For the people who have damaged and corrupted the software and having black screens stuck and nothing else or either they did something naive and somehow cant get in the fastboot mode: Hook up your phone to an A/C Charger and wait for about 30mins to atleast recharge it. Then remove your phone from charger and dont press the power button! Do this: Press and hold the power/lock button and volume down button simultaneously for 5 seconds, then release those buttons after 5 seconds,If you are not properly bricked you will be on the fastboot now probably, now plugin your phone on usb cable of your computer make sure the bootloader says "USB CONNECTED." If it doesnt shows usb connected sign, Change the usb cable or try another usb slot.

For the people stuck on bootloop after flashing a 3rd party custom rom or stuck on the motorola logo etc. Do this: Press and hold the Power/lock button, Volume Up Button and Volume Down button, all the three buttons simultaneously for about 15 seconds, when the screen turns off, Quickly press the Power button and volume down button repeatedly (this time dont press and hold! Press both buttons repeatedly!) You will be on the fastboot mode of your phone plugin the phone on usb port and your bootloader should say "USB CONNECTED" AFAIK. If you are not bricked!

STEP 5:Flashing the firmware

On Rsd lite, make sure that your device is showing "Connected" Now, Press the start button on the rsd lite and wait for about maximum 30-40Mins to get your firmware flashed in the phone successfully. ATTENSION: Dont touch or power off your phone or computer during the flashing process untill or unless your device reboots and comes to its homescreen on the factory settings, make sure the usb cable is connected properly not loose. If you mess up anything during flashing process you are risking your whole phone so do this when you are calm enough.

Flashing Process Done Now You Are All Set Up To Receive The Latest OTA OF 5.1!

For the people who have flashed the 5.1 soak test/leak and are stuck at some certain point

So you couldn't wait and flashed the LEAKED test/soak versions of 5.02 and 5.1 and your bootloader is upgraded to 30.BC or 30.BD you are stuck on a bootloop and cant get your phone to work ----> There is nothing you could really do to save your self till now only one thing you can do is wait! DO NOT DOWNGRADE YOUR BOOTLOADER/FIRMWARE as that will risk bricking, but rather WAIT and hope a 5.1 SBF for their model/carrier leaks in the coming weeks/months, then fully flash it to return to stock. credits goes to [MENTION=1165307]KidJoe[/MENTION] for adding this info.

Good luck mates!

Thats all I can sum up in one thread, I hope this helps the new people. Peace Out.