1. Are you ready for the Galaxy S20? Here is everything we know so far!

[CDMA] How to manually flash a recovery image (via fastboot OR from SD card)

Discussion in 'Android Devices' started by novox77, Jul 29, 2011.

  1. novox77

    novox77 Leeeroy Jennnkinnns!
    Thread Starter

    As of this post, it would appear that the S-OFF tool, Revolutionary, may not successfully flash clockworkmod recovery for everyone. And once it S-OFFs your HBOOT, it won't run again, so there's no way to get it to retry the recovery flashing. The following is a guide on how to manually flash a recovery. May come in handy some day. Or you may want to wait for Revolutionary to address the issue. But if you're one of the people who has run Revolutionary and is without a recovery image, this is for you.

    For now, TeamWin has created a brand new recovery called TWRP, and it works great. You can download the image here:
    [RECOVERY] [EVO3D] TeamWin Recovery Project (twrp) v1.0.2 [7/31/2011] - xda-developers

    Or you can go with ClockworkMod recovery, which is what you would end up with if the recovery portion of Revolutionary succeeds:

    Choose which recovery you want to try, and save that image to your computer.

    There are two popular methods to flash a recovery. The easiest way is known as the update.zip method. The other way, fastboot, is more technical and requires that your PC is set up with drivers and the and fastboot tool.

    Both methods require that you boot your phone into HBOOT. If you are unsure how to do this, see this post: http://androidforums.com/evo-3d-all-things-root/362270-how-boot-into-bootloader-hboot.html

    This method can be used to flash to any partition, not just recovery. Essentially you place a file at the top (root) level directory of your SD card and HBOOT will automatically find the file and flash its contents. The filename needs to be named PG86IMG.ZIP for the Evo 3D, and it needs to contain the .img files named the same as the partition name.

    Most of the time, you don't need to worry about all this; the file you download will already be in the correct format. You just have to rename it to PG86IMG.ZIP. The link to TWRP recovery above is distributed in this update.zip format. All you need to do is rename it and put it in the root of your SD card. Then boot into HBOOT. HBOOT will automatically scan for the file, and if it was named correctly, it will ask you if you want to flash what's in the file. Say yes, and it will do it's thing. That's it.

    If you only have the .img file, you can make your own update.zip file. For example, if you have a recovery image file, it needs to be named recovery.img. Then, put it in a ZIP file without compression. Name the file PG86IMG.ZIP, and you're all set.

    This method requires a little more setup and is a bit more manual than the above update.zip method, but in my experience, having a computer set up to run fastboot and adb can come in handy, especially once you've graduated to an advanced power root user. If you ever want to help in the effort to crack bootloaders, having fastboot working is a must :)

    fastboot is a little executable tool that comes with the Android SDK. It is right alongside adb. If you have adb working, then fastboot is ready to go. Both adb and fastboot require that you have the HBOOT drivers installed for your phone. You can get the drivers here:
    public:revolutionary [RootWiki]
    (go to the part, "are any drivers required?")

    Once the drivers are installed, you should get the Android SDK here:
    Android SDK | Android Developers

    Just get the .zip file and extract it anywhere on your computer. Look for the /tools folder. In there, you'll see the fastboot executable.

    Ok, these instructions are for Windows users, but the equivalent steps should work for mac and linux:

    Open up a cmd window and go to your SDK tools folder. Now type

    Code (Text):
    1. fastboot
    and press enter. You should see a list of fastboot commands available. If you don't get that, you're probably not in the right folder. Check your path and where you installed the SDK and make sure you are in the /tools folder.

    Once you've verified you can run fastboot, it's time to move the recovery image to the /tools folder (easier not to have to specify a path to the recovery file). I would also rename the recovery file to something short like recovery.img.

    Once the recovery image is in the same /tools folder as fastboot, you'll need to put your phone in fastboot USB mode. To do this:

    1) make sure the Fast Boot option is disabled. Note, this "Fast Boot" has nothing to do with the fastboot executable I've been talking about. This is a setting in Sense to allow the phone to boot up faster. To disable this setting, go to Settings > Power > Fast boot (uncheck the box).

    2) Hold down the power button and select Power Off from the menu. Wait 1 minute for the phone to completely power off.

    3) Boot into HBOOT. See this post for detailed instructions on how to boot into HBOOT:

    4) Once you're in HBOOT, you'll see it scan for a few files. This is normal. When it is done, you can make selections in the menu. Vol-UP and Vol-DOWN allows you to move up and down the menu list. POWER button acts as ENTER and selects whatever you're highlighted over.

    By default, FASTBOOT is selected. So just press power.

    5) now you should be in the FASTBOOT section of HBOOT. Plug the phone in via the USB cable to the computer where you installed the Android SDK. You should see the red FASTBOOT banner turn into FASTBOOT USB. If that doesn't happen, it means that your HBOOT drivers aren't working.

    Your phone is now ready to accept commands from the fastboot executable that came with the Android SDK. Go back to that cmd window where we tested the fastboot command earlier. From there, issue the following command:

    Code (Text):
    1. fastboot flash recovery recovery.img
    Here's a quick explanation of the above command:

    fastboot: that's the executable tool
    flash: that's the function we want the fastboot tool to perform
    recovery: this is the name of the partition we want to flash into. since we are flashing a recovery image, it needs to go to the recovery partition.
    recovery.img: this is the name of the actual file to flash. Your filename may be different. Just make sure it matches the actual filename.

    Fastboot will flash the image and give you a success/failure notification. If successful, you're all set. To check out the new recovery image, verify that BOOTLOADER is selected in the HBOOT menu (should be highlighted in blue). Press POWER button to select it. Now you should be back at the main HBOOT menu.

    Use VOL-DOWN to highlight RECOVERY and press POWER button. The phone will now attempt to boot into the new recovery image. You'll see the htc splash screen briefly and then the recovery image. That's it!

    A note about ROM Manager:
    Some people have mentioned here and there that the easiest way to flash a recovery image is with the ROM Manager app, which is free on the Market. While this is true, I discourage people from using this app to flash their recovery IF they don't know how to use the two methods detailed above. Why? Because there may come a day when you have a bad flash, or you did something that prevents your phone from booting into Android, and you can't run ROM Manager. If, in this situation, you needed to reflash your recovery, you'll need to do it the manual way.

    If you are proficient in the manual flash, then by all means, use ROM Manager to change out your recovery image. Just be sure that the image it recommends is the proper one for the Evo 3D. It seems possible to use an old version of ROM Manager and flash a recovery not intended for the Evo 3D, so be careful.

  2. NYCHitman1

    NYCHitman1 Gun for Hire

    1.33 GB, it's looking like. Good grief.

    On a side note, for anyone that is having trouble with Fastboot - they uploaded a flashable version of TWRP which you can just drop on the root of the SD card and the bootloader will update it. Just remember to delete it after you install it.
    ocnbrze and EarlyMon like this.
  3. outkast25

    outkast25 Android Enthusiast

    I get "error: cannot load"recovery.img" after i type"
    fastboot flash recovery recovery.img
    i figured it out, i renamed the file with .img on the end instead of just "recovery"
  4. mynamewastaken

    mynamewastaken Android Enthusiast

    Make sure you have the file 'recovery.img' in the same folder as the 'fastboot.exe' command. If you downloaded the clockwork recovery image from this thread you'll also need to rename it to 'recovery.img'
  5. novox77

    novox77 Leeeroy Jennnkinnns!
    Thread Starter

    updated the OP to include instructions for the much easier update.zip (PG86IMG.ZIP) method of flashing the recovery image.
  6. EVO3D

    EVO3D Newbie

    As always great post Novox77! I really would like to say thanks for all the nice work you put in around here. But, I'm writing this right now because Revolutionary failed to load clockworkmod recovery on my phone. I know its happening to a lot of people but I think tha it's kind of crappy that it works for some people and not for others. And it seems like my luck (i.e. bad luck) that it didn't work for me, as I am a noob! Anyways, after reading a few things I decided to try to use the Fastboot Method. I was unsuccessful with loading the fastboot drivers (followed complex instructions off XDA Dev. because at the time I hadn't found your thread yet). Anyways after an unsuccessful attempt I moved onto trying the Update.zip Method of manually flashing a recovery image. Unfortunately, at first it didn't work for me. I followed your instructions to perfection!

    When I load into my phones bootloader the recovery option is in green, however when I click on it, the phone shows a red triangle with an exclamation point...Supposedly this means that I don't have a recovery image successfully installed on the phone.

    Forgive me if this sounds like a stupid problem to have but I'm a noob, and believe me this is my first time rooting so I expect a little trial by fire.

    Atleast I have been reading and reading about rooting for the last 2 days!
  7. EVO3D

    EVO3D Newbie

    In regard to my last post, I have figured out the issue I was having and fixed it...I now have root access!

    Here is how I went about fixing the issue I was having:

    I read the original post above and then sought out a Youtube Video called "TeamWin Recovery Installation Guide for HTC EVO 3D" and watched the video. Here is the link: ‪TeamWin Recovery Installation Guide for HTC EVO 3D‬‏ - YouTube

    In the video and in this orginal post it says to rename the TeamWin recovery file "PG86IMG.zip" however, this did not work for me. Instead I had to rename it "PG86IMG" (without the .zip extension). Then I dragged the file onto my SD Card and loaded up the bootloader. Once on the bootloader menu it will ask if you want to update the TeamWin Recovery file, I clicked 'Yes' as stated in the video and then proceeded to reboot the phone. Once the phone was back on the home screen I erased the "PG86IMG" from my SD Card and dragged the Superuser.zip file onto the SD card directory. Once finished I loaded into bootloader and clicked on Recovery and presto! I went in the recovery menu and able to load the .zip file that granted me root access!

    (Hope this helps someone, but just about 99% of this information was covered in this original post and in the Youtube video I linked. All of the credit goes to Novox77 and Youtube's willwhitworth.)
    JD_from_da_80s and novox77 like this.
  8. Does anyone know how to make a wimax.img using the twrp recovery software?

    I have seen with clockwork recovery that there is a backup option, but can not find that option with twrp.

    Ever mind, sorry just found it in the menu option. It was under the main menu called Naniod Menu, then selected backup, then selected all of the options, then clicked back up naow. Selected=press power button.
    EVO3D likes this.
  9. EarlyMon

    EarlyMon The PearlyMon
    VIP Member

    Have to be careful renaming files in Windows when known file extents are hidden.

    That results in rename attempts as XXX.zip.zip - and when renamed to XXX as shown on-screen, the actual name will be XXX.zip.
    novox77 and jamesdean like this.
  10. EVO3D

    EVO3D Newbie

    Yes, I was getting tired and not thinking things through.
  11. EarlyMon

    EarlyMon The PearlyMon
    VIP Member

    Well, how do think everyone else learned to call that out? ;) :p Just posted that for the next cat.

    Glad you got it nailed tho - that's the main thing!
  12. jerofld

    jerofld Fixing stuff is not easy

    I've always used Clockwork. How does TWRP compare to CWR? Any worthwhile/substantial differences?
  13. EarlyMon

    EarlyMon The PearlyMon
    VIP Member

    I use CWM, but I understand from novox77 and NYCHitman1 (by memory) that it includes being able to zip your nandroids (saving the 1.2 GB size I'm hitting now) as well as being able to be selective about which things you nandroid.

    Example, once you have your master nandroid, you don't need to keep including wimax stuff in your nandroid, maybe just /system.

    Somebuddy using it deeply will have to explain other options.
    jerofld likes this.
  14. EarlyMon

    EarlyMon The PearlyMon
    VIP Member

    For those of us using CWM!

    Last night I spent an hour trying to figure out why my phone wouldn't charge while powered off.

    ceabbott2 found and informed me that this is a bug in CWM - checking the CWM website, I found they had a image available there.

    Tired of dealing with this, I just grabbed the free version of Rom Manager from the Market.

    I went to the first option, install CWM - and then rebooted into recovery to see for myself what's up. was installed nicely and now when power is off, my phone recharges.
    ceabbott2 and OutofDate1980 like this.
  15. moosh62

    moosh62 Lurker

    Help....After installing revolutionary.exe, the recovery image was not loaded automatically. I tried loading the image manually and that did not work. After rebooting I was getting error 16 when making a call. I restored to factory default and error 16 did not go away. Sprint was able to resolve the problem. I have attempted to load the recovery image using the zip file and copying on the root of the SD card and also tried using fastboot and flashing it from my PC and neither method works. Any ideas !!!!
  16. falconey

    falconey Android Enthusiast

    Here's what I did. I went to my sdk folder. The fastboot option was located in android-sdk-windows\tools folder. then I opened up another folder window and went to android-sdk-windows\platform-tools and copied the files AdbWinApi.dll and AdbWinUsbApi.dll. I then pasted those files in android-sdk-windows\tools. You will also need to copy the clockwork.img file into this same folder(for simplicty). Now within that folder(android-sdk-windows\tools hold down the shift button and right click. Select the option 'open command window.

    in the command window type - fastboot devices and hit enter
    your device should be recognized

    now type -flashboot flash recovery clockwork.img(this is whatever your file name is)

    you should get a response of OKAY

    If you don't have sdk you can find it here

    Jackietreehorn, moosh62 and EarlyMon like this.
  17. jerofld

    jerofld Fixing stuff is not easy

    The NANDroid stuff alone is worth trying. My NANDroid is 1.53 GB. I have a 32GB SD card on the way, but that's besides the point...
    EarlyMon likes this.
  18. EarlyMon

    EarlyMon The PearlyMon
    VIP Member

    I've moved your post over to the main thread for this - please see falconey's answer and the other helpful posts here, I'm sure you'll be squared away in no time. :) ;)
    moosh62 likes this.
  19. novox77

    novox77 Leeeroy Jennnkinnns!
    Thread Starter

    So I noticed that the TWRP NANDroid images have .win extension. I expected .img. Does anyone know if they are using a proprietary format? Or if I can just rename it to .img?

    I suppose I'll be brave and rename it and try to flash it via fastboot and see what happens :)

    And regarding Windows hiding file extensions, they've been making that the default setting since Windows 95. So I have to assume that it's the best decision for most users of windows.

    Personally, I think it's rediculous to hide the extension. It's one of the first things I change in a fresh install of Windows, followed by showing all hidden files.
  20. EarlyMon

    EarlyMon The PearlyMon
    VIP Member

    I assume if it's been broken that long, no one is going to own up to the mistake now.
  21. JD_from_da_80s

    JD_from_da_80s Well-Known Member

    Yea, I'm gonna see if I can do some more reading on this. Doing a nandroid this morning, system, data & boot were checked to be backed up (default) while recovery, cache, wimax & .android_secure were not. I'm going to do two compressed back ups, (1 default, 1 custom) save em on my laptop & the one that takes up less space will be on my phone.
    EarlyMon likes this.
  22. jtlind01

    jtlind01 Member

    So I am curious I am not a seasoned vet on roms and recoveries and how to do everything but I saw all the posts on how to put clockwork mod as a recovery on manually and wondered why it is not being written on doing it through ROM manager. All I had to do was select flash clockwork mod and it flashed and installed in about 10 seconds. Like I said I'm nowhere near as advanced as everyone on here so it may have been written already and I missed it or what I flashed is not an updated version or something. Just thought maybe it was worth writing about.
    EarlyMon likes this.
  23. Cbelflower321

    Cbelflower321 Member

    Sorry if this is a noob question, but I have gotten to the part where i have to flash my own recovery.img file. I have downloaded the file and created a winrar archive then placed the recovery.img file inside. I put the winrar archive onto my sd card and rebooted into hboot. When I get there it shows that it is trying to read the file, but says there is no img file or something to that extent. What am I doing wrong?
  24. EarlyMon

    EarlyMon The PearlyMon
    VIP Member

    Have you verified that the winrar is simply packaging - and not compressing - the recovery.img file inside?

    Sorry, I'm not conversant with winrar (it's been at least a year or more since I was last near it) but that's a key point to making this work right.

HTC EVO 3D Forum

The HTC EVO 3D release date was July 2011. Features and Specs include a 4.3" inch screen, 5MP camera, 1GB RAM, Snapdragon S3 processor, and 1730mAh battery.

July 2011
Release Date
Similar Threads - CDMA manually flash
  1. marctronixx
  2. bobinyelm
  3. Samsung
  4. Gourav Sarker
  5. notableuser
  6. Christina M Young
  7. consultant
  8. mdshanks1
  9. Spencer Holt
  10. lazyinformant7

Share This Page