Android Development Environment Setup with free ebook


Here we will show you how to get started with set up of developmentenvironment for Android so you can start creatingandroid-devprojects.Google has put out both the Android SDK and the Android ADT in order to help developers integrate Android into their dev environment as well as facilitate more Android development.
Step 1: Install the JDK
Most of you probably have the Java JRE installed, but Android requires the JDK “Java Development Kit” to compile Java programs. The JDK is available on Oracle’s Java webpage. Install the version of the JDK appropriate for your OS; the Java EE 6 bundle is recommended, but you caninstall any bundle you like so long as it contains the JDK.
Linux users: many Linux distributions come with an open source variant of the JDK, like OpenJDK or IcedTea. While you may be tempted to use these in support of open-source or for whatever reason, for maximum compatibilityinstall the official Oracle JDK. You may choose to ignore this warning, but you may end up encountering obscure, strange errors because of it; if you do, most likely it’s some minor difference in the two JDKs.

Step 2: Install Your IDE of Choice
You can by all means code straight up in Emacs or Vi; if you prefer doing that, this article is not for you. For the rest of us, install a Java IDE; Eclipse is recommended, as it is the IDE that the Android developers use and the IDE with official plugin support from Google. The rest of this guide will assume Eclipse is the IDE you’re using, but NetBeans has Android plugin support for it as well.
When you download Eclipse, make sure to download Eclipse Classic or Eclipse for Java EE developers; there are quite a few flavors of Eclipse for download on their page, and you don’t want to end up with the C++ or PHP versions of Eclipse.
Step 3: Install the Android SDK
Now it’s time to install the Android SDK. You can grab it from the Android Developer website at:
http://developer.android.com/sdk/index.html
Download the installer for your particular operating system, and open it up when you’re done:
The Android SDK Manager is modular, meaning that you download the initial package and then download separatesdk-manager packages within the framework in order to provide more functionality. This lets the SDK be more flexible, as you don’t need to keep downloading entire packages every time a new version comes out; you can simply download the latest module and pop it into the SDK. You can pick and choose which modules to install, but if you’ve got the hard drive space I recommend installing all of the different flavors of Android; it will help later when debugging apps, especially on older Android OSes.
Step 4: Install the Android ADT for Eclipse
NOTE: if you’re using NetBeans, you want the nbandroid plugin, found here:
Now that the SDK is installed, you should install the Android ADT plugin. It’s not strictly necessary to do so, but the ADTadt-plugin offers powerful integration with many of the Android tools, including the SDK Manager, the AVD Manager, and DDMS, or dynamic debugging. All of these are extremely useful to have when creating an Android application, and if you want to skip them you should do so at your own peril!




To install the ADT, you’re going to have to add a custom software package to Eclipse. To do so, head over to the “Help”eclipse-install-software button on Eclipse’s menu and click the “Install New Software” button. Click “Available Software”, click “Add Remote Site”, and pop in this URL: https://dl-ssl.google.com/android/eclipse/




Step 5: Create an Android Virtual Device (or AVD)
Like the previous step, this step isn’t entirely necessary; you could do all your debugging and development work on ancreate sdk actual Android handset. Creating AVDs is a great way to see how your application might work across different operating systems and handset types, as AVDs can mimic not only different Android OSes but also different hardware; you can change such settings as heap size, display type, and maximum memory, making it useful to try and figure out where bugs are happening when you don’t own a multitude of different handsets to test on! To create an AVD, you can open the Android AVD manager from Eclipse from the “Window” button on the top bar, and go to “Virtual Devices”. From there, you can add, configure and delete them:
For those of you running a different IDE, the AVD Manager can be accessed in the same manner as the Android SDK is accessed outside of Eclipse; this is just a very easy shortcut for those with the Android ADT installed.

0 comments:

Post a Comment