A Context-Driven Programming Model for Pervasive Spaces Hen-I Yang, Jeffrey King, Abdelsalam (Sumi) Helal, Erwin Jansen Pervasive and Mobile Computing Lab, University of Florida {hyang, jck, helal, ejansen}@cise.ufl.edu www.icta.ufl.edu Abstract. This paper defines a new, context-driven programming model for pervasive spaces. Existing models are prone to conflict, as it is hard to predict the outcome of interleaved actions from different services, or even to detect that a particular device is receiving conflicting instructions. Nor is there an easy way to identify unsafe contexts and the emergency remedy actions, or for programmers and users to grasp the complete status of the space. The programming model proposed here resolves these problems by improving coordination by explicitly defining the behaviors via context, and providing enhanced safety guarantees as well as a real-time, at-a-glance snapshot of the space’s status. We present this model by first revisiting the definitions of the three basic entities (sensors, actuators and users) and then deriving at the definition of the operational semantics of a pervasive space and its context. A scenario is provided to demonstrate both how programmers use this model as well as the advantages of the model over other approaches. 1 Introduction As the field of pervasive computing matures, we are seeing a great increase in the number and the variety of services running in a pervasive space. Ad-hoc approaches to developing these spaces become unwieldy with this complexity. As other researchers have found, a programming model for pervasive spaces is required, so that these environments can be assembled as software. The keystone of such a model is context, because of the dynamic and heterogeneous nature of these environments. Several systems and tools have been created to support context-aware development of pervasive spaces [1, 2, 3, 4]. While these existing programming models provide a convenient means for specifying the rules and behaviors of the applications with a formulated and systematic process, they do not provide an easy way to grasp the overall state of the smart space with a glance. In these models, obtaining the “big picture” of the space requires intentional effort; programmers first must know exactly what to look for, then explicitly query the system for particular data, and then compose and interpret the collected data, weaving them into an overall understanding. As the number of applications grows, or the scenarios become more complicated, or services are provided by different vendors, conflict is almost certain. The existing