Android Debug Bridge (ADB) and Fastboot are two important utilities that one must know about, and these are a significant part of a rooting toolkit. Most people find it difficult to understand and differentiate between the two utilities. Both the utilities resolve a different issue but are combinedly used to unlock access to the Android system when a smartphone is connected to a PC via USB cable.
The Android Debug Bridge (ADB) is a versatile command-line tool that works when an Android is running, and it lets you create communication with a device. It also facilitates a variety of device actions. One can use it for installing and debugging apps, tweak hidden settings, access system folders, etc. It will help you with multiple purposes. In contrast, Fastboot works when the Android is not working, and the device gets booted into Fastboot mode. It lets you reflash system partitions on your Android device. These two utilities are a significant part of an Android software development kit’s Platform Tools collection. You can use these via Command Prompt (on Windows) or Terminal (on Mac and Linux).
Now that you have learned the basics, here is how you can set up the ADB and Fastboot utility:
- Start by setting up your phone by going to the Settings app.
- Then, click on About Phone and tap on the Build Number seven times to enable the Developers Options.
- In the Settings page, checkmark the box for USB debugging and check the following dialogue box.
Then, you can download the ADB and Fastboot from the Android Developer website. While unzipping the downloads, all the data will get collected inside Platform tools. Windows users will also have to download the drivers from the Android Developer website. You can then use the Command Prompt or Terminal, depending on the device you use. Here is what to do:
- Open the Command Prompt or Terminal app on your device.
- Now, go to the platform-tools folder for using the ADB and Fastboot utility.
- Type the following command and hit the Enter key:
cd [path to platform-tools]
- If you are using Windows, you can hold the Shift key while right-clicking the platform-tools folder. Then, click on ‘Open Command Prompt Here.’
Note that the commands for Windows and Mac or Linux are different. So, Windows users will write ‘adb,’ and Mac or Linux users have to write ‘./adb’ for every ADB command. For Fastboot commands, write ‘fastboot’ on Windows and ‘./fastboot’ on Mac or Linux. Below, we will mention the steps for Windows, which you can tweak according to your system.
Following are the steps for using ADB:
- Start by booting your phone into Android and connecting it to your PC with a USB cable.
- On PC, open Command Prompt and change the directory to the platform-tools folder.
- Enter the following command and hit the Enter key:
- adb devices
- You will find a list of attached devices with a serial number.
- Now, type ‘adb’ followed by the command you want to execute.
If you are going to use Fastboot, know that it works the same way as ADB. The only difference is that you have to boot your phone into Fastboot mode instead of Android. To do so, press and hold power and volume keys together when turning on the phone.
When to Use ADB and Fastboot?
Now that you have learned to use ADB and Fastboot, you must know about the tools you can use with these two utilities. Here are a few examples of what you can try:
- Use ‘adb pull [path to file] [path to folder]’ for copying the files stored on your phone, and save them into a specified folder on your PC.
- Using the ‘adb push [path to file] [path to folder]’ command, you can send files from your desktop to your phone.
- With ‘adb install [path to file],’ you can install an APK app on your phone.
- You can even tweak your display’s pixel density using the ‘adb shell wm density [dpi]’ command. Note that using a lower number will make space for more content to fit onto the screen, and a higher number will consume space and hold less content.
- Use ‘fastboot -w’ to entirely wipe your phone and prepare it for flashing a custom ROM.
- Using the ‘fastboot update [path to rom.zip]’ command will flash a custom ROM.
This was everything you needed to know about the ADB and Fastboot utility tools. Note that the commands mentioned above will offer you essential guidance, which you can tweak as per your preference. You have to be careful while using the commands with ADB and Fastboot, so take your time to understand them and try when you are sure about it.
No comments:
Post a Comment