wiki:2012/Projects/ASL/Tutorial1

Version 6 (modified by xianyi, 5 years ago) (diff)

--

Tutorial 1: A Simple Use of the Library

Prerequisites

Required Downloads

Before beginning and using this tutorial, you will need the following fundamental tools:

Follow all necessary instructions on those respective websites as to how to install each tool individually.

And of course, you will need:

Required Code

Any use of the library will require that the following permissions are set in the AndroidManifest.xml file:

    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
    <uses-permission android:name="android.permission.READ_PHONE_STATE" />
    <uses-permission android:name="android.permission.INTERNET" />
    <uses-permission android:name="android.permission.BLUETOOTH" />
    <uses-permission android:name="android.permission.BLUETOOTH_ADMIN" />
    <uses-permission android:name="android.permission.RECORD_AUDIO" />
    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
    <uses-permission android:name="android.permission.ACCESS_LOCATION_EXTRA_COMMANDS" />

And the following services need to be placed under the <application> header in AndroidManifest.xml:

        <service
            android:name="winlab.file.RunningService"
            android:enabled="true" />
        <service
            android:name="winlab.sql.Sensors_SQLite_Service"
            android:enabled="true" />
        <service
            android:name="winlab.sensoradventure.gps.GPSloggerservice"
            android:enabled="true" />


Using the Library

Start off by opening Eclipse and creating a new Android project.

Attachments (16)

Download all attachments as: .zip