So I recently upgraded my Z3 Compact to Android Lollipop 5.1.1. The upgrade went fine but the process of downloading the necessary files were a pain in the ass.
Why? Because downloading the firmware files using the XperiFirm is very slow (well, sometimes)!
Anyway, this post is not for me to rant about it but to teach you on how to avoid waiting for too long for the XperiFirm to download those firmware file updates. We will discuss the following topics in this post (seriously. I feel like a teacher right now):
- How to download firmware files using a download manager
- How to unpack firmware files
- How to create custom FTF files (lets assume that you wanted a pre-rooted FTF)
- How to create a flashable .zip file
…Yeah. I did drown you to some technical jargon. Before we continue, lets define everything first.
Definition of Terms:
- Z3 Compact – An epic small form factor phone from Sony
- Android Lollipop – The latest version of Android operating system available to users
- XperiFirm – A tool used for downloading Sony Xperia firmware files
- Flashtool – A tool used for creating unbricking / flashing / creating FTF files
- Unbricking – A process in recovering a phone from a corrupted software state
- Flashing (this is not the NSFW term. *wink*) – A process in which a phone’s system files are modified
- FTF – A file used by Flashtool in flashing mobile phones
- PRFCreator – A tool used to make a flashable .zip file used by a custom recovery installed in the phone
- Custom Recovery – A modified part of the phone’s system in which users can use to flash / backup / restore / or reset their phones without using the official Android OS.
Wheew. That was very long. I hope those terms covers everything in this post. With that out of the list, let’s move on.
Get the list of URLs for download
Ahh yes. XperiFirm. This is a great tool used by power users in order to bypass queuing to over-the-air updates for Sony devices. But more importantly, this tool is used in downloading firmware files for later use.
I realized the XperiFirm was created by Iagucool. The same person whom I looked up to during the days of Nokia n97 flashing. He created the custom firmware “IC@Darkstream” to which up to this date my n97 uses. He is a great dev by the way. 🙂
Now go and fire up your XperiFirm. If you don’t have a copy of the tool, go can go here.
After you have checked and verified that you have the same XperiFirm program, go and choose your firmware.
Once you have picked your firmware, a download menu will appear.
Now, click “Manual” and XperiFirm will notify you that the links were copied to your clipboard.
And here’s what a sample URL from XperiFirm looks like.
Once you have to URLs, you can now go to your favorite download manager and start downloading your firmware files!
Download those firmware files
Internet Download Manager (IDM), Free Download Manager (FDM), etc. Those are some of the most popular download managers out there. It doesn’t really matter which download manager you will use as long as it can download multiple files simultaneously (seriously, we wouldn’t call it a download manager if it can’t handle multiple files).
Collect those downloaded files
Fast forward to the future, you now have those firmware files ending in .bin right? (uhhm. yes). Good. Now we shall unpack those firmware files using…
…XperiaFirm! (If you guessed Flashtool, you are incorrect. Better luck next time!)
Now move your files to a single location where XperiFirm is located.
Remember the last popup window in XperiFirm? What does it say?
Yes, you should click “OK” after you have downloaded the files and moved it in the same folder together with XperiFirm.
After clicking “OK”, XperiFirm will ask you if you want to unpack the files, click “Yes”, select the folder where the files are located and click “OK”.
XperiFirm will throw you an error if some files are missing (see below). In my case, I am missing this specific file.
But how? I downloaded everything right?
Sometimes, errors like this happens because the download manager is changing the file names of the downloaded firmware files. In my case the “+” symbol was deliberately changed to ” ” that is why XperiFirm could not find the said file.
Now let’s check our files and rename it.
Tip: It will be very helpful if you save the download links to notepad for future references.
After renaming the files to their correct file name, we can now redo the unpacking process. Head to…
…XperiFirm (you got it right!) and unpack the files.
After the successful unpacking, you will notice that the files in the working folder (XperiFirm folder) have changed (did they just evolved?).
We just unpacked the files. So what’s next?
We will use the next tool to create our FTF – the Flashtool.
Creating the FTF file
Ladies and Gentlemen. Welcome to Flashtool! The one stop-shop for creating and flashing firmwares!
Oh by the way, you can get Flashtool here.
As most of you may have recalled, we have unpacked the firmware files and get a bunch of new files in our working folder. Our current working folder was the XperiFirm folder. Now, for safety reasons, we will move those files to a new folder named Flashtool. This will be our new working folder.
Now, lets open Flashtool and create that FTF file.
Head to Tools > Bundle > Create. A window will appear where you will have to fill it up with details.
- Select source folder: click the “…” button and select the folder where we placed the unpacked firmware files
- Device: Double click on the field to view the list of devices. Select your device and press “OK”.
- Branding: Place the operator name here. This is found in the XperiFirm download window. (I think this is not a mandatory field so you can just give this field any value that you like.)
- Version: Well, its self explanatory. You know what you need to put here. Again, refer to the download window in XperiFirm.
- Folder List: This lists all the files from the unpacked firmware files. Select all from this list (left side) and click “->” to move it on the Firmware content list.
After filling up the fields above, you can now click “Create”.
After the process, an FTF file will now appear in this location:
Now that we have the FTF file, we can now create a flashable zip (at last!)!
Creating the flashable zip
Head to the location where Flashtool saved your FTF files and move the FTF file to a new working directory named “PRFCreator” together with the PRFCreator and other flashable zips that you want to include.
You maybe asking why I have more than enough files in the working directory. The other files (.zip) are for the custom recovery, root (Super Administrator) app, and to bypass SD card write permissions. Don’t worry, the flashable zip will work even if you don’t have these additional .zip files.
Now, let’s run PRFCreator.exe and create our flashable zip.
Select the FTF file, SuperSU Zip file (if any), Recovery Zip (if any), and any other extra zips (if any). Check all boxes including the “Sign zip” and click create.
Congratulations! You now have a flashable zip for your Sony Xperia Z3 Compact update!
Now why do I need a flashable zip file?
Normally, you will only have to follow these instructions until you reach the Flashtool stage. However, since some of the users out there (including me) wants to create a pre-rooted file and a flashable zip for easier installation / update, I continued the guide up to the flashable zip stage. Personally upgrading via custom recovery is much much easier compared to upgrading via Flashtool. No cords and no Flashtool application needed. Just your mobile phone and the custom recovery.
That’s all folks!
Now, go ahead and upgrade your device!