Database Reference
In-Depth Information
Mobile Client
The Android platform was chosen for the sample, so you need to install
the developer tools for building Android applications. The current Android
Development Kit is a tool chain that integrates with the Eclipse IDE. A
version is also available for IntelliJ, referred to as Android Studio, which
is available as an early access preview at this time. For the sample in this
book we have supplied an Eclipse project that you can import to build
the code and experiment with the application. If you do not already have
Eclipse installed, first you need to download and install the IDE from
http://www.eclipse.org . You can download and install the
development kit from http://developer.android.com/sdk/ .
Detailed installation instructions are available on the site, which we will not
bother reproducing here. The sample application targets version 17 of the
Android runtime.
1. Start Eclipse and select Windows Android SDK Manager and ensure
that version 17 of the SDK is installed. It is fine if more than one SDK
version is installed.
2. After you have the SDK installed, create a new Eclipse project that
imports the sample application code. The recommended practice for
Android projects is to include the Eclipse project settings in your source
code (and revision control system), so it is included in the download for
this chapter. After unpacking the download for the chapter, you can find
the source code for the mobile client under ch08/sensors/client .
3. To create the project in Eclipse, select File Import Android/
Existing Android Code into Workspace. In the dialog that appears, set
the root directory to the full path to the client source directory, and
ensure that both Copy Projects into Workspace and Add Project to
Working Sets are unchecked.
4. Clicking Finish creates a project called SensorsClient in your Eclipse
workspace. The project defaults to building automatically. You can
disable automatic building and instead select the project and then use
Project Build Project explicitly. If everything is set up correctly, the
project should build without any errors.
Search WWH ::




Custom Search