"Reprint" APK package installation in Android and use of the ADB command

Source: Internet
Author: User

APK Package Installation steps:

1, first will be. /android-sdk/platform/tools Add both path path

2. In the console window, go to the directory where your APK package resides

3, Input: Abd Unremount, the first time you use this command, you need to get the operation permission of the command

4. Open Android Emulator

5, execute in console: adb install package name. apk

6, if the display success, so long install APK package successfully, display failure, the installation fails.

7, check the error, troubleshooting, and then execute the following command: Abd install-r package name. apk

8, if the installation is successful, you can execute your application in the emulator

ABD's related commands:

Installing the Software
ADB install APK file name. apk
Reinstall the SOFTWARE
ADB install-r apk file name. apk

Uninstall APK software
ADB uninstall APK package name. apk

Check the run log on your phone, which can be used to check for errors
ADB logcat

See if your phone is connected, and how many phones are connected
ADB devices

A is the phone path, B is the computer path, meaning: Copy the file from the phone to the computer
ADB pull <A> <B>
A is the phone path, B is the computer path, meaning: Copy the file from the computer to the phone
ADB push <B> <A>

Command Line window specifies the device method via ADB connection when multiple devices are onlineCategory: Android2012-01-07 18:07 12920 People read Comments (5) favorite reports CMD database SHELLC

1. Obtain serial number for all online devices through the ADB devices command.

C:\USERS\ADMINISTRATOR>ADB devices

List of devices attached
emulator-5554 Device
sh0a6pl00243 Device

The above indicates that there are currently two devices online, the first emulator-5554 is the simulator, and the latter is the real chance sh0a6pl00243.


2. Send the ADB command to the device via Adb-s <serial number> cmd.

For example: Run the command shell.

C:\users\administrator>adb-s sh0a6pl00243 Shell
#

For example: down an application's database to the local f:\test directory.

C:\users\administrator>adb-s sh0a6pl00243 Pull Data/data/com.android.tencent/databases/agendadetails.db f:\test
555 kb/s (5120 bytes in 0.009s)

C:\users\administrator>
Running other commands is the same as running the pull command, except that you need to add the-s <serial number> between ADB and CMD.

Access to the phone's HyperTerminal terminal
ADB shell

Re-mount the file system
ADB remount

Restart your phone
ADB reboot
Reboot to Recovery interface
ADB reboot Recovery
Reboot to Bootloader interface
ADB reboot bootloader

Example: Retrieving the root and demotion method (partial operation) after swiping the official high version

Run the ADB environment
ADB shell

Set up Super User mode
Su

Mapping out Catalogs
Mount-o remount,rw-t Yaffs2/dev/block/mtdblock3/system

Exit Su
Exit

Exit Shell ready to accept next adb command
Exit

Add flash_image files to the phone
ADB push Flash_image.zip/system/bin/flash_image

Recovery first copy to card
ADB push Recovery-ra-heroc-v1.6.2.img/sdcard

Enter the ADB environment again
ADB shell

Modify file properties
chmod 0755/system/bin/flash_image

Rebooting the system
Reboot

"Reprint" APK package installation in Android and use of the ADB command

Related Article

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.