Getting Started on Android Projects

The following steps will walk you through how to get started using Android Studio for development.

 

Install JDK 1.7

You can download JDK from Oracle's JDK web site. You can watch the video below to follow along.

 

 

TIP: Ensure JAVA_HOME environment variable is set correctly. You can verify by starting a new command prompt and typing set JAVA_HOME - It should display the path where you i nstalled Java SDK.  

 

 

Download Android Studio

 


 

 

  1.  You can download the latest version of Android Studio and Android SDK from android sdk web site. You can watch the video below to follow along.

TIP: Add a new environment variable ANDROID_HOME and set its value to the sdk-path. For example: If you installed Android SDK in c:\AndroidSDK, set the value of ANDROID_HOME variable to c:\AndroidSDK. 

TIP: Add sdk-path\tools and sdk-path\platform-tools to your PATH variable. For example: If you installed Android SDK in c:\AndroidSDK, add c:\AndroidSDK\tools;c:\AndroidSDK\platform-tools to your PATH. 

TIP: Confirm adb.exe is in your path before proceeding further. Start a new command window, type adb version. You should see output such as: Android Debug Bridge version 1.0.32 (the exact version number might vary).

 

Configure Emulator or Phone Device

You need to configure an emulator or an actual phone device to run/test your apps. If you've a personal android phone, you can use it for this purpose. If you do not have access to a device, you can configure an android emulator on your laptop to run the apps.

Follow the steps to configure your device or emulator based on your situation.

Configure Device

Follow the steps given here and here to enable your device for USB debugging.

Configure Emulator in Android Studio

 Follow the steps given here to create/configure an emulator in Android studio

For most of the exercises, the nexus S API 22 AVD image (shown below) works well, so we recommend using that image for your emulator.

Using Genymotion Android Emulator

Genymotion android emulator can be more performant. If you have issues with the android studio emulators, you can try the Genymotion emulator.

You can download the GenyMotion emulator from GenyMotion web site.

 

You can watch the video below for steps on configuring it.

 

 Build and Run a Simple App

Confirm you have every thing installed correctly by creating a simple app and running it on your device/emulator.

Follow the steps here to try out a simple android app. You can also watch the video below to follow along.

 

Now, you are ready to work on the android projects in the course.