[Nexus 6P Q&A, Help & Troubleshooting] Sass86oh:
Fastboot (also refered to as "download mode") is a tool used to essentially reprogram your device in the event that you are unable to enter into recovery mode in oreder to fix whatever issue your device is having. Android devices have 3 working modes, normal function, recovery mode, and fastboot. Number one is obvious, recovery allows you to completely reset your device without using a computer if every other measure youve tried hasn't worked. When you use this feature everything on your device is erased and your phone is completely restored to factory settings. Its convienet becuase not everyone is computer savvy and its to the point. But say you were updating (system update) your phone and accidently dropped it causing the battery to fall out and the device to shut off in the middle of the update process. What will most likely happen is the system partition will become corrupt, causing the phone to stick at the initial boot screen. Usually if that happens you can still access recovery mode and just reset but if for some reason that didnt work you would go to the manufacturers website and download the latest firmware for your device. You put the phone into fastboot mode by holding volume down and then pressing and holding the power button at the same time (while the phone is off).The process varies bydevice, If done correctly you will see on your screen a bunch of info along with Andy (the Android) chillin with his hatch open. You connect your phone to your computer and as long as your computer is set up correctly with adb and fastboot, you now have the abailty to reprogram (flash) your device using a series of commands that are issued from either the command line (windows) or terminal (linux/mac).

YOUR BOOTLOADER NEEDS TO BE UNLOCKED BEFORE CONTINUING. IF YOU DONT SEE A LITTLE LOCK AT THE BOTTOM OF YOUR DEVICE UNDER THE GOOGLE LOGO WHEN YOU FIRST TURN IT ON THEN YOU NEED TO GO TO SETTINGS, ABOUT DEVICE, FIND BUILD NUMBER AND TAP IT RAPIDLY UNTIL YOU SEE A MESSAGE POP UP SAYING YOU UNLOCKED DEVELOPER OPTIONS. GO BACK TO THE SETTINGS MENU AND SELEC DEVELOPER OPTIONS WHICH SHOULD NOW BE THERE AND INSIDE THERES AN OPTION CALLED "ALLOW OEM UNLOCKING" TURN IT ON. AND CONTINUE

Eextract the firmware archive you downloaded which will produce a folder containing 2 ".img files" files, another ".tar" archive, and some script files that you can use to make the process pretty much automated.

There are two of them, one for Windows (flash-all.bat) and one for Linux and Mac (flash-all.sh)....

Open the folder that was extracted from the firmware archive... Hold shift then right click a blank area in the folder. Select "open command prompt here" (Windows)

or

Type in terminal : cd ~/downloads/xxx where "xxx" is the name of the folder that was extracted but make sure that folder is moved to your "downloads" directory first

Then type the following commands:

IF YOU HAVENT UNLOCkED YOUR BOOTLOADER BEFORE THEN THIS IS WHERE YOU WILL NEED TO:

For Mac/Linux type: ./fastboot flashing unlock **Make sure you use the ./ or the command wont be recognized**

For Windows type: fastboot flashing unlock

Select yes on the phone when it asks if youre sure..... BAM, unlocked bootloader.

Your phone is completely free of restrections if you want to install custom firmware now. If not you can relock it after flashing the stock firmare by enterning fastboot mode again and typing

fastboot flashing lock or ./fastboot flashing lock (mac/linux).....

Now we can proceed with flashing the device...

For Windows: flash-all.bat and hit enter. The computer will do the rest.

Linux/Mac: ./flash-all.sh Make sure you use the ./ or the command wont be recognized.

If youre feeling brave you can do the entire process yourself by extracting the files in that second archive that was produced and flash each of them individually using a series of command in a specific order.

The 2nd extracted archive will give you a folder with five .img files

boot.img

cache.img

system.img

recovery.img

userdata.img ***** DO NOT FLASH THIS IMAGE. FORGET ITS EVEN THERE****

Take all five and move them to the original folder that was extracted. There are 2 other .img files that were extracted from the first archive also like I mentioned above, one that says "BOOTLOADER.xxx.xx.img" and one that says "RADIO.xxx.xxx.img"... Rename RADIO.xxx.xxx.img to | radio.img |and the other to| bootloader.img |ALL LOWER CASE keep them in that folder along with the other five. Now you should have 7 total image files in one folder. (Its smart to use the folder that your command prompt or terminal was opened in, if you decide to use a different folder then you have to direct each fastboot command to the folder where the .img file is located.

from the command line you flash each img individually with the following commands.....

(Mac/Linux need to include ./ before every fastboot command begins like this: ./fastboot or it wont work.

fastboot flash bootloader bootloader.img

fastboot reboot-bootloader (phone will reboot then go back into fastboot mode, dont worry should only take seconds)

fastboot flash radio radio.img

fastboot reboot-bootloader (reboots again)

fastboot flash boot boot.img

fastboot erase cache

fastboot flash cache cache.img

fastboot flash recovery recovery.img

fastboot flash system system.img

fastboot flash vendor vendor.img

fastboot format userdata (this command takes place of the "userdata.img" file I told you to forget about)

fastboot reboot

As long as you see action on the screen and a "complete" after every command then youre in business. If you get an error check your spelling. THE COMMAND LINE IS CASE SENSETIVE. You might type the correct words but if one letter is capital the command wont work. If theres an extra space between words then the command wont work so check everything. Safe rule: Everything should be in lower case letters with 1 space after every word.... THIS S*** MATTERS

Its not as hard as it seems if you arent familiar with the process, but its also not something to mess with unless youve done your homework. Read up on it, there are so many good posts and people in here so you'll be able to find everything you need without any issue.

Fastboot can also be used to install a custom recovery like TWRP which would then allow you to install custom firmware (roms) on your device as long as theres support for it. Nexus devices are built for that very reason! They tend to have a huge selection of development within the Android community. They come with Android as Google intended it to be! No extra BS.... And its wicked easy to unlock the bootloader. That is why they are, in my opinion, the best Android devices available. But someone who doesnt really care much for things like modding and installing custom firmware might see the Nexus as plain device which lacks the bells and whistles included in other devices. Which is ok! I personally love the simplicity of pure Android and the whole philosophy behind the Nexus Program. To each is own! If you need anything else send me a message!