Android - Installation of Android
Installation of Android
This tutorial shows you how to download and install Android SDK to get you started developing Android applications.
The objective of this android tutorial would be
a) Install the Android SDK on Windows and configure with eclipse
b) Create an Application that Runs on the Android Emulator
1.Install Java (if it is not on your machine)
Now save file and install the jdk.
2. Install Eclipse
Eclipse is a professional editor.
Go to http://www.eclipse.org/downloads/ . Click on Windows 32 Bit from the right side download icon of Eclipse IDE for Java Developers row.
After it has finished downloading, you will have this file in your directory. Unzip this file.
Now you find the eclipse.exe file from your unzip folder directory and double-click on the file eclipse.exe to run Eclipse editor. You will see this.
Click ok.
2.1. Install the ADT Plug-in
- · Start Eclipse, then select Help > Software Updates or Help>Install New Software…. In the dialog that appears, click the Available Software/Install New Software tab.
- · Click Add Site.
- · In the Add Site dialog that appears,
Copy and paste this link into input box “Location/Work with”: https://dl-ssl.google.com/android/eclipse/
Back in the Available Software view, you should see the plugin. “Android Developer Tools”, and “Android Editors” should both be checked. The Android Editors feature is optional, but recommended. Then click on the button “Install …”
Click on the button next
Check the “I accept the terms of the license agreements” and click Finish.
Eclipse will ask to restart, click on the button Yes.
After restart, update your Eclipse preferences to point to the SDK directory:
If you want to know more then go to http://developer.android.com/sdk/eclipse-adt.html and read the content Downloading the ADT Plugin
2.2. Android SDK
Download the Android SDK from the Android homepage under Android SDK download . The download contains a zip file which you can extract to any place in your file system, e.g. I placed it under “c:\android” .
2.3. Configuration
In Eclipse open the Preferences dialog via Windows -> Preferences. Select Android and maintain the installation path of the Android SDK. Click Apply, then OK.
Now, set your PATH environment variable by right click on My Computer, and select Properties. Under the Advanced tab, hit the Environment Variables button, and in the dialog that comes up, double-click on Path under System Variables. Add the full path to the
tools/
directory to the path, in this case, it is: ;C:\android\android-sdk-windows\tools. Then click OK , OK , OK.
2.4.Create an AVD
In this tutorial, you will run your application in the Android Emulator. Before you can launch the emulator, you must create an Android Virtual Device (AVD). An AVD defines the system image and device settings used by the emulator.
To create an AVD:
In Eclipse, choose Window > Android SDK and AVD Manager.
2.3. Configuration
In Eclipse open the Preferences dialog via Windows -> Preferences. Select Android and maintain the installation path of the Android SDK. Click Apply, then OK.
Now, set your PATH environment variable by right click on My Computer, and select Properties. Under the Advanced tab, hit the Environment Variables button, and in the dialog that comes up, double-click on Path under System Variables. Add the full path to the
tools/
directory to the path, in this case, it is: ;C:\android\android-sdk-windows\tools. Then click OK , OK , OK.
2.4.Create an AVD
In this tutorial, you will run your application in the Android Emulator. Before you can launch the emulator, you must create an Android Virtual Device (AVD). An AVD defines the system image and device settings used by the emulator.
To create an AVD:
- Select Virtual Devices in the left panel.
- Click New.
The Create New AVD dialog appears.
3. Type the name of the AVD, such as “testAVD”.
4. Choose a target. The target is the platform (that is, the version of the Android SDK, such as 2.2) you want to run on the emulator.
5. Click Create AVD. Your new AVD is created now!
Create a New Android Project
After you’ve created an AVD, the next step is to start a new Android project in Eclipse.
2. Fill in the project details with the following values:
- Project name: HelloAndroid
- Application name: Hello, Android
- Package name: com.droidbd.helloandroid (or your own private namespace)
4. Create Activity: HelloAndroid
5. Min SDK version : 8 (as per API level)
Click Finish.
Run the Application
The Eclipse plug-in makes it easy to run your applications:
- Select Run > Run.
Or Right click on project from project explorer and go
Run as ->Android Application
Yeah, you will see a black screen at your AVD with Your application name and a “Hello …..” text.
Comments
Post a Comment