Scripting Internal Debugging and Shell CMD For Android
Scripting Internal Debugging and Shell CMD For Android
ADB Command
Scripting commands
Wait for the device to be in the specified state.
state : Values can be device , recovery , sideload , or bootloader .
transport : Values can be usb , local , or any .
adb wait-for [-transport] -state
Print the adb state of a device. The adb state can be print offline , bootloader ,
or device .
adb get-state
Side load (install in APK format) the specified full OTA package onto the device.
adb sideload otapackage
Shell commands
Start a remote interactive shell in the target device.
adb shell
Issue a shell command in the target device and then exit the remote shell. Use any
combination of the following options:
-e : Specify an escape character or the value none if you do not want to use
an escape character. If you do not provide a value, the default escape character (a
dash ( - )), is used.
-n : Do not read from stdin .
-T : Disable pseudo-terminal utiity (PTY) allocation.
-t : Force PTY allocation.
-x : Disable remote exit codes and stdout/stderr separation.
adb shell -e escape_char [-n] [-T] [-t] [-x] [command]