JSR-179 API exploitation and philosophy Francesca Bellanca Paolo Rodolà.

Slides:



Advertisements
Similar presentations
MIDP Mobile Information Device Profile Johnny Yau CIS 642 Prof. Insup Lee.
Advertisements

Handheld Wireless GPS Tracking Device Senior Design EEL 4914C : UWF, Fall 2006.
Real time vehicle tracking and driver behavior monitoring using a cellular handset based on accelerometry and GPS data Kevin Burke 4 th Electronic and.
Personal Navigation Phone Technical Presentation.
UNDERSTANDING JAVA APIS FOR MOBILE DEVICES v0.01.
Sensors. Point your phone at the sky, and Google Sky Map tells you which stars you’re looking at. Tilt your phone, and you can control the game you’re.
Tutorial 7: Using Advanced Functions and Conditional Formatting
© 2009 Research In Motion Limited Methods of application development for mobile devices.
Location Aware Devices  Location information can lead to creative applications  GPS hardware  cell tower positioning.
Making Cell Phone Games An Overview Ray Ratelis Guild Software, Inc.
V0.01 © 2009 Research In Motion Limited Understanding Java APIs for Mobile Devices Trainer name Date.
Cosc 4730 Phone Programming in Java An Introduction.
© 2009 Research In Motion Limited Introduction to GPS and Wi-Fi technology on BlackBerry smartphones.
70-293: MCSE Guide to Planning a Microsoft Windows Server 2003 Network, Enhanced Chapter 7: Planning a DNS Strategy.
Copyright : Hi Tech Criminal Justice, Raymond E. Foster Police Technology Police Technology Chapter Five Police Technology Geographic Information.
Java 2 Platform, Micro Edition (J2ME) By Xiaorong Wang.
Monitoring systems COMET types MS55 & MS6 MS55/MS6 Configuration.
11 Obtaining the User’s Position Dr. Miguel A. Labrador Department of Computer Science & Engineering
Pervasive Computing MIT SMA 5508 Spring 2006 Larry Rudolph 1 Location Again Location API’s and Room-Size Location Feb 28, 2006 Larry Rudolph.
Integrated Vehicle Tracking and Communication System.
Location-Based API 1. 2 Location-Based Services or LBS allow software to obtain the phone's current location. This includes location obtained from the.
Michael Brockway Advanced Applications Development in Java J2ME -- Introduction l Introduction / Overview l Java 2 Micro Edition n CLDC n MIDP l Examples.
Lecture # 9 Hardware Sensor. Topics 2  SensorManger & Sensor  SensorEvent & SensorEventListener  Example Application.
70-291: MCSE Guide to Managing a Microsoft Windows Server 2003 Network Chapter 7: Domain Name System.
INTRODUCTION TO HTML5 Geolocation. Display a Specific Location with Google Maps  You can use the Google Maps API to display a custom map on your own.
Computer Science Wi-Fi App using J2ME and MVC Architecture Advisor : Dr. Chung-E Wang Department of Computer Science Sacramento State University Date:
J2ME Presented by May Sayed & Menna Hawash. Outline Introduction “Java Technology” Introduction “What is J2ME?” J2ME Architecture J2ME Core Concepts 
Demo. Overview Overall the project has two main goals: 1) Develop a method to use sensor data to determine behavior probability. 2) Use the behavior probability.
Investigation in the development of Standalone Location Based Services Nkululeko Gojela Supervisor: Dr Hannah Thinyane FINAL PROJECT PRESENTATIONS.
PROG Mobile Java Application Development PROG Mobile Java Application Development BlackBerry App Lifecycle Java ME API.
1Basics of J2ME. 2 Objectives –Understand the different java API’s and how the mobile edition API’s fit in –Understand what a mobile configuration and.
GEOREMINDERS ANDROID APPLICATION BY: ADRIENNE KECK.
Event Management & ITIL V3
Context Aware Location Nasrullah. Location Basics LocationManager—Class providing access to Android system location services LocationListener—Interface.
Java Programming: Guided Learning with Early Objects
Linux+ Guide to Linux Certification, Third Edition
GPS for Teachers. What is GPS? Global Positioning System –A Network of satellites that continuously transmit coded information, which makes it possible.
Location. GPS Global Positioning System – At least 4 satellites typically used 3 required extra for error detection and altitude typically accurate within.
PIMRC 2007 A lightweight approach for providing Location Based Content Retrieval Anastasios Zafeiropoulos, Emmanuel Solidakis, Stavroula Zoi, Nikolaos.
1 © 2005 Cisco Systems, Inc. All rights reserved. Session Number Presentation_ID Cisco Public Cisco Unity Connection Notification Jane Rygg Core Services.
Class Builder Tutorial Presented By- Amit Singh & Sylendra Prasad.
Karolina Muszyńska Based on: S. Wrycza, B. Marcinkowski, K. Wyrzykowski „Język UML 2.0 w modelowaniu SI”
Android - Location Based Services. Google Play services facilitates adding location awareness to your app with automated location tracking Geo fencing.
FriendFinder Location-aware social networking on mobile phones.
Sensors in android. App being more applicable Keeping track of your heart beat while jogging. Pointing the phone camera towards the night sky to know.
Sensors – Part 2 SE 395/595. Location in Android LocationManager class – Configure providers and their listeners LocationListener class – Handles update.
DEVOLOPING ANDROID APP ON LOCATION BASED REMINDER ON ANDROID MOBILE SYSTEMS.
Perfecto Mobile Automation
6 Copyright © 2007, Oracle. All rights reserved. Managing Security and Metadata.
Phonegap Bridge –Geolocation and Google maps CIS 136 Building Mobile Apps 1.
Copyright © 2016 Ramez Elmasri and Shamkant B. Navathe.
Enhanced mobile services in Java enabled phones Björn Hjelt Sonera zed ltd Supervisor: Professor Jorma Jormakka.
How to complete and submit a Final Report through Mobility Tool+ Technical guidelines Authentication, Completion and Submission 1 Antonia Gogaki IT Officer.
In this session, you will learn to: Create and manage views Implement a full-text search Implement batches Objectives.
CPE 490/590 – Smartphone Development
Garmin 60CSx How To Use The Available Features Photos by IN-TF1 Technical Search, Stephen Bauer Written by IN-TF1 Technical Search, Jean Seibert.
1. 2 Android location services Determining a device’s current location Tracking device movements Proximity alerts.
Advance Computer Programming Market for Java ME The Java ME Platform – Java 2 Micro Edition (J2ME) combines a resource- constrained JVM and a set of Java.
The Java Platform Micro Edition Java ME
1 Terminal Management System Usage Overview Document Version 1.1.
Mobile Computing CSE 40814/60814 Spring 2017.
AnDroid GoogleMaps API
Java Beans Sagun Dhakhwa.
Sensors, maps and fragments:
Wireless Instant Messaging Using J2ME
Mobile Computing CSE 40814/60814 Spring 2018.
Using K2 applications How can users interact with K2 applications?
Always Connected introduces Tigo SMART 3.1 This guide is interactive!
Greta Mameniskyte IV course 3rd group
CS378 - Mobile Computing Location and Maps.
Presentation transcript:

JSR-179 API exploitation and philosophy Francesca Bellanca Paolo Rodolà

Location API overview The Location API for Java™ 2 Platform, Micro Edition (J2ME™) (JSR is an optional package that can be used with many J2ME profiles. The purpose of the Location API is to enable the development of location-based mobile applications. Considering the nature of mobile devices, the Location API provides a natural way to utilize location-based information. Moreover, the Location API is a compact package of classes and interfaces that are easy to use. The three main features that the Location API brings to mobile programming are:  Obtaining information about the location of a device  The possibility to create, edit, store, and retrieve landmarks  The possibility to obtain the orientation of a device

Location API overview The Location API needs a connection to a location-providing method, which generates the locations. Location providing methods differ from each other in many ways. The most common methods are:  device-based (for example, GPS module a method based on a Global Positioning System's satellites)  network-based (for example, cell of origin – a method in which the network determines a user's place)  hybrid methods (for example, A-GPS - a GPS method which also uses network-based information to speed up location determination).

Location API overview The figure below shows a generalized structure of a Location API MIDlet that uses a GPS module as a location providing method. After the MIDlet is found to be working properly in the SDK environment, it should also be tested under real-world conditions. Typically, real-world testing means the outdoor use of the MIDlet in a device that supports the Location API.

Main Use Cases Location-Based Services (LBS) are applications that utilize a user’s current physical location to provide enhanced services. We can use location information for a variety of purposes. The use cases include:  Mapping, navigation, and directions applications, which can also be combined with directory services  Workforce-tracking and management applications  Interactive gaming and services that complement sporting events, concerts, and more  “Finder” applications can apply users’ location to help them locate people or places nearby  Weather applications can provide local forecasts and warnings about bad weather

Geographic Coordinate System The Location API uses coordinates that are given using the World Geodetic System (WGS 84) datum at It is also currently used as reference system by the Global Positioning System (GPS). The coordinates in the API are constructed from latitude, longitude, and altitude values. (In this case, altitude is the elevation above the sea level.)

Using the Location API The Location API is defined in the javax.microedition.location package. The first operation in the API use is choosing the location Provider. Those classes are introduced first in the table below. ClassShort Definition CriteriaUsed for the selection of the location provider. LocationProviderRepresents a source of the location information (e.g., GPS module). Usually an application that uses the Location API examines the device's position updates. The Location API uses listeners to examine these updates. The table below introduces these listeners. ClassShort Definition LocationListener Listener that receives events associated with a particular LocationProvider. ProximityListenerListener to events associated with detecting proximity to registered coordinates.

Using the Location API The table below briefly introduces a set of classes for the measurement of a device‘s location. ClassShort Definition AddressInfo Holds textual address information about a location. CoordinatesRepresents coordinates as latitude, longitude and altitude values. LocationRepresents the standard set of location information (time-stamped coordinates, speed, accuracy, course, etc.) LocationExceptionIs thrown when a location API-specific error has occurred. QualifiedCoordinatesRepresents coordinates as latitude, longitude and altitude values that are associated with an accuracy value.

Location information can be stored for later use in the landmark store. The table below introduces the Location API classes for this purpose. Using the Location API ClassShort Definition Landmark Represents a known location with a name. LandmarkExceptionIs thrown when an error related to handling landmarks has occurred. LandmarkStoreMethods for persistent landmark store management (store, delete, and retrieve landmarks). If the device's sensors support the obtaining of orientation information, the information is available through the Location API's Orientation class. ClassShort Definition Orientation Represents the physical orientation of the device.

Choosing the Localization Provider The starting point of the API use is the LocationProvider class, which represents the location provider module. An instance of the LocationProvider class can be created by using the factory method LocationProvider.getInstance(Criteria criteria). Criteria parameters can be used to define what kind of location provider is accepted. The Location API implementation chooses the location provider that best matches the defined criteria. If the device does not have any built-in location methods available or any external methods connected to it, the LocationProvider.getInstance() method throws LocationException, and the MIDlet gives a notification that says all providers are out of service. The location provider is found when the result from LocationProvider.getInstance() is not null. The MIDlet continues the search in a loop until one location- providing method is found.

Creating listeners When LocationProvider has been successfully created, it can be used to register the MIDlet to listen for regular location updates and to detect certain coordinate proximity. Current location update and location provider state change events can be listened to through the LocationListener interface. Through this interface a JSR-179 application may track a device's route. Through ProximityListener, the interface MIDlet obtains notifications when a registered coordinate is detected. Proximity event listening makes it possible to monitor when the device arrives in a certain area, for example close to a hotel or restaurant.

Registering listeners LocationListener implementation can be registered to a particular location provider with LocationProvider's setLocationProvider method. With this it is possible to define the following parameters:  the interval (in seconds) at which the application wants to receive events  the timeout value, which indicates how late (in seconds) an update is allowed to be in comparison to the defined interval  the maxage value, which defines how old the location update value is allowed to be

The Proximity Listener We can also register the ProximityListener by using LocationProvider's static addProximityListener method. With this method, for each listened coordinate one can also set a radius (in meters) that is a threshold value for event launching. In case the registration fails due to a lack of resources or support, LocationException is thrown. Proximity listener registration method takes the Coordinates parameter, which can be obtained, for example, from the Landmark instance by using the getQualifiedCoordinates() method. All devices and emulators might not support proximity event sending through the ProximityListener interface. If the target device has no support, listeners have no effect.

Landmark Store Landmarks can be stored for later use to a specific database called landmark store. All landmark stores are shared between all J2ME™ applications. Landmarks in the stores have a name identifier and may be placed into one or more categories, making it easier to find landmarks from the store, because especially in urban areas many different types of landmarks may be located close to each other. Devices contain one default landmark store. In addition, it may be allowed to create new landmark stores. The Location API enables applications to add new categories and remove existing ones within landmark stores. The LandmarkStore class contains a set of landmark management methods. Enumeration of Landmark objects can be obtained with one of the three getLandmarks() methods. The first method does not use parameters and provides a list of all stored landmarks in a specific landmark store. The other two methods can be used to fetch only the landmarks that match the set parameters. So we can obtain a list of landmarks from a specified category that are within a defined area and bounded by the min and max latitude and longitude positions or we can list landmarks within a specific category.

An existing landmark in the landmark store can be updated by using the updateLandmark(Landmark landmark) method. This method throws LandmarkException if the landmark passed as a parameter does not belong to the landmark store. In addition, landmark removal from the landmark store can be done with the deleteLandmark(Landmark lm) method. Also this method throws LandmarkException if the landmark passed as a parameter does not belong to the store. Furthermore, an existing Landmark object can also be removed only from the specific category with the removeLandmarkFromCategory(Landmark lm, String category) method. Landmark Store

Device Orientation Some devices may include a hardware sensor that determines the orientation of the device. If the sensors are magnetic, the orientation is given as magnetic angles to the application. The sensor type can be checked by using the isOrientationMagnetic() method of the Orientation class. Orientation information can be obtained from the API's Orientation class. If the device's sensor provides only a horizontal compass azimuth, the getPitch() and getRoll() methods of the Orientation class return Float.NaN as a sign that information is not available. If the device contains a 3D-orientation sensor, these two methods provide numeric information. The range of pitch values is [-90.0, 90.0] degrees. A negative value means that the top of the device screen is pointing towards the ground. The range of roll values is [-180.0, 180.0]. If roll values are negative, the device is orientated counter-clockwise from its default orientation.

Device Specifications The Location API for Java™ 2 Platform, Micro Edition (J2ME™), first introduced in S60 and Series 40 3rd Edition, is an optional package that can be used with many J2ME profiles. The minimum platform for JSR179 use is Connected Limited Device Configuration (CLDC) 1.1, because the API requires floating point math support.

JSR-179 API application Our idea is to use this API on the devices that support this specification, and to develop a similar API as well for the devices that do not support it, following its philosophy (let us call it SMS-179 API ). Moreover, since our localization system provides more advanced features to mobility services, our goal is to extend the original JSR-179 API to support these features. EXTENDED JSR-179 JSR – 179 API EXTENDED SMS SMS – 179 API JSR-179 supporting devicesJSR-179 non-supporting devices

The choice of exploiting the original extended JSR-179 and our version can be done either at deployment time or at runtime. The former case refers to the distinction between devices that natively support the JSR-179 API and devices that does not, letting us to deploy the most appropriate version. The latter case refers to a runtime choice between the original JSR-179 API or the extended one, even for devices that natively support the JSR-179 API. This is the case wherein more advanced features must be provided in order to satisfy the mobile services the user demands. JSR-179 API application

Devices supporting the Location API VendorDevicePlatform BlackBerry7520MIDP/2.0, BlackBerry CLDC/1.1 BlackBerry8800MIDP/2.0, BlackBerry CLDC/1.1 MotorolaI870MIDP/2.0, JTWI/1.0 CLDC/1.1 MotorolaI730MIDP/2.0 CLDC/1.0 MotorolaI88sMIDP/2.0 CLDC/1.0 MotorolaRAZR2 V9MIDP/2.0 CLDC/1.1 Nokia2855MIDP/2.0, JTWI/1.0 CLDC/1.1 Nokia5500MIDP/2.0, JTWI/1.0 CLDC/1.1 Nokia6165MIDP/2.0, JTWI/1.0 CLDC/1.1 Nokia6275iMIDP/2.0, JTWI/1.0 CLDC/1.1 Nokia6290MIDP/2.0, JTWI/1.0 CLDC/1.1 NokiaE50MIDP/2.0, JTWI/1.0 CLDC/1.1 NokiaE60MIDP/2.0, JTWI/1.0 CLDC/1.1 NokiaE61MIDP/2.0, JTWI/1.0 CLDC/1.1 NokiaE62MIDP/2.0, JTWI/1.0 CLDC/1.1 NokiaE70MIDP/2.0, JTWI/1.0 CLDC/1.1

Devices supporting the Location API VendorDevicePlatform NokiaN3250MIDP/2.0, JTWI/1.0 CLDC/1.1 NokiaN71MIDP/2.0, JTWI/1.0 CLDC/1.1 NokiaN73MIDP/2.0, JTWI/1.0 CLDC/1.1 NokiaN75MIDP/2.0, JTWI/1.0 CLDC/1.1 NokiaN76MIDP/2.0, JTWI/1.0 CLDC/1.1 NokiaN80MIDP/2.0, JTWI/1.0 CLDC/1.1 NokiaN91MIDP/2.0, JTWI/1.0 CLDC/1.1 NokiaN92MIDP/2.0, JTWI/1.0 CLDC/1.1 NokiaN93MIDP/2.0, JTWI/1.0 CLDC/1.1 NokiaN93iMIDP/2.0, JTWI/1.0 CLDC/1.1 NokiaN95MIDP/2.0, JTWI/1.0 CLDC/1.1 SamsungSPH M620MIDP/2.0 CLDC/1.1° SiemensC65MIDP/2.0, CLDC/1.1 SiemensCX65MIDP/2.0, CLDC/1.1 SiemensS65MIDP/2.0, CLDC/1.1 SiemensSK65MIDP/2.0, CLDC/1.1

Devices supporting the Location API VendorDevicePlatform SiemensSL75MIDP/2.0, CLDC/1.1 SiemensSXG75MIDP/2.0, JTWI/1.0 CLDC/1.1 Sony-EricssonK630MIDP/2.0 CLDC/1.1 Sony-EricssonK640MIDP/2.0 CLDC/1.1 Sony - EricssonK850MIDP/2.0, CLDC/1.1 Sony-EricssonK858MIDP/2.0, CLDC/1.1 Sony-EricssonW908MIDP/2.0, CLDC/1.1 Sony-EricssonK660MIDP/2.0, CLDC/1.1 Sony-EricssonK850MIDP/2.0, CLDC/1.1 Sony-EricssonW910MIDP/2.0, CLDC/1.1 Sony-EricssonW890MIDP/2.0, CLDC/1.1 Sony-EricssonZ750MIDP/2.0, CLDC/1.1

References  MIDP: Location API Developer's Guide v.2    