Implementation of Generic Context Middleware for Context-Aware Applications

DOI : 10.17577/IJERTV1IS3244

Download Full-Text PDF Cite this Publication

Text Only Version

Implementation of Generic Context Middleware for Context-Aware Applications

Ms. A.Kalaiselvi Ms.V.Indumathi Mr. J. Madhusudanan Dr. V. Prasanna Venkatesan

PG Scholar, Department of CSE, Sri Manakula Vinayagar Engineering College, Puducherry

PG Scholar, Department of CSE, Sri Manakula Vinayagar Engineering College, Puducherry

Research Scholar, , Pondicherry University, Puducherry

Associate Professor, Pondicherry University, Puducherry

Abstract

Context-awareness enables generation of context by analyzing situation of users and environments so that applications can autonomously react to contexts without users explicit commands. There is growing interest in the use of context-awareness as a technique for developing pervasive computing applications that are flexible, adaptable, and capable of acting autonomously on behalf of users. In this paper we are presenting the implementation of Gene ric Context Middleware for developing context- aware applications in pervasive computing environment. The implemented context-aware applications shown are Smart Home applications. The Generic context Middleware developed is adaptable for any types of context-aware applications like Smart banking, smart office, and Smart classroom and so on. This Context Middleware works based on the user Input and is capable of providing the best service to the user request based on the context.

Ke ywor ds: Conte xt, Conte xt-aware , Conte xt Mi ddle ware , autonomous, adaptable .

I. Introduction

Conte xt awa reness has attracted a lot of attention in recent years, especially in the realms of mobile and ubiquitous computing. Systems that utilize informat ion about the situation of its users, the environment, or the state of the system itself to adapt their behavior are called context -aware systems [1, 2]. Typica lly, such systems are also self- adaptive in the sense that they can dynamica lly adapt as a response to changes in the execution conte xt. Conte xt manage ment in ubiquitous computing environments must reflect the specific characteristics of these environments, e.g. distribution, mob ility, dynamic discovery of context sources, and heterogeneity of context informat ion. In order to ease the development of context-awa re self-adaptive applications, that utilize the full potential of such environments, the developer should be able to transparently access context informat ion without bothering with the underlying context accessing techniques and the distribution aspects. A context-awa re application reacts to the situation and adjusts their actions and presents related services by ma king the interactions

between humans and computers easier depending on the context.

Context-a wareness (or context sensitivity) is an application software systems ability to sense and analyze context fro m various sources; it lets application software take diffe rent actions adaptively in different contexts [3]. By using middlewa re for context-awa reness, there will be huge benefits include reduced development times of context-awa re applications and great ease in specifying comple x behaviors of these applications. Context-a ware middlewa re provides an easy way for developers to specify the way in which an environment should automatically respond to different contexts. Developers do not have to worry about the details of getting contextual informat ion fro m different sources or the mechanics of triggering different actions in diffe rent situations. Middleware for conte xt- awareness would allow autonomous, heterogeneous agents to seamlessly interact with one another.

    1. What is context?

      Conte xt is any informat ion that can be used to characterize 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 [2].The three aspects of context like (1)where you are; (2) who you are with; and (3) what resources are nearby by configuring sensors, devices, user and associating set of rules among them[4].

      Conte xt plays an important role in developing intelligent applications in ubiquitous computing environments. Not satisfied by a general defin ition, many researchers have attempted to define context which has the meaning related to computer environment [5], [6], [7], [8].

      Schilit and Theimer (1994) refe r to context as location, identities of nearby people and objects and changes to those objects [9]. In a similar way, Bro wn, Bovey, and Chen (1997) define context as location, identities of the people around the user, the time of day, season, temperature, etc [10]. Ryan, Pascoe, and Morse (1997) define context as the users location, environ ment, identity, and time [11].

    2. Context-Awareness in Ubicomp Environments

      In ubiCo mp environ ments, context- awareness plays an important role in smart services autonomously reacting to context. This context is generated by sensing the change or situation of users and environments and by extracting the needs of users.

      In general, conte xt-a wareness refers to the idea that applications can understand their context and adapt their behavior based on informat ion gathered from the environment without an explic it user intervention. Thus, it aims to increas e usability and effectiveness of applications. Most importantly, this dynamic adaptation aspect can provide context-awa re applications with a degree of autonomy.

    3. Context-Aware Computing

      In ubiCo mp domain many definit ions for context-awa reness have been conceived. Schilt and Theimer (1994) firstly referred context-awa re co mputing to be software that adapts to its location of use, the collection of nearby people and objects, as well as changes to those objects over time [12]. Then, definit ions of context-aware co mputing fa lls into two categories: using context and adapting to context. This requires a context- aware system to detect, interpret and respond to the context. There are no generic context middle ware suits for all types of application [13].

    4. Context-Aware Smart Home Applications Example

      Recently, context-a ware applicat ions have actively been developed in ubiCo mp. In th is paper, we introduce the Five Generic conte xts as Location, Time, User, Dev ice and Environment and the imple mented context- aware applications is sma rt home . For e xa mple the smart home environ ment context focus on controlling home appliances or adjusting residential conditions such as lighting, te mperature, and humidity by using context.

      Scenarios make it easy for people saving the list of action for further use, in addition to

      design multip le actions to be done in a single scenario application [14].

      1. Categories of Context

        1. Location conte xt

        2. Time context

        3. Device conte xt

        4. User context

        5. Env iron ment context

            1. Context Categories for Smart Home

              The Conte xt Categories are Location, Time , Device, User and Environ ment. The location context class includes location name, present location and changed location as attributes and to find location as method. The Time context class includes Am and Pm as attributes and to set and reset the time as methods. The Device conte xt c lass includes lights, tv and alarm as attributes and to get the device as methods. The User context class includes the activity of the user such as cooking and sleeping as attributes and to find the user activity as methods. The Environment context class includes temperature and lght as attributes and to find the environment as methods as shown in fig 1.

              Fig 1: Context Categories for Smart Home

              location context class includes living room, kitchen, reading room and bathroom. The time context c lass includes early morning and noon. The device context class includes lights, alarm and tv. The user context class includes the activity of the user as cooking and sleeping. Then finally the environment context class includes temperature and light as shown in fig 2.

              Fig 2: Five Cont ext Categories wit h Their Specified Cont ext for Smart Hom e

      2. Working Model of Generic Context Middleware for Smart Home Application

        Steps for imple ment ing Smart ho me Application,

        Step 1: Enter the Input scenario for s mart Ho me Application, Scenario: if \user/ rela xing in living roo m turn light on. This scenario is the input given to the Generic conte xt Middlewa re. Simila rly a ll the possible scenarios are given as input to the Context Middlewa re as shown in fig 3.

          1. Five Context Categories with Their Specified Context for Smart Home

        The c lass diagram for the Smart Ho me application consists of five general contexts as Location, Time, Dev ice, User and Environment context and the attributes and methods are to be specified in the general context. For a smart ho me application the

        ep 2: Generate XM L Representation for the put scenario.

        St

        in Fig 3: Entering the input scenario

        In this step from the given input scenario the Generic Conte xt Middlewa re splits the context and generates the XML Representation for the given scenario as shown in the fig 4.

        Fig 4: Generating the xml representation

        Step 3: Save the XM L Representation in the database for future use.

        In this step the generated XML Representation is stored in the database and it is used for future use. If the same smart ho me scenario is given as the input and the XML Representation is again stored in the database the Generic Conte xt Middle ware shows that the data already exist in the database so to save the working time , first check the database that the data already exists or not if e xists the same data is to be reused as shown in the fig 5.

        Step 4: Retrieve the XM L file in the database

        Fig 5: Storing the Xml Representation to the

        and show the data.

        In this step the saved XML file is retrieved fro m the database to show the fast retrieval of context data as shown in the fig 6.

        Fig 6: Retrieve the XML file

        Step 5: open the Xml file in Internet Explore r to view the files.

        In this step we can also view the database file not only from the database but also in Internet Exp lorer also as shown in the fig 7.

        Fig 7: viewing the XML file in Internet Explorer

        Step 6: Store new device context in the Generic Conte xt M iddlewa re

        In this step we can add more number of context such as location context, Time context, device context, User context and Environment conte xt in our Generic Conte xt

        Middlewa re. Here the new device context added as shown in the fig 8.

        is

        www.ijert.org 4

        Vol. 1 Issue 3, May – 2012

        Fig 10: provide authentication

        Fig 8: Store new device context.

        Step7: The new device conte xt data is updated.

        In this step the new device context data is

        updated in the database as shown in the fig 9.

        Fig 9: New device context data is updated

        Step 8: To provide authentication.

        In this step by proving the authentication of user name and password we can view the data in the Generic Context Middle ware as shown in the fig 10.

        Step 9: To vie w data in the database.

        In this step we can view the data in the database and to view all stored XML files as shown in the fig 11.

        Fig 11: To view data in the database

        Step10: To de lete any context in the database. In this step we can delete any number of context in the database e.g. delete corridor it

        is deleted successfully as shown in the fig 12.

        Fig 12: Deleting any context in the database

        Step 11: To vie w the XM L files for Smart Ho me Applicat ion.

        In this step we can view all stored XML files as shown in the fig 13.

        Fig 13: View all XML files

        Step 12: open the xml file of 003.xml

        In this step from the stored XML files we can open the file na med 003.xml and it is opened in the Internet Exp lore r as shown in the fig 14.

        Fig 14: open the xml file

      3. Conclusion

        This paper worked on imp le menting the sample Conte xt-a ware application smart Ho me with the fo llo wing Working Model steps imple mented in the Generic Conte xt Middlewa re. Simila rly the Generic Conte xt Middlewa re imp le mented is adaptable for diffe rent Conte xt-awa re applications such as Smart banking, smart office, and Smart classroom and so on.

      4. References

[1] B. Schilit, N. Adams & R. Want, Context – aware computing applications, Proceedings of the Workshop on M obile Computing Systems and Applications, Santa Cruz, CA, USA, pp. 85-90, 1994.

[2]A. Dey, Understanding and Using Context, Personal and Ubiquitous Computing, Vol. 5, 1, pp. 4-7,2001.

  1. Yau, S., et al, Reconfigurable Context-

    Sensitive M iddleware for Pervasive Computing. In IEEE Pervasive Computing, pp. 33-40, July- Sept 2002.

  2. Thyagaraju.GS, Umakanth P.Kulkarni, Design and Implementation of Context Program Compiler for developing Context Aware Applications in Pervasive Computing Environment, International Journal of Soft Computing and Engineering (IJSCE) ISSN: 2231- 2307, Volume-1, Issue-4, September 2011.

  3. Bill Schilit, Norman Adams, and Roy Want. Context-aware computing applications. In IEEE Workshop on M obile Computing Systems and Applications, Santa Cruz, CA, US, 1994

  4. Anind K. Dey and Gregory D. Abowd.

    Towards a Better Understanding of context and context-awareness. Technical Report GIT-GVU- 99-22, Georgia Institute of Technology, College of Computing, June 1999.

  5. A. Schmidt and M . Beigl. There is more to

    context than location: Environment sensing technologies for adaptive mobile user interfaces, 1998.

  6. Guanling Chen and David Kotz. A survey of context-aware mobile computing research. Technical Report TR2000-381, Dartmouth College, Computer Science, Hanover, NH, Nov 2000.

  7. B.N. Schilit, I.A. Norman and R. Want , Context-aware computing applications, In the Proceedings of the 1st International Workshop on Mobile Computing Systems and Applications, pp. 85-90, Santa Cruz, CA, IEEE. December 8-9 (1994)

  8. P.J. Brown, D.B. John and X. Chen, Context- aware applications: From the laboratory

    to the marketplace, IEEE Personal Communications 4(5): pp. 58-64. (1997)

  9. N.Ryan, J. Pascoe and D. Morse, Enhanced reality fieldwork: the context-aware

    archaeological assistant, Computer Applications and Quantitative M ethods in

    Archaeology. V. Gaffney, M . van Leusen and S. Exxon, Editors. Oxford.

  10. B.N. Schilit, and M .M . Theimer,

    Disseminating active map information to mobile hosts, IEEE Network 8(5): pp. 22-32. September/October (1994).

  11. Soma Bandyopadhyay, M unmun Sengupta, Souvik M aiti, and Subhajit Dutta, A Survey of M iddleware for Internet of Things,2011

  12. Zahra Forootan Jahromi and Amir Rajabzadeh, Ali Reza M anashty, A M ulti-Purpose Scenario-based Simulator for Smart House Environments,2011

Leave a Reply