ADB (Android Debug Bridge)
Located under the Plaform-tools subdirectory of the Android SDK installation directory. You can complete the file copy between the PC and the phone, apk install and uninstall, and even can switch directly to the Android system to execute the Linux command.
1. View the currently running emulator
ADB devices
2, the computer and the phone to copy each other files
Computer → Mobile phone
ADB push PC file path phone file directory, for example: ADB push d:/abc.txt/sdcard/
Mobile → Computer
ADB pull Mobile file path computer file directory, for example: ADB pull/sdcard/asd.txt e:/
3. Start the shell window of the simulator
Startup: adb shell
Exit: Exit
4. Install and uninstall APK
An Android app packaged as a release APK package requires the following 3 steps:
1.*.class----------------------DX Tools---------------→*.dex File
2. resource file--------------------aapt tool------------→*.ap_ file
3. (*.dex file, *.ap_ file)-----Apkbuilder tool------→APK Package
Installation: adb install APK file path
Uninstall: adb uninstall [-K] <package>
PACKAGE--APK package,-k--only deletes applications, preserves data and caches files.
5, Mksdcard can manage SD card
Mksdcard [-l label] <size> <file>
<size>--Specify the virtual SD card size, <file>--Save the file image of the virtual SD card. For example:
Mksdcard 64m D:\avds\.android\avd\sdcard.img Create a 64m virtual SD card with the corresponding mirrored virtual file as D:\avds\.android\avd\sdcard.img.
Add the-sdcard <file> option when the emulator starts.
01_android Application development environment _04_android usage of common development tools