Introduction and Install ADB and Fastboot (Windows, Mac OS X, Linux)
Selasa, 20 Oktober 2015
Tulis Komentar
Before you perform the installation of the ADB and Fastboot least, it's good and knowing some of the terms as below:
What is ADB?
The Android Debug Bridge (ADB) is a client-server program used in Android application development. The Android Debug-Bridge is part of the Android SDK and is made up of three components: a client, a daemon, and a server. It is used to manage either an emulator instance or an actual Android device.The Android Debug Bridge (ADB) is a client-server program used in Android application development. The Android Debug-Bridge is part of the Android SDK and is made up of three components: a client, a daemon, and a server. It is used to manage either an emulator instance or an actual Android device. It is a client-server program that includes three components:
- A client, which runs on your development machine. You can invoke a client from a shell by issuing an adb command. Other Android tools such as the ADT plugin and DDMS also create adb clients.
- A server, which runs as a background process on your development machine. The server manages communication between the client and the adb daemon running on an emulator or device.
- A daemon, which runs as a background process on each emulator or device instance.
What is Fastboot?
Fastboot is a protocol that can be used to re-flash partitions on your device (update the flash file system in Android devices). It is this small tool that comes with the Android SDK (Software Developer Kit), which is an alternative to the Recovery Mode for doing installations and updates.
Not all phones have a fastboot mode that the user can access. It’s turned on with Nexus devices by default as well as a few other phones and tablets and has been enabled by independent Android developers and enthusiasts on some other phones.
How To Install ADB and Fastboot for Windows
For Windows Operating System, there are two tools that are made in this post, the first (15 Seconds ADB Installer) and the second with (Minimal ADB and Fastboot). Both of these tools have their merits, but the second most important tool that has the same function, namely to have ADB and Fastboot.
1. With 15 Seconds ADB installer
For Windows Operating System, there are two tools that are made in this post, the first (15 Seconds ADB Installer) and the second with (Minimal ADB and Fastboot). Both of these tools have their merits, but the second most important tool that has the same function, namely to have ADB and Fastboot.
1. With 15 Seconds ADB installer
Features 15 seconds ADB installer
- Small: - 9.18 MB
- Fast: - 15 seconds install (many times its even less)
- AIO: - ADB, Fastboot and also Drivers
- Easy to install: - just run it and program will guide you
- Clean: - ADB and Google Drivers from latest SDK
How To Install 15 ADB Installer
- Download and execute file 15 seconds ADB installer on your windows computer. Run it (Require administrator privileges)
- Press Y/Yes to install ADB and Fastboot or N/No to skip
- Press Y/Yes to install ADB system-wide or N/No for current user only
- Press Y/Yes to install Drivers or N/No to skip
- Continue Driver installation
- 15 SECONDS Passed - finished!
- Open your Command Prompt, and type adb version for checking
2. With Minimal ADB anda Fastboot
What is Minimal ADB and Fastboot?
Minimal ADB and Fastboot Tool is a small utility created by shimp208 (xda developer) that allows you to install the latest version of adb and fastboot files on your computer without the need of installing the entire android sdk package.
Features of Minimal ADB and Fastboot Tool
- Lightweight: The total installation of Minimal ADB and Fastboot tool is around 2 mb only (where as android sdk package takes more than 500 mb).
- Installer: You dont have to setup the minimal adb and fastboot tool manually, simply run the setup and it will install the files in C:\Program Files\Minimal ADB and Fastboot folder).
- Quick Installation: As minimal adb and fastboot installation package is hardly of 2 mb, so it takes few seconds to install on the computer
How to Install Minimal ADB and Fastboot
- Download Minimal ADB and Fastboot tool
- Install by double clicking on the file Minimal ADB and Fastboot
- Going out the window as shown below, click Next to continue
- Click on the "I accept the agreement" and click Next
- In this section, you can specify the folder where the installer is located, click Next only
- Click Next to create a Minimal ADB and Fastboot is also located in the Start Menu Click
- Next if you want to create an icon Minimal ADB and Fastboot is located on the Desktop
- If everything is according to what you want, click Install
- Finally, click Finish
- After that you can open minimal ADB and Fastboot via the icon on the Desktop or in the Start Menu, also via the right click on the folder Instaler in Program Files
How to Install ADB and Fastboot for Mac
- Download ADB and Fastboot tool for Mac OS X
- Or you can also get it by typing this command into your terminal (/Applications/Utilities/Terminal.app)
git clone https://github.com/koddsson/adb-fastboot-install.git
- Extract the file and Run ADB-Install-Mac.sh from Terminal (/Applications/Utilities/Terminal.app) and then restart Terminal. If you wish to uninstall, simply run Uninstall-ADB.sh ADB and Fastboot will be moved to /usr/bin/
How to Install ADB and Fastboot for Linux
- Download ADB and Fastboot tool for Linux
- Or you can also get it by typing this command into your linux terminal
git clone https://github.com/koddsson/adb-fastboot-install.git
- Extract and Run ADB-Install-Linux.sh from your command line application. Then restart your command line application. If you wish to install, simply run Uninstall-ADB.sh
• ADB and Fastboot will be moved to /usr/bin
• 51-android.rules will be moved /etc/udev/rules.d/
• The Java JDK will be installed.
Or you can also install it by entering this command into your linux terminal
Command
On Mac OS X (and some Linux distros) you can drag and drop your install file into your terminal windows and press return (or enter) and the script will run.
You also may execute the command:
/path/to/install/script/ADB-Install-<OS>.sh
The second way to install ADB and Fastboot on Mac OS X and Linux
Not only the above can be done to install ADB and Fastboot on Mac OS X and Linux, there sat again under way to install ADB and Fastboot on Mac OS X and Linux, using Nexus-Tools.
Nexus Tools is an installer for the Android debug/development command-line tools ADB (Android Device Bridge) and Fastboot for Mac OS X and Linux. The script does not need to be downloaded, simply copy and paste this command into the terminal and run it to install ADB/Fastboot:
bash <(curl -s https://raw.githubusercontent.com/corbindavenport/nexus-tools/master/install.sh)
and this command to un-install ADB/Fastboot:
bash <(curl -s https://raw.githubusercontent.com/corbindavenport/nexus-tools/master/uninstall.sh)
These commands will download the selected script and run it. The script will download the files it needs during runtime, so it requires an internet connection. The script works on both Mac OS X and Linux (as long as the curl package is installed).
Nexus Tools requires sudo privileges to install/uninstall the adb and fastboot tools to /usr/local/bin, so they can be run without typing the full directory.
ADB and Fastboot commands
If the ADB and Fastboot already installed on your computer, now you can do a variety of things dealing with your android device, ranging from Unlock Boot Loader, install Custom Recovery and others, all it can do to learn the commands ADB and Fastboot below :
Commands | Use |
Basic ADB Commands | |
adb devices | Shows a list of devices attached to the computer. |
adb reboot | Reboots a device connected to the PC. |
adb reboot recovery | Reboots a device into recovery mode. |
adb reboot download | Reboots the connected device into download mode. E.G Download mode on Samsung Galaxy devices. |
adb reboot bootloader | Reboots a device into Bootloader. Once in Bootloader, you can make further selections here. |
adb reboot fastboot | Reboots a connected device into Fastboot mode. |
Installing / Uninstalling / Updating Apps with ADB. | |
adb install <ApplicationpathPackagename>.apk | ADB install let’s you install APK files directly to your phone. To use this command type adb install application path, as shown in the commands part and hit enter key and it will start installing the app on your phone. e.g adb install C:/Users/UsamaM/Desktop/CandyCrushSaga.apk. If process succeeds it will show you “Success” in the command window. |
adb install -r <AplicationpathPackagename>.apk | If you have already installed an app, and you just want to update it then this command will let you do so. e.g adb install -r C:/Users/UsamaM/Desktop/CandyCrushSaga.apk |
adb unistall package_name e.g adb uninstall com.android.chrome | Uninstalls and application from your device. The easiest way to find a package name is, install Package Name Viewer from the play store and find the name of the package under the App Name. If process succeeds it will show you “Success” in the command window. |
adb uninstall -K package_name e.g adb uninstall -K com.android.chrome | Uninstall an app but keeps it’s data and cache directories. If process succeeds it will show you “Success” in the command window. |
Push and Pull files | |
adb rootadb push >e.gadb push c:\users\UsamaM\desktop\Song.mp3 \system\media adb push filepathonPC/filename.extension path.on.phone.toplace.the.file | the adb push commands let’s you transfer any files to your phone from your PC. You simply need to provide the path of file on your PC and path where to place this file on your phone. |
adb rootadb pull>e.gadb pull \system\media\Song.mp C:\users\UsamaM\desktop adb pull [Path of file on phone] [Path on PC where to place the file] | Similar to the adb push command. Using adb pull, you can simply pull any files from your phone. |
Backing up system and installed apps. Before doing this, in your adb folder create a folder Backup and under the backup folder create two folders named SystemApps and InstalledApps. These folders are necessary as you’ll be pushing the backed up apps to these folders. | |
adb pull /system/app backup/systemapps | backs up all the system apps of your phone to the Systemapps folder that you created in the ADB folder. |
adb pull /system/app backup/installedapps | backs up all the installed apps of your phone to the installedapps folder that you created in the ADB folder. |
Background Terminal | |
adb shell | starts the background terminal. |
exit | exits the background terminal. |
adb shell <command you want>e.g adb shell su | switches to the root of your phone. Please make sure that you’re rooted in case you wish to use adb shell su. |
Fastboot commands To flash files using fastboot, place the desired files in Fastboot folder or Platform-tools folder that you obtained after installation of Android SDK tools. | |
Fastboot Flash File.zip | Flashes a .zip file to your phone, when your phone is connected in Fastboot mode. |
Fastboot Flash recovery recoveryname.img | Flashes a recovery to your phone when it’s connected in Fastboot mode. |
Fastboot flash boot bootname.img | Flashes a boot or kernel image when your phone is connected in Fastboot mode. |
Fastboot getvar cid | shows you the CID of your phone. |
Fastboot oem writeCID xxxxx | writes the super CID. |
fastboot erase system fastboot erase data fastboot erase cache | In case you want to restore a nandroid backup, you’ll have to delete the current system/data/cache of your phone first. Before doing this, it is always recommended to have backed up your system using a custom recovery>backup option and copy the backed up .img files to Fastboot or Platform-tools folder in Android SDK folder. Then performing these commands will erase everything. |
fastboot flash system system.img fastboot flash data data.img fastboot flash cache cache.img | These commands will restore the backup that you made using a custom recovery on your phone and placed in the Fastboot folder under Android SDK tools. |
fastboot oem get_identifier_token fastboot oem flash Unlock_code.bin fastboot oem lock | These commands help you to get the identifier token of your phone that can be used for unlocking the bootloader. The second command helps your to flash the bootloader unlock code, and the 3rd commands helps you to lock your phone’s bootloader once again if locking it is actually allowed. |
Logcat | |
adb logcat | Shows you the real time logs of your phone, these logs represent the ongoing process on your device.It is recommended that you run this command while your device boots up to check what’s going on. |
adb logcat > logcat.txt | Creates a .txt file containing the logs in the Platform-tools folder or Fastboot folder in Android SDK tools directory. |
Source:
http://www.kingoapp.com/help/fastboot-mode.htm http://developer.android.com/tools/help/adb.html
http://androidxda.com/download-minimal-adb-and-fastboot-tool
http://forum.xda-developers.com/showthread.php?t=2317790
http://techbeasts.com/2014/01/05/useful-adb-and-fastboot-commands-and-how-to-them/
Belum ada Komentar untuk "Introduction and Install ADB and Fastboot (Windows, Mac OS X, Linux)"
Posting Komentar
We hope you can leave comments about this post, so that it will be an evaluation material for us to make a better article for the future.
Report if there is an inactive link by commenting, we will immediately make improvements to the link.