FORUMS
Remove All Ads from XDA
Win Honor 9 Lite

[FIX] Unbrick Nexus 5 stucked in Qualcomm HS-USB QDLoader 9008 mode

1,544 posts
Thanks Meter: 1,244
 
Post Reply Email Thread
Requirements:
  • Bricked Nexus 5
  • EMMC should not be fried
  • Image files: 16GB (mirror) and 32GB (mirror)
  • BoardDiag (mirror) tool for Nexus 5
  • Windows XP - 7 - 8 - 8.1 (Virutal Box or VMware good too)
Let's start!
  • Connect the phone to your PC
  • Open Device Manager

1: Find Qualcomm HS-USB QDLoader 9008 device under Ports (COM & LPT) and note the COMxy port (in my case it is COM3).
If you dont see Qualcomm HS-USB QDLoader 9008 click on the CLICK TO SHOW CONTENT button bellow, otherwise don't and follow the guide.


1: If you see LG Android USB Device under Other devices or LGE AndroidNet USB Serial Port under Ports (COM & LPT), then press VOLUME_UP+VOLUME_DOWN+POWER keys until you see QHSUSB_BULK under Other devices or Qualcomm HS-USB QDLoader 9008 device under Ports (COM & LPT).

1: If you see QHSUSB_BULK under Other devices, then you have to install drivers (mirror). Just click on Next, Next... and Finish.
You have to turn off driver signature enforcement if you are using Windows 8 or Windows 8.1 to make the drivers work.
  • Extract the downloaded images 16GB.rar or 32GB.rar to get the image files
  • Start BoardDiag

1: Select Nexus5 (MSM8974_HammerHead).
2: Select the Com Port you see in Device manager (in my case it is COM3).
3: Select the 16GB or 32GB folder.
4: Select AP check.
5: Select RESTORE BOOT IMG.

1: Click on START.

If you were successful you should see Boot images download completed.
Your phone should turn on, but it may stuck at Google logo. If it is stucked at Google logo you have to reflash a stock rom. You can use either LG FlashTool or fastboot method. You can also flash custom rom from custom recovery if it didn't get replaced by the stock recovery, otherwise flash custom recovery from fastboot.

Extra fun

Quote:
Originally Posted by bitdomo

OP updated.

I want to make a little comment about this boarddiag tool, and how it works.

Emmc test:

Erase: erase the whole emmc. Even if you select a partition from the dropdown menu,
Read only: Only reads random blocks from the emmc. If you check DUMP it will read back the amount of blocks of a the chosen partition given in the partition.txt
Write only: writes dummy data to the emmc (55AA hex values and some other other random writes on the actual partition).
Read/Write: writes dummy data to the emmc (55AA hex values and some other other random writes on the actual partition) and then verify them by reading it back
SDRAM test:
I think this test the memory. There is a Level option for it. I dont know what is the differance between the two.
PIMC ON:
No idea, but in some LG documentations it is for only APQ8064 chipset.
Restore boot img:
Restores the images.
How it know which partitions have to be restored?
There is a rawprogram0.xml in model\Nexus5 (MSM8974_HammerHead)\boot_partition_info folder.
The partitions declared here will be flashed to the device if you select nothing in the partititon dropdown menu or in the restore boot img dropdown menu
Boarddiag only cares about the "label" value (have to be tha same as in partition.txt) from rawprogram0.xml. The rest info like startblock, files size and file name will be acquired from the partition.txt.
Partition.txt is a binary file:
0x00-0x03: start block
0x04-0x07: file size in block numbers ( 1 block = 512 byte)
0x08-0x0F: always zero
0x10-0x2F: partition name (must be the same as the label value in rawprogram0.xml)
0x30-0x4F: file name
and the pattern goes on.
I wrote a little program which converts this binary partition.txt to an actual txt. You can get it from here
Copy the partition.txt to the same folder where the bin2txt and txt2bin exes are. Run bin2txt then it will create a readable_partition.txt file. Edit it with notepad++. The start block is in HEX and the file size is in bytes (must be multiple of 512). Partition entries is the number of partition declared in the partition.txt. If you done with the editing then run txt2bin and it will create a new_partition.txt file.




Old OP
Requirements:
  • Bricked Nexus 5
  • EMMC should not be fried
  • Firmware file: D820 and D821
  • BoardDiag tool for Nexus 5
  • Windows XP - 7 - 8 - 8.1 (Virutal Box or VMware good too)
Let's start!
  • Connect the phone to your PC
  • Open Device Manager

1: Find Qualcomm HS-USB QDLoader 9008 device under Ports (COM & LPT) and note the COMxy port (in my case it is COM3).
If you dont see Qualcomm HS-USB QDLoader 9008 click on the CLICK TO SHOW CONTENT button bellow, otherwise don't and follow the guide.


1: If you see LG Android USB Device under Other devices or LGE AndroidNet USB Serial Port under Ports (COM & LPT), then press VOLUME_UP+VOLUME_DOWN+POWER keys until you see QHSUSB_BULK under Other devices or Qualcomm HS-USB QDLoader 9008 device under Ports (COM & LPT).

1: If you see QHSUSB_BULK under Other devices, then you have to install drivers. Just click on Next, Next... and Finish.
You have to turn off driver signature enforcement if you are using Windows 8 or Windows 8.1 to make the drivers work.
  • Extract the downloaded firmware .zip to get the .tot file
  • Start BoardDiag

1: Select .tot file.
2: Select a directory where to extract .tot file.
3: Click on Extract.
It may hangs on extracting system and cache. Just let it finish.

1: Click OK.

1: Select Nexus5 (MSM8974_HammerHead).
2: Select the Com Port you see in Device manager (in my case it is COM3).
3: Select the directory where you extracted the .tot file.
4: Select AP check.
5: Select RESTORE BOOT IMG.

1: Click on START.

If you were successful you should see Boot images download completed.
Your phone should turn on, but it may stuck at Google logo. If it is stucked at Google logo you have to reflash a stock rom. You can use either LG FlashTool or fastboot method. You can also flash custom rom from custom recovery if it didn't get replaced by the stock recovery, otherwise flash custom recovery from fastboot.


Thanks @jd1639 once again for the GPT partition table of the 32GB variant.
The Following 90 Users Say Thank You to bitdomo For This Useful Post: [ View ] Gift bitdomo Ad-Free
 
 
1st March 2015, 02:22 PM |#2  
doctor_droid's Avatar
Senior Member
Flag Indore
Thanks Meter: 1,952
 
More
Superb tutorial...its like recovering semi hardbricked phone..
The Following User Says Thank You to doctor_droid For This Useful Post: [ View ] Gift doctor_droid Ad-Free
1st March 2015, 02:31 PM |#3  
Retired Senior Moderator - Be careful not to choke on your aspirations
Flag The Dark Side
Thanks Meter: 23,017
 
More
Great job!! 🍻
The Following User Says Thank You to Darth For This Useful Post: [ View ] Gift Darth Ad-Free
1st March 2015, 02:49 PM |#4  
Elluel's Avatar
Senior Member
Flag えうれる
Thanks Meter: 3,236
 
More
@bitdomo Nice, once again.

Added this thread to the Sticky Roll-Up thread.
The Following User Says Thank You to Elluel For This Useful Post: [ View ] Gift Elluel Ad-Free
1st March 2015, 07:17 PM |#5  
OP Senior Member
Flag Göd
Thanks Meter: 1,244
 
Donate to Me
More
Quote:
Originally Posted by Lethargy

@bitdomo Nice, once again.

Added this thread to the Sticky Roll-Up thread.



---------------------------------------------------------------------------

The tool is working. I tested on my nexus 5. I dd zeroed out the sbl1 partition. The phone refused to turn on no matter what I do. I did that what is shown in my first post and now the phone is working again. I also tried to help a guy, but it turned out the emmc of his phone has an I/O error. I used the EMMC TEST option to check the emmc for bad sectors.

I am also summoning @rootSU to let him know what a cool stuff nexus 5 has.
The Following 8 Users Say Thank You to bitdomo For This Useful Post: [ View ] Gift bitdomo Ad-Free
1st March 2015, 07:36 PM |#6  
danarama's Avatar
Senior Member
Flag Oxenhope, West Yorkshire, UK
Thanks Meter: 19,658
 
More
Quote:
Originally Posted by bitdomo

I am also summoning @rootSU to let him know what a cool stuff nexus 5 has.


Meh, I have a nexus 6. One hit to the bridge of the nose can kill a man before his head hits the floor.

---------- Post added at 07:36 PM ---------- Previous post was at 07:29 PM ----------

Superb work though, really!
The Following User Says Thank You to danarama For This Useful Post: [ View ] Gift danarama Ad-Free
1st March 2015, 10:13 PM |#7  
theesotericone's Avatar
Senior Member
Thanks Meter: 2,494
 
More
Quote:
Originally Posted by bitdomo

I tested on my nexus 5. I dd zeroed out the sbl1 partition..

Now that is dedication. Welcome back man.
The Following 2 Users Say Thank You to theesotericone For This Useful Post: [ View ] Gift theesotericone Ad-Free
2nd March 2015, 12:11 PM |#8  
Senior Member
Flag Fondi, LT
Thanks Meter: 368
 
More
Maybe this could work or be adapted for Nexus 4? I ask for personal curiosity

Inviato dal mio Nexus 4 con Tapatalk 2
2nd March 2015, 12:14 PM |#9  
OP Senior Member
Flag Göd
Thanks Meter: 1,244
 
Donate to Me
More
Quote:
Originally Posted by jacomail95

Maybe this could work or be adapted for Nexus 4? I ask for personal curiosity

Inviato dal mio Nexus 4 con Tapatalk 2

It could be if we would have the flash programmer hex for nexus 4. I have some for some LG phone, but I have no idea are they working or they are for which phone. If you have a bricked nexus 4 or you know somebody who has I could try check the remaining flash programmers. Maybe 1 works for nexus 4.
The Following User Says Thank You to bitdomo For This Useful Post: [ View ] Gift bitdomo Ad-Free
2nd March 2015, 09:44 PM |#11  
Senior Member
Flag Fondi, LT
Thanks Meter: 368
 
More
Thanks for your patience and information Have a nice week

Inviato dal mio Nexus 4 con Tapatalk 2
Post Reply Subscribe to Thread

Tags
d820, d821, nexus 5, qhsusb_bulk, qualcomm hs-usb qdloader 9008

Guest Quick Reply (no urls or BBcode)
Message:
Previous Thread Next Thread
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes