Android ADB

Android ADB commands

Android ADB Commands can be a mysterious bunch, but they have saved me from some disasters and made my life easier overall so I figured I would write a small post today and list some useful commands, hopefully you may use in your android endeavors. First you need to have the actual binaries that let you use these commands. you can get minimal adb fastboot tools from this XDA topic (windows), or get the full android studio from here.

adb devicesShows a list of devices currently attached. example :

List of devices attached
FA43KWM04187 device

adb rebootReboots a device currently attached.
adb reboot recoveryReboots a device currently attached into recovery mode. This is usually a very minimal recovery mode for most OEM devices. You can install custom recoveries like TWRP or CWM etc that come with extra features.
adb reboot downloadReboots the connected device into download mode. This is different for most manufacturers. Download mode is for flashing radio firmware/ROM upgrade through official means.
adb reboot bootloaderReboots a device into Bootloader.The bootloader configures the device to an initial known state and has a means to select where to start executing the kernel. Bootloaders are written by hardware vendors and are specialized for the hardware they run on. In Android the bootloader typically starts either android OS itself or a Recovery. Android bootloaders often have a basic interactive mode that can be triggered by holding the “volume down” button while the bootloader is executing.
adb reboot fastbootReboot a connected device into Fastboot mode.
In Android, fastboot is a special diagnostic tool / state that you can boot your Android device into. While in fastboot, you can modify the file system partitions directly. It is an alternative to the recovery mode for doing installations and updates.
adb install camera.apkADB install let’s you install APK files directly to your phone. To use this command type adb install application, 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/sumguy/camera.apk.
If process succeeds it will show you “Success” in the command window. If you have already installed an app, and you just want to update it then you need to add the -r switch
adb install -r C:/Users/sumguy/camera.apk
adb uninstallUninstalls 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
adb uninstall -K an app but keeps it’s data and cache directories. If process succeeds it will show you “Success” in the command window.
adb pushthe 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 push file/path/on/connected/comp \path\on\phone
adb pullSimilar to the adb push command. Using adb pull, you can simply pull any files from your phone.
adb pull \path\on\phone file/path/on/connected/comp
adb shellstarts the background terminal.

that’s all the Android ADB Commands i can think of. Am I missing something? let me know in the comments!

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *