Professional Documents
Culture Documents
ii). [4 marks] Give two examples of pervasive computing applications and explain the
characteristics of these applications that make you classify them as pervasive computing
applications?
a Such as billboard advertisement, user type input from her mobilephone ± it will appear in
the billboard
a Locate places of interest, user find places in which she is currently in the area.
- RFID Based Maintenance at Frankfurt Airport (Slides11.1)
- Total Navigation Support in Japan
- SMS Games
a The characteristic of the applications: mobile and ubiquitous, the technology is applicable
anywhere, anytime and anyway to access data, knowledge, computional support or
resources. It includes everyday life activites of devices user and the user environment.
Both devices are embedded in the environment.
iii). [6 marks] What are the main characteristics of the mobile computing environment
that makes it different from the desktop computing environment? [Hint: Consider the
characteristics of mobile devices, wireless communication and the typical user of mobile devices.]
a Example ±
In Odyssey, the role of the operating system is to sense external events (such as connectivity and
physical location changes), and to monitor and allocate resources (such as network bandwidth,
cache space, battery power, and communication budget).
In contrast, the role of individual applications is to adapt to changing conditions by using the
information and resources provided by the operating system. (the application subscribes to
notifications about changes via the Odyssey API)
The nature of the adaptation is specific to the application. For example, in accessing video data,
degrading the display from full motion color to black and white, and thence to slow-scan might be
appropriate. But when accessing map data, the meaningful form of degradation might be to lower
the resolution and minimum feature size represented. The overall goal is to minimize the need for
active intervention by users to cope with the consequences of mobility. For example, it is
inappropriate to require the user to use a different video display program when bandwidth drops.
a × does lo÷er fielit cause t e reuce po÷er consumption?
As t e fielit of t e vieo is reuce t e processor can operate at corresponingl lo÷er
clock frequencies since t e neee computation per frame is smaller. ×it suc a
processor t e total energ use b t e lo÷est fielit ÷ill be significantl reuce.
v). [10 marks] Oracle Lite architecture and MySQL Server on Mobile are two examples of mobile
database systems.
a). [4 marks] Draw a diagram to show the main architectural components in a typical mobile
database system.
b). [4 marks] Explain how a mobile database system supports data hoarding, disconnected
operation and reintegration/synchronization. [Hint: Comment on why certain components are
present in the architecture and what the functions of these components are.]
Mobile database system supports: (Slides 1.4, no 47)
a data hoarding (Oracle Lite DBMS- client side) Hoarding: preload data onto a mobile device
to allow continued operation during disconnection; need to reintegrate after reconnection.
a disconnected operation (Mobile Lite SQL and DB Lite DBMS ), update a hoard (snapshot
unit), updates at Client
c). [2 marks] Do existing mobile database systems support the push (broadcast) mode of delivery
or pull (query) mode of delivery in bringing data from the stationary server to the mobile device?
Push
- Try to use thread, runnable, so while data is being load, user can do other activities, this
will not effect user
- Keep user informed of what happen (put gauge for processing an action), so with this
visual feedback, user will know current situation.
- Control the program, such as put wait form, so the user will have to wait and cant do other
activities, this is to control the process such as for data is in high volume.
- Chunk data to be sent, such as sent data in multiple SMS, and sent it in friendly way, such
as sent it as part1, then part2, so user know the sequence of data being sent.
ii). [8 marks] The figure below illustrates the lifecycle of a MIDlet application.
Method Description
a). Explain why the ³Paused´ state is useful. Initialize and waiting, release any shared resources
and leave your MIDlet in a quiescent state, because the AMS or device OS will be bringing
another application to the foreground.
b). Which method is called when the MIDlet first starts up? startApp()
c). Which method is called when the MIDlet is paused? pauseApp()
d). In programming a MIDlet, which method(s) must the programmer implement? startApp()
estroApp() pauseApp()
iv). [6 marks] Below recall the set of commands used for controlling a MIDlet.
b). In an application with many commands, why will certain commands be mapped to a submenu
(and accessible via more than one button presses) whereas other commands are accessible
directly via only one button press?
Because soft button, because there are more than 2 commands, so the menu will be
automatically created.
c). In a submenu containing three commands (³delete´, ³update´ and ³execute´), how will you
ensure that the command ³execute´ is at the top of the submenu, and the command ³delete´ is at
the bottom of the submenu?
Question 3 [40 marks]
i). [4 marks] What is the general layered abstract architecture for context-aware computing
applications?
ii). [8 marks] What would be the main components of a context-aware computing application,
according to the Context Toolkit architecture?
(Slie 7.7)
a)
Location model: Symbolic location models:
b)
c)
Location model: Geocoding
Positioning Technologies: Wireless networking based: Bluetooth, cellular networks (Cell
ID identified using the Base Stations), Wireless LAN (e.g., www.ekahau.com).
On a mobile phone, location provider depends on the location information - might be cell
ID, GPS coordinates or symbolic (using IR or Bluetooth based beacons). Hardware of the
phone determines what location method the API calls map to, varies depending on the
actual device the API has been implemented on
Symbolic location models: hierarchical model, Granularity: shops
v). [12 marks] Consider the case study of an ambient services application as below.
The user can receive updates of different services when in different shops and zones/areas.
For example, the user sees a different list of services when in different areas/zones.
a). [6 marks] Given the floor plan above with shop areas, each at least of size 8m by 9m, describe
a solution to provide zone-based positioning to determine which zones (i.e., shop areas) users
would be located in - describe the technologies you would use, e.g., hardware and software
required, and your reasons, and state any assumptions you make.
ii). [3 marks] Propose a method to improve the accuracy of RF fingerprinting. Explain why your
method would improve the accuracy.
Instead of 3, add more access points because more signals reading is better for circle. Refer
CISCO handout 11
iii) [7 marks] Explain why at least three WiFi access points are required for Received
Signal Strength (RSS) triangulation for WiFi. Draw diagrams and provide examples in explaining
your answers.
If there is only two APs there will be another point which have the same distance, that¶s why need
three AP at least.
Because all the access points is spread out, different angle distinguish each APs, the similar
strength look same. Greater chance for different APs.
This method will compare signal strength measurements from access points at different distances
away. (Slide 7.5)
iv). [8 marks] Given the floor plan below, the three small shaded circles represent the positions of
(the only) three WiFi access points on the floor. Are these three positions for access points the
best for positioning using Received Signal Strength (RSS) triangulation? If not, provide better
positions for the three access points for positioning, and justify your answer.
[HINT: Explain why the position of the WiFi access points are important for Received Signal
Strength (RSS) triangulation for WiFi. Draw diagrams and provide examples in explaining your
answers.]
Gisco page 9 1. T e most important«..
Calibration, each signal strength is unique where (a, b, c) is compared with all point.
(a ±s1)2 + (s2-b)2 +(s3-c)2
Technology used: RFID semi (no battery), put tag at flower pot. Choice of tag semi passive, so
don¶t have to change battery because life time to track flower pot not too long.
Plantation to retails store is approximately 2-3 days. Readers can be put to all location involved:
- Plantation
- Warehouse
- Vehicles
- Retail stores
Example diagram refer slide MPC topic 3-RFID
ii). [5 marks] What are the advantages of standards for Radio Frequency Identification (RFID)
technologies (such as the EPCglobal standards)?
It standardized the format of ID, make international business compatible to any country. An easy
and fast way to track the goods whereabouts.
Assuming that these devices (the spy pen and spy earpiece) always have the same standard
Bluetooth device name ³spy´ (though each has a different MAC address), Device a method to
detect persons (within an exam hall) that may be using such a method to cheat. State any other
assumptions you make.
Put a Bluetooth sensor so any Bluetooth signal used in the exam hall will be detected.
ÿT in Action
Phase 1: device discovery
Phase 2: service discovery (there must be compatible services on both devices)
Phase 3: application-to-application connection (application-level connection establishment &
communication)
Service Discover
Each device has a database of service records, standardized serviceclassID embedded in UUID
to identify a class of (common) services
A device can interrogate another device to retrieve a list of services on the device
A service record contains information about a service available on the device, accessible via BT
There is an API to register a service, i.e. to add service records to the service DB
(Slide 8.3)
iii). [8 marks] Consider the following code fragments from a Bluetooth application called BTApp.
«
import javax.bluetooth.DiscoveryListener;
«
public class BTApp implements Runnable, DiscoveryListener {
«
private Vector devices = new Vector();
«
/* in some method, a Bluetooth inquiry is started */
discoveryAgent.startInquiry(DiscoveryAgent.GIAC, this);//put the mobile in query mode
«
public void deviceDiscovered(RemoteDevice btDevice, DeviceClass cod) {
// same device may found several times during single search
if (devices.indexOf(btDevice) == -1) {
devices.addElement(btDevice); //it will add the device to the list µdevices¶
}
}
«
}
a). [4 marks] Based on only the code fragments above, explain, in your own words, what BTApp
would likely be doing when it executes and starts to discover other Bluetooth devices.
BTApp firstly try to detect device with DiscoveryListener, then, once discovered, establish BT link:
pairing
b). [4 marks] Mr. Jack Chan owns a restaurant though is seldom there himself. He wants to know
how crowded his restaurant can get at different times of the day, and
if the same people goes to his restaurant, and how often they go, that is, are there regular
customers?
Explain briefly (you do not have to give any code) how you can use BTApp to help Mr. Chan with
the above, and what shortcomings (if any) of this approach might be.
Detect if same person entered his restaurant.
Set a DB / recordstore ± detect (using BT) ± add the customer to the list with the timestamp (for
how crowded ± count the customer), ID, user profiles for each occurrence.
Shortcomings = customer disable their BT application
ii). [10 marks] J2ME specifies a library to support GPS based location information, that is, JSR
179.
a). [5 marks] Consider the J2ME code fragment below.
Criteria cr = new Criteria();
cr.setHorizontalAccuracy(10);
LocationProvider lp =LocationProvider.getInstance(cr);
Location l = lp.getLocation(60);
Coordinates c = l.getQualifiedCoordinates();
if (c != null ) {
double lat = c.getLatitude();
double lon = c.getLongitude();
} ...
With GPS coordinates, the latitude N 25° means 25 degrees north of the Equator. The latitude S
22° means 22 degrees south of the Equator, which can also be written as the negative number -
22°. And similarly with longitudes, east or west of a reference line Greenwich Meridian (which is
defined to have longitude 0°).
Given that the user is at location (latitude) N 10° and (longitude) W 75° (minus), when the above
code fragment is executed on the user¶s phone (which has an integrated GPS receiver), explain
what the above code does as detailed as you can, and give the values of lat and lon.
The code will find the location specified from the criteria with accuracy of 10(is it meter?) and in 60
seconds timeout. Then it get the coordinates in longitude and latitude form.
lat is 10.0000
lon is -75.0000
b). [5 marks] Linda Smith would like to build a social network application called ³Surprise!´ using
JavaME. In her JavaME application, whenever a Facebook friend (www.facebook.com is a social
network web site where a person can list his/her friends) comes within 20m of her, then
(assuming that the Surprise! application has been installed on her phone and on her friends¶
phones), an SMS application will be automatically sent from her phone to her friend¶s phone. She
needs your advice«.
Provide pseudo-code for the main logic for this JavaME application, mentioning the JavaME APIs
for messaging and positioning she might use in her application (including the classes and
methods of the API she should use, where applicable) and features of the JavaME Application
Management System (AMS) that she shou .
1.create a connection
2. setMessageListener(ml)
[ml is any instance of a class that implements MessageListener interface and provides a definition
for the method notifyIncomingMessage(..)]
3. wait for messages
4. be notified of message & handle the message in the method notifyIncomingMessage(..)
ld employ. State any assumptions you make.