Various Exercises

Exercise 1: Building an occupancy simulator and an alarm application

Both alarm and occupancy simulation applications are two well known proactive/reactive systems for protection against system.

Question 1 – Alarm application: Based on your previous experiences with building pervasive application, propose an architecture and implement an alarm application. To alert the administrator your alarm can be based on the lights (that you can turn on), the audio system (based on iCASA audio devices), or/and on an Android GUI (that you will develop).

Your system should be able to automatically turn on the alarm when all the users are leaving. You can also disable the system using the location service when legitimate users are entering the house. We assume that the system is able to distinguish between authorized/unauthorized users.

Question 2 – Building an occupancy simulation application: Propose an architecture and implement an application for simulating occupancy. The goal is to mimic the users activities by the turning your lights on and off just as if they were in the home.

To this end, it would be a good idea to reuse previously written services (e.g., room occupancy service). It would also be interesting to know which particular device is used at a given moment of the day.

You can decouple the activation/deactivation of the occupancy simulation application by building a dedicated autonomic manager that will be able to activate/deactivate the application based on the presence of users. The same applied to the level of energy used by the simulation.