Upload
others
View
1
Download
0
Embed Size (px)
Citation preview
1
USC-Namseoul Summer Certificate Program
Laboratory Manual for Day 1
“Android Installation Guide”
1. JDK Installation
Download JDK 6 Update 19 (newest version should also be fine.) from the following link: http://www.oracle.com/technetwork/java/javase/downloads/index.html. Once you are on the site you will find the following Java downloads:
To start downloading the JDK platform just click on it, this action will take you to the following page:
2
Accept the license agreement to be able to select the JDK
Now you should be able to select the appropriate JDK for your computer
If you have Windows 32 bits operative system select Windows x86 If you have Windows 64 bits operative system select Windows x64
Look for the appropriate one.
Once you have clicked on the one you chose the download should start automatically and when
the download is finished double click on the JDK icon to install it.
3
When the program is installed go to the bin folder which should be located in: C:\Program Files\Java\jdk1.6.0_26\bin
Copy the path of this folder:
This path will be pasted as a system variable. The first thing you have to do is open computer properties.
Next, open Advanced system settings
This will take you to the following window, click on the Environment Variables button.
4
Now you should have the following window open: Note that we are finally in the System variables section.
In the system variables section double click on Path option.
5
Now you will be able to create a new system variable, be careful in this part, you do not want to delete the highlighted path.
Click at the end of the highlighted path in order to have a blinking cursor.
Write a semicolon and paste the path of the Java bin folder (the one you copied earlier)
Once you finish press ok and that’s all with the installation of the JDK.
2. Android SDK Installation
• Follow this link: http://developer.android.com/sdk/index.html to download the SDK. In the web page you can download different Installation packages, download the android-sdk_r12-windows.zip package.
6
When the download has finished you will have a .zip android package.
You will have to uncompress this folder in a specific location in your computer, it is recommended
to do so in the C:\ drive.
After you have uncompressed the folder, double click the folder and double click the SDK manager icon.
The SDK Manager will open the installation wizard and the next step is to install the default android packages (This will take some time).
7
Once you have installed the android packages you have to add a new System Variable the same way you added the JDK variable.
Go to the location of the android folder and open it, look for the tools folder and also open it.
Copy the path of the tools folder and add it as a system variable just as you did it for the bin folder
of the JDK.
New variable:
Press ok and that’s all with the installation of the ADK
3. Eclipse Installation
Now you have to download “Eclipse IDE for Java Developers” from the following link: http://www.eclipse.org/downloads/.
8
If you have Windows 32 bits operative system select Windows 32 Bit If you have Windows 64 bits operative system select Windows 64 Bit
Once you have selected the one that fits your computer characteristics you will be able to download the Eclipse IDE, click on the Green arrow to start downloading.
When the download is finished you will have a .zip Folder
You have to uncompress this folder in a specific location in your computer for example a C:\ drive.
9
Open the eclipse Folder and then double click on the eclipse icon.
A new window will open and it will show you a message, click on the ok button to continue.
4. Install Android Development Tools
10
For the android development tools, open eclipse and go to: HelpInstall New Software.
Add https://dl-ssl.google.com/android/eclipse/ as URL
Now you will see “Android Development Tools” as the available software. Select and install this package by clicking on the Next button.
When the installation has finished the wizard will ask you to restart eclipse, go ahead and let it restart eclipse.
11
If the installation was successful, in the window tab you will see “Android SDK and AVD Manager”.
Now go to WindowPreferences.
Click on the android tab.
Now click on Browse and find where did you put the SDK folder, then click it and press OK and
then press Apply.
12
Press Ok and now you have finished the installation of the ADT.
5. Motorola USB driver
If your computer cannot find the phone after you plugged the USB cable, then your operation system needs to install the USB driver so it can recognize the device. The drivers provided here are for windows. If you are using any other OS, you need to look for the proper driver to install. For 32‐bit Windows click on this link: http://infolab.usc.edu/projects/GeoTrust/download/Handset_USB_Driver_32_v4.2.4.msi For 64‐bit windows click on this link: http://infolab.usc.edu/projects/GeoTrust/download/Handset_USB_Driver_x64_v4.2.4.msi
By clicking on the link you will download the drivers, now you can install the proper driver by simply clicking and following the wizard.
6. Creating an Android Virtual Device (AVD)
To create an AVD Click on the Android SDK and AVD Manager:
Click the virtual devices button and then click on the “New...” button:
The following window will appear:
13
Enter the following Name: Android-2.#-Emulator Target: Android 2.# Then click on Create AVD. If you wish to test your program on your device, you don’t need to create an emulator device.
7. Phone Registration
Each phone needs a Google account. Most phone accounts have been set up properly. If not, please set it up according to the following rules. Each group needs to create a Google account with the following format. First name: infolab Last name: USC Account: [email protected] Password: infolabXX XX stands for the 2 digit number assigned to your phone. Secondary email: [email protected]
8. HelloWorld, your first Android App
14
After you’ve finished the installation, please follow this link to do a helloworld android application. http://developer.android.com/resources/tutorials/hello-world.html 9. Reading list
http://developer.android.com/guide/basics/what-is-android.html Application fundamentals http://developer.android.com/guide/topics/fundamentals.html Basic programming components http://developer.android.com/guide/topics/fundamentals/activities.html User interface http://developer.android.com/guide/topics/ui/index.html Application resources http://developer.android.com/guide/topics/resources/index.html