Android General Shell Daquan

Source: Internet
Author: User

First, "What is the shell"

The shell of the Linux system is the shell of the operating system, providing the user with an interface to use the operating system. It is the general designation of command Language, command interpreter and programming language. The shell is the interface between the user and the Linux kernel, and if you think of the Linux kernel as the center of a sphere, the shell is around the outer layer of the kernel. When a command is passed to Linux from a shell or other program, the kernel responds accordingly. The shell is a command language interpreter with its own built-in shell command set, and the shell can be called by other applications in the system. Commands entered by the user at the prompt are interpreted by the shell before being passed to the Linux kernel. Some commands, such as changing the Working Directory command CD, are included inside the shell. There are also commands, such as the Copy command CP and the move command RM, which are separate programs that exist in a directory on the file system. For users, there is no need to care whether a command is built inside the shell or a separate program.

Ii. "Preparatory work"

Step 1: Install the USB driver to download and install the HTC full driver (http://shuajidown3.lexun.cn/articile/2013/7/3/ Htcdriver3.0.0.021.exe) phone into settings-application-Develop-USB debug, tick the first option. Then connect the computer via USB cable and prompt to install the driver. Step 2: Software preparation 1, the ADB tool http://shuajidown3.lexun.cn/articile/2013/7/3/adb tool. rar

Unzip it into the root directory of your computer's system disk

2, run, enter CMD to enter the command prompt. The following commands are at the command prompt. Start (click to enter CMD in the input box)

3, enter the CD c:\adb return, enter the ADB directory

Now it's time to do the command.    third, "common adb shell command"    1. Display all Android platforms in the system:Android list targets    2. Display all AVD (simulator) in the system:Android List AVD    3. Create an AVD (simulator):Android Create AVD--name name--target platform number    4. Start the emulator:EMULATOR-AVD name-sdcard ~/name. IMG (-skin 1280x800)    5. Delete the AVD (simulator):Android Delete AVD--name name    6. Create SDcard:Mksdcard 1024M ~/name. img    7. AVD (simulator) Location:Linux (~/.ANDROID/AVD) Windows (C:\Documents and SETTINGS\ADMINISTRATOR\.ANDROID\AVD)    8. Start Ddms:Ddms    9. Show all currently running emulators: ADB devices    10. Execute a command on a simulator:Abd-s Simulator number Command    11. Install the application:ADB install-r application. apk    12. Get the files in the emulator:ADB pull <remote> <local>    13. Write the file to the emulator:ADB push <local> <remote>    14. Enter the shell mode of the simulator:ADB shell    15. Launch the SDK, documentation, instance download Manager:Android    16. Uninstall APK Package:ADB shell CD Data/app RM apk package exit ADB Uninstall APK package main package name ADB install-r APK Package    17. View the ADB command Help information:ADB Help    18. View the log information on the command line:ADB logcat-s label Signature    the commands behind the ADB shell come mainly from:SOURCE \system\core\toolbox directory and source code \FRAMEWORKS\BASE\CMDS directory.    20. Remove the System application:ADB remount (re-mount the system partition so that the system partition is re-writable). ADB shell CD System/app RM *.apk    21. Get Administrator Privileges: adb root    22. Start activity:ADB shell am START-N package Name/package name + class name (-N class name,-a action,-d date,-m mime-type,-c category,-e Extended data, etc.).    23. Release Port:You can set any port number as the request port for the host to the emulator or device. such as: adb forward tcp:5555 tcp:8000    24. Copy files:You can copy files to or from a device, copy a file or directory to a device or emulator: ADB push <source> &LT;DESTINATION&GT;&LT;/DESTINATION&GT;&LT;/SOURCE&G    T For example: ADB push test.txt/tmp/test.txt Copying a file or directory from a device or emulator: ADB pull <source> <destination></destination> </source> such as: ADB pull/addroid/lib/libwebcore.so    25, the search simulator/device instance:Gets a list of instances of the currently running emulator/device and the status of each instance: ADB devices    26. Check the bug report:ADB bugreport    27. Record the wireless communication log:In general, the number of wireless communication logs is very much, at run time do not need to record, but we can still through the command, set records: ADB shell Logcat-b Radio28. Get the ID and serial number of the device:ADB get-product adb Get-serialno    29. Accessing the database SQLite3adb shell sqlite3 #cd system/sd/data//Enter the specified folder in the system #ls//list displays the contents of the current folder #rm-R xxx//delete the folder with the name xxx and all the files inside #rm XXX//delete files xxx #rmdir xxx//delete xxx folder

Android General Shell Daquan

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.