21
Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan Janeiro [email protected] CRUISe Project

Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

Embed Size (px)

Citation preview

Page 1: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

Context Infrastructure for Developing Context-Aware Applications

Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze

Jordan [email protected]

CRUISe Project

Page 2: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

2 von 15

Agenda

• Why Develop Context-Aware Applications

• MoCA Framework– Architecture– Context Model

• Use Cases - CRUISe

Page 3: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

3 von 15

Motivation

• Ubiquitous and Pervasive computing demonstrate a trend towards more complex and dynamic computer networks

• This complexity is mainly introduced by:– Varying quality of wireless links;– Heterogeneous capabilities of connected

nodes;– QoS and reliability

• Adaptation of services by “context” changes– Dynamically;– Transparently

Page 4: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

4 von 15

Motivation

• Context is …– ” Context is any information that can be used

to characterise the situation of an entity. An entity is a person, place, or object that is considered relevant to the interaction between a user and an application, including the user and applications themselves.”

• Adaptations need support of a software infrastructure to provide context– Implement the retrieval of “low-level”

information in the mobile devices– Many middlewares were proposed

Page 5: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

5 von 15

Objectives

• Use a software infrastructure to support the retrieval of context information– Implemented as “sensors”

• Bandwidth• Location• Luminosity

• Implement adaptation rules based on the context information

Page 6: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

6 von 15

Mobile Collaboration Architecture - MoCA

Page 7: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

7 von 15

Mobile Collaboration Architecture - MoCA• Discovery Service

– Accepts announcements of applications, and allows Clients to locate the corresponding Servers and Proxies;

• Configuration Service– Stores and manages the configuration of each mobile device: MAC

Address, (IP:port) pair of CIS, periodicity of the Monitor repots to the CIS, and (IP:port) pair of the Discovery Service;

• Location Inference Service– Infer the location of devices using 802.11 interface (indoors)

• Context Information Service– Stores and processes the state information received from the

Monitors, and eventually sends notifications about context changes to Proxies which have subscribed to such notifications

• Monitor– Is in charge of: (i) probing the state information (aka execution

context) of the mobile device and (ii) sending this information to the Context Information Service (CIS) executing in the static network

Page 8: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

8 von 15

Mobile Collaboration Architecture - Monitor• Is a daemon executing on the mobile device;

– Periodically polls (and sends to the CIS) state information about the mobile device’s resources and wireless RF signals, e.g.:

• Strength of RF signal received from all visible Access Points ;• CPU utilization, available memory and energy;• MAC Address, IP and currently used Access Point;

• RF signals are obtained through WiFi scan operations independently of the 802.11 network interface;

• Also reports to the CIS any change of the current IP address or Access Point of the device (i.e. a migration)

• Implementations ready for– Windows XP– Windows CE– Linux– Symbian– Nokia N60

Page 9: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

9 von 15

Mobile Collaboration Architecture - Monitor

Page 10: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

10 von 15

Mobile Collaboration Architecture – Monitor Simulator• Is a tool which simulates a mobile device:

– Behavior defined by a configuration file (scans are read from different files)

– Sends this information to CIS (like the “real” Monitor)– Can be deployed on any host

• This facilitates: – Debugging of the context-aware applications in the

usual networked environment (without having to physically move between regions)

– Evaluating the scalability of the application (test with hundreds/thousands of fake mobile devices)

Page 11: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

11 von 15

Information of Device’s Context

Monitor

Application

Monitor

Application

CIS

Page 12: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

12 von 15

Context Notification - Polling

Monitor

Application

Monitor

Application

CIS

EnergyLevel < 30 and FreeMemory > 5000 ??????

EnergyLevel < 20 and FreeMemory > 5000 ??????

EnergyLevel = 28 FreeMemory = 6000

Page 13: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

13 von 15

Context Notification – Publish/Subscribe

Monitor

Application

Monitor

Application

CIS

EnergyLevel < 20 and FreeMemory > 5000

EnergyLevel > 20 and FreeMemory > 5000

EnergyLevel = 18 FreeMemory = 6000

Page 14: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

14 von 15

Context Model

• Automatically Collected Hardware Context Variables• CPU Usage (%);

• Battery Energy Level (%) ;

• Free Main Memory (KB);

• Advertisement Periodicy – Monitor (seconds);

• Delta T – context freshness (ms);

• Acess Point Mac Address (Mac Address);

• OnLine (boolean);• Other devices

Page 15: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

15 von 15

Context Model

• Automatically Collected Hardware Context Variables• IP Change (boolean);

• AP Change (boolean);

• Roaming (boolean);

• List of Available Acess Points (Array);• AP Mac Adsress (MAC Address);• RSSI (Integer);• SSID (String);

• Static Hardware Context Variables

• Device Type (String);

• ScreenSizeWidth (Integer);

• ScreenSizeHeight (Integer);

• ColorCapable (Boolean);

• BitsPerPixel (Integer)

Page 16: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

16 von 15

Adaptations for the Use Cases

• „The Closest Place“ service– FunctionalityFunctionality

• Find the closests place to the user– ExamplesExamples

• Hotels, restaurants, car rentals, „luggage locks“, public transpostation stations, information services, touristic attractions, bike rentals, pharmacies, doctors and hospital

– Context VariablesContext Variables• User‘s location, place location

• „Wheather Forecast“ service– FunctionalityFunctionality

• Find the whether forecast information to specific places– Context VariablesContext Variables

• Place location

• „Personalized News“ service– FunctionalityFunctionality

• Set the News broadcast to a specific country• Set the language for a News broadcast

– Context VariablesContext Variables• Home Location, Mother Language

Page 17: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

17 von 15

Adaptations for the Use Cases

• „Screen Expansion“ service– FunctionalityFunctionality

• Expand the display of a device to a another device (netbooks or notebooks)

– Context VariablesContext Variables• Display Size, Available Devices

• „Automatic Route Calculation for Agenda Appointments“ service– FunctionalityFunctionality

• Calculate the route to the address of the next appointment in the agenda– Context VariablesContext Variables

• Current Location, User Profile Options (fit or green)

• „Cheap Citesseing“ service– FunctionalityFunctionality

• Find a citeseeing which covers the citeseeing of a city wiht public transportation

– Context VariablesContext Variables• Current Location, Public Transportation Available in the Location, Location

of Touristic Attractions

Page 18: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

18 von 15

Adaptations for the Use Cases

• „Automatic Ticket Buying“ service– FunctionalityFunctionality

• Buy transportation tickets automatically based on the proximity of the device to special buying places

• „I am in hurry“ service– FunctionalityFunctionality

• Calculate the fastest route to a location, based on the period of a day and traffic data

– Context VariablesContext Variables• Current User Location, Period of the Day, Traffic Statistic Service of the

Current User Location

• „Battery Saving“ preference– FunctionalityFunctionality

• Stop streaming services or change them to less consuming bandwidth/battery services

• Change the brightness level of the display– Context VariablesContext Variables

• Battery Level, Bandwidth Threshold Current Location, Visual Impairment Preference

Page 19: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

19 von 15

Adaptations for the Use Cases

• „Special Eating“ preference– FunctionalityFunctionality

• Find special kinds of restaurants: vegetarian, steaks, nuddles or paellas– Context VariablesContext Variables

• Current User Location, Restaurant Locations

• „Movement Impairment“ preference– FunctionalityFunctionality

• Find less walking routes• Find stations which support transit of impaired people

– Context VariablesContext Variables• Current User Location, Current Location Station Information, Destination

Location

• „Visual Impairment“ preference– FunctionalityFunctionality

• Display bigger icons in the screen• Enable machine speaking mechanism• Change the brightness level of the display• Change the ilumination of the keyboard

– Context VariablesContext Variables• Screen Size, User Visual Impairment, Environment Light Level

Page 20: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

20 von 15

Adaptations for the Use Cases

• „Fit Feeling“ preference– FunctionalityFunctionality

• Rank the kinds of transporation based on movement (1. Walking, 2. Bike)

– Context VariablesContext Variables• Current User Location, Destiny Location,

Physical Level Movement of the Transportation

• „Green Conscience“ preference– FunctionalityFunctionality

• Calculate routes based on the CO2 emission– Context VariablesContext Variables

• Current User Location, Destination Location, CO2 Emission of the Local Transportations

Page 21: Context Infrastructure for Developing Context-Aware Applications Fakultät Informatik, Institut für Systemarchitektur, Lehrstühl für Rechnernetze Jordan

21 von 15

Conclusion

• A middleware (MoCA) which supports the development of context-aware applications

• An extensible context model to gather specific context information

• Future context-based scenarios for the CRUISe project based on MoCA