Leaderboard1

Leaderboard2

Get Started Developing for Android with Eclipse


Why Develop for Android?

Android is an open-source platform based on the Linux kernel, and is installed onthousands of devices from a wide range of manufacturers. Android exposes your application to all sorts of hardware that you’ll find in modern mobile devices — digital compasses, video cameras, GPS, orientation sensors, and more.
Android’s free development tools make it possible for you to start writing software at little or no cost. When you’re ready to show off your application to the world, you can publish it to Google’s Android Market. Publishing to Android Market incurs a one-off registration fee (US $25 at the time of writing) and, unlike Apple’s App Store which famously reviews each submission, makes your application available for customers to download and buy after a quick review process — unless the application is blatantly illegal.
Here are a few other advantages Android offers you as a developer:
  • The Android SDK is available for Windows, Mac and Linux, so you don’t need to pay for new hardware to start writing applications.
  • An SDK built on Java. If you’re familiar with the Java programming language, you’re already halfway there.
  • By distributing your application on Android Market, it’s available to hundreds of thousands of users instantly. You’re not just limited to one store, because there are alternatives, too. For instance, you can release your application on your own blog. Amazon have recently been rumoured to be preparing their own Android app store also.
  • As well as the technical SDK documentation, new resources are being published for Android developers as the platform gains popularity among both users and developers.
Enough with the talk — let’s get started developing for Android!

Installing Eclipse and the Android SDK

The recommended environment for developing Android applications is Eclipse with the Android Development Toolkit (ADT) plugin installed. I’ll summarize the process here. If you need more detail, Google’s own developer pages do a good job of explaining the installation and configuration process.
  • Download the Android SDK for your platform (Windows, Mac OS X, or Linux).
  • Extract the downloaded file to somewhere memorable on your hard drive (on Linux, I use /opt/local/).
  • If you don’t already have Eclipse installed, download and install the Eclipse IDE for Java Developers package. For programming, Google recommends using Eclipse 3.5 (Galileo).
  • Run Eclipse and choose Help->Install New Software.
  • Click Add in the Available Software window.
  • Enter Android Development Tools in the Name field, and https://dl-ssl.google.com/android/eclipse/ in the Location field.
  • Click OK and check Developer Tools in the list of available software. This will install the Android Development Tools and DDMS, Android’s debugging tool.
  • Screensot
    • Click Next and Finish to install the plugin. You’ll need to restart Eclipse once everything is installed.
    • When Eclipse restarts, choose Window->Preferences and you should see Androidlisted in the categories.
    • You now need to tell Eclipse where you’ve installed the Android SDK. Click Androidand then Browse to select the location where you extracted the SDK files. For example, /opt/local/android-sdk.
      Configuring ADT
      Large view
    • Click OK to have Eclipse save the location of your SDK.

No comments:

Post a Comment