martedì 6 marzo 2012

Adk and Sdk installation reference and first adb steps







SDK DOWNLOAD AND INSTALLATION
http://developer.android.com/sdk/index.html


ADT PLUGIN FOR ECLIPSE
http://developer.android.com/sdk/eclipse-adt.html 


After a correct installation of these tools, we should define a system variable as 

D:\> set %ANDROID_HOME%=D:\OUR_SDK_INSTALLATION_DIR

and updating the path system variable as

D:\> path=%path%;%ANDROID_HOME%\platform-tools

[this is the location of the adb command that is the Android Device Bridge]

in that way everywhere you are in your filesystem using console, allows us to do something like shown in this picture.






 The next step is tring to find out the connected devices with

D:\> adb devices
List of devices attached
emulator-5554   device


That's done ! We can see our emulator for instance, launched from our eclipse ide.

This is the basic step to access to the device doing

D:\>adb shell

and if the system answer with a confortable and nice 


then here we are ! Inside our emulator's linux shell.
Let's have a look at the filesystem directory list
 

# ls
ls
config
cache
sdcard
acct
mnt
vendor
d
etc
ueventd.rc
ueventd.goldfish.rc
system
sys
sbin
proc
init.rc
init.goldfish.rc
init
default.prop
data
root
dev
#

   
Deploing apk packages with the Adk plugin for eclipse it's very easy, but essentially do what we can easily do using command line.
For instance

D:\> adb install pippo.apk 

install the apk package of an application under the selected device, naturally we have to enable the Settings >> Applications >> Unknown sources to install an extra market application


An extra step will be the security management using key pair to sign the package.

i.e. keytool -genkey -alias duke -keypass dukekeypasswd
 

Nessun commento:

Posta un commento