ANDROID - Intelligent Room meets Smartphones
Participants
- Soufian Jebbara
- Carsten Poggemeier
- Felix Tristram
Project Supervisors
- Jan Moringen
- Johannes Wienke
- Sebastian Wrede
Winter Term
Motivation & Application Szenario
Only five years after Apple basically invented the smartphone with it's first generation iPhone there are already more than one billion smartphone's (with a working system like iOS or Android) in use world wide. Each of these devices is able to sense it's environment to some degree, be it by motion and proximity sensors or is at least able to provide other interesting information about it's current status, be it by GPS or just the information about whether there is a call currently in progress. Since these devices are running mostly during all of their owner's waking hours anyway they could be useful and easy to tap into interface between a user and his intelligent environment. Imagine entering an intelligent room. The phone in your pocket recognizes the local WiFi automatically and already logs you into the room's systems. The room's built-in stereo starts to play your favorite music. You deem it a bit too loud, so you just lift your phone on shoulder's height and turn it like a knob in midair - immediatly the music turns to a more comfortable volume. As you start on your day's work you receive a phone call from your special someone and the background music is turned off for the remainder of the call - all without you even having to think about it. This is possible by setting up a simple server and by building an app that runs on your phone, streaming the releveant data to whatever process is needed to fullfill the users wish. We wanted to build that system. So we did.Application Szenario
-
An interaction example for our selected scenario is shown in the video:
Objectives
Objectives
The project goals are- to buid a framwork for that supports simple use cases. The actual implementation of sophisticated use cases is *not* the goal of this project.
- to build a smartphone app that is capable of streaming sensor data on demand to a local server via WiFi.
- to create an application that can run on a linux computer and act as a server, mediating between the smartphone app and the programs actually using the streamed data.
- to build a simple demo application that requests orientation data from a phone in the room via the server to control the volume of the music it is playing.
- to have this system support the management of multiple phones and end-applications simultaneously.
- to create a filter-function where an intermediate program is used as a 'filter' to manipulate sensor data before it is used again.
Description
We selected Android as the smartphone OS of our choice beause it is widespread and easy to develop for. The oldest officially supported Android by our app version is 4.0.3. Our system uses RSB (https://code.cor-lab.de/projects/rsb) to propagate messages between it's components. So far all of it's components have to be in the same local network for it to work. Upon start the smartphone app sends some registration data on a predefined RSB-Channel. The server running in the same network receives this registration data and registers the device internally. Clients can then request a list of all the registered devices together with the sensors these devices provide. They can then proceed to request the sensor data of one device from the server. This request is forwarded to the device itself, which begins to write these sensor data to another predefined RSB channel. This channel is then read by the client, thereby achieving the goal of making the phone's sensor data available for more sophisticated programs to use.Results
- server helps to manage the administration between smartphones and clients
- 'easy' framework
- 'filters' can calculate high cost computations
- 'filters' are supposed to reptitive tasks like converting radian to degree
The following code example illustrates an simple client:
In this example the client program gets the list of user's and sends a message to get the callstatus of a specific smartphone.
Performance
- The data consumption is 80MB per hour, like 20.000 messages per hour. We use one smartphone and one client. The messages get the client from one smartphone.
- The battery consumption on a Galaxy Nexus phone is 16% per hour. At the moment we don't test more phone's.
Discussion and Conclusion
- The system is able to achieve all the previously stated goals.
- A problem is the privacy. The smartphone's stream data without any encoding in the WiFi network. The network has a WPA2 encoding, but all user's can get the data, if they have a key for the network. If the system should work outside the university, the data has to be enrypted.
- So far our system works great with two samrtphone's, one client and one filter. But we didn't test, if our system get problem's with more smartphone's.
Outlook
Future works could be:- Smartphone helps robots to navigate, for instance by the gyroscope.
- Smartphone like a WiiMote to control an avatar.
- Navigate with the WiFi scan results.
- More tests: many smartphone's, many clients for example.