1 / 52

Middleware for Sensor Network

Middleware for Sensor Network. ECE1770 Trends in Middleware Systems Prepared by Mi Li and Tony Lee. Agenda. 1. Introduction of Sensor Network 1.1 Application Examples 1.2 Sensor Network Architecture 1.3 Hardware and Software 1.4 Sensor Network's Features

Anita
Download Presentation

Middleware for Sensor Network

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Middleware for Sensor Network ECE1770 Trends in Middleware Systems Prepared by Mi Li and Tony Lee

  2. Agenda 1. Introduction of Sensor Network 1.1 Application Examples 1.2 Sensor Network Architecture 1.3 Hardware and Software 1.4 Sensor Network's Features 2. Middleware for Sensor Network. 2.1Why do we need Middleware for SN? 2.2 Challenges in designing middleware. 2.3 Middleware approaches for SN. 2.4 Example: Mires, A Message-Oriented Middleware

  3. 1.1 Application Examples • Military applications: • target detection • battlefield surveillance • nuclear, biological and chemical attack detection etc. • Enviromental applications: • forest fire detection • flood detection • structure monitoring • Health applications • monitor human physiological data • drug administration

  4. Agenda 1. Introduction of Sensor Network 1.1 Application Examples 1.2 Sensor Network Architecture 1.3 Hardware and Software 1.4 Sensor Network's Features 2. Middleware for Sensor Network. 2.1Why do we need Middleware for SN? 2.2 Challenges in designing middleware. 2.3 Middleware approaches for SN. 2.4 Example: Mires, A Message-Oriented Middleware

  5. 1.2 Sensor Network Architecture • Sensor Nodes:sense target events, gather sensor readings, manipulate informations, send them to gateway via radio link • Base station/sink: communicate with sensor nodes and user/operator, (database-stores the data) • Operator/user: task manager, send query

  6. 1.2 Sensor Network Architecutre cont. Task Management Plane Mobility Management Plane Application Layer Transport Layer Power Management Plane Network Layer Data Link Layer Application Layer: middleware, OS Network Layer: Routing Physical Layer

  7. 1.2 Sensor Network Architecture-Routing • State of the art routing protocols are distributed and reactive : the systems start looking for a route only when they have application data to transmit • We study here Ad hoc On demand Distance Vector (AODV) and Dynamic Source Routing (DSR) for the sensor network

  8. 1.2 Sensor Network Architecture-Routing cont. • Route Discovery A node sends a Route Request message to all of its neighbours. Any node receiving such a request, either answers to it or rebroadcasts it. The procedure finishes either when the request sender has received the route information, or when the request times out. • With AODV, each node remembers the next hop information associated with the destination. The route knowledge itself is distributed in the network. • With DSR, the complete route is sent to the route requester. • Message transmission • With AODV, the message is sent to the next hop as recorded in the routing table, and this procedure is repeated at each hop. • With DSR, the message is sent with its complete route as header.

  9. 1.2 Sensor Network Architecture- Routing cont. • Rumor Routing • "Rumor Routing Algorithm for Sensor Network" by Braginsky and Estrin • How to make information available in a sensor network • Assumption: sense particular eventt when requested, don't know the existence or the location of the event

  10. 1.2 Sensor Network Architecture- Routing cont. • An event sends out agents which travel the network from node to node on a random path.Each visit leaves information about the event in the node's database. After a predefined TTL the agent stops • A requester also sends out an agent. After some time it will hopefully come across the path of the information agent by checking the node's databases. It can then travel the backward references the first agents left in the nodes to reach the event.

  11. 1.2 Sensor Network Architecture- Routing cont. • Critical review + Only a small number of nodes have to adopt the same information + Only a small number of nodes have to process the request When or whether requested information can be delivered is a random process. - The failure of nodes can interrupt the path to the event (depending on how broad it is). - The actual behavior of a node is very different from what is shown in the former slides

  12. Agenda 1. Introduction of Sensor Network 1.1 Application Examples 1.2 Sensor Network Architecture 1.3 Hardware and Software 1.4 Sensor Network's Features 2. Middleware for Sensor Network. 2.1Why do we need Middleware for SN? 2.2 Challenges in designing middleware. 2.3 Middleware approaches for SN. 2.4 Example: Mires, A Message-Oriented Middleware

  13. 1.3 Hardware- Sensor Nodes • Sensing: sensor --a transducer that converts a physical, chemical, or biological parameter into an electrical signal • Processing: microprocessor(CPU) data storage(Mem) AD converter • Communicating: data transceiver(Radio), • Energy source: battery

  14. Hardware- Sensor Nodes cont.

  15. Hardware – Sensor Nodes cont.

  16. Hardware- Sensor Nodes cont.

  17. Hardware – Sensor Nodes cont. Characteristics of Sensor Nodes • Limited capacity of • Battery (Lifetime: day - 10 years) • Processing capabilities (10MHz) • Transmission range (5 - 20 meters) • Data rates: Bit/s - KB/s • Transmission methods: • 802.11 (WiFi) • Bluetooth – short distance, other applications • ZigBee – for sensor network • Price: some cents

  18. Software-Operating System • Sensor Manager • provides access to the sensors • manage the delivery of sensor data • provides and manages the resources provided to a sensor

  19. Storage persistent storage for data streams Software-Operation System cont.

  20. Query Manager manages active queries query processing delivery of events and query results to registered, local or remote consumers Software-Operating System cont.

  21. Software-Operation System cont. • Top layer: access control and integrity service • OS examples: • TinyOS: when an event occurs, it calls the appropriate event handler to handle the event. • Others: Contiki, MANTIS, and SOS.

  22. Create Hardware-optimized software components (driver, operating system ) Create hardware- independent software components (middleware, services) Combining of predefined components Source code generation Removing unused components Optimizaion of interface Optimizaion to node's hardware Distribution of nodes in different environments Monitoring the execution Creation of logfiles Evaluation of logfiles Components Design & Edit Resource Hardware driven Complie/Link Distribute Execute/Administrate Monitoring Evaluation Optimization Software Design

  23. Agenda 1. Introduction of Sensor Network 1.1 Application Examples 1.2 Sensor Network Architecture 1.3 Hardware and Software 1.4 Sensor Network's Features 2. Middleware for Sensor Network. 2.1Why do we need Middleware for SN? 2.2 Challenges in designing middleware. 2.3 Middleware approaches for SN. 2.4 Example: Mires, A Message-Oriented Middleware

  24. 1.4 Sensor Network's features • Restricted Resources: energy, computing power, memory, and communication bandwidth • Network Dynamics: node mobility, environmental obstructions, hardware failures • Scale of Deployments: thousands or millions of nodes

  25. Sensor Network's features cont. • Real-world intergation: seperation of events in time and space and correlate information from multiple sources • Collection and Processing of Sensor Data: preprocess data at the source • e.g. smart sensor ( IEEE 1451 ) • Integration with Background Infrastructures: tasking the sensor network, and provide resources (eg. computing power)

  26. Agenda 1. Introduction of Sensor Network 1.1 Application Examples 1.2 Sensor Network Architecture 1.3 Hardware and Software 1.4 Sensor Network's Features 2. Middleware for Sensor Network. 2.1Why do we need Middleware for SN? 2.2 Challenges in designing middleware. 2.3 Middleware approaches for SN. 2.4 Example: Mires, A Message-Oriented Middleware

  27. 2.1 Why do we need Middleware for WSN? • What is it? • A software infrastructure that glues together the network hardware, operating systems, network stacks, and applications. • Role • Provide standardized system services to diverse applications. • Provide a runtime environment that can support and coordinate multiple applications. • Provide mechanisms to achieve adaptive and efficient utilization of system resources.

  28. Compare with other middlewares. • Traditional middleware systems • Normally heavyweight in terms of memory and computation and therefore not suitable for SNs. • Java RMI (Remote Method Invocation) • EJB (Enterprise JavaBeans) • CORBA (Common Object Request Broker Architecture) • A middleware for WSN should facilitate development, maintenance, deployment and execution of sensing-based applications.

  29. Agenda 1. Introduction of Sensor Network 1.1 Application Examples 1.2 Sensor Network Architecture 1.3 Hardware and Software 1.4 Sensor Network's Features 2. Middleware for Sensor Network. 2.1Why do we need Middleware for SN? 2.2 Challenges in designing middleware. 2.3 Middleware approaches for SN. 2.4 Example: Mires, A Message-Oriented Middleware

  30. Challenges in designing middleware. • Limited power and resources. • Advance microelectronics technology allows tiny devices but limited in energy and resources, i.e. CPU and memory. • Middleware should provide mechanisms for efficient processor and memory use while enabling lower-power communication and prolong sensor node lifetime. i.e. sleep mode, minimize number of transmission. • Scalability, mobility, and dynamic network topology. • As the application grows, device failure, moving obstacles, mobility, and interference, the network will change frequently. • Middleware should maintain performance and robust operation while network changes dynamically. Also, It should support mechanisms for fault tolerance and sensor node self-configuration and self-maintenance. • Heterogeneity. • CPU-power, networking, memory and storage, operating systems. • Middleware should able to interface various kinds of hardware, software and networks. • Dynamic network organization. • In most situation, Client/Server mode is impossible, no infrastructure is not available. • Middleware should support Ad-hoc capability to discover resource and its location which affect the trade-offs among latency, reliability, and energy.

  31. Challenges in designing middleware. • Real-world integration. • Most of the applications are dealing with real-time phenomena. • Middleware should provide real-time services. • Application knowledge. • Developer would like to inject application knowledge to the network so as to map application communication requirements to it, • Middleware design should balance between application specificity and middleware generality. • Data aggregation. • Network generate lots of redundant data, communications cost is much higher than computational cost. Sending a single bit can consume the same energy as executing 1000 instructions • Middleware should able to aggregate data to eliminate redundancy and minimize the number of transmissions to the sink. • Security. • Middleware efforts should concentrate on developing and integrating security in the initial phases of software design, hence achieving different security requirements such as authentication, integrity, freshness, and availability.

  32. Agenda 1. Introduction of Sensor Network 1.1 Application Examples 1.2 Sensor Network Architecture 1.3 Hardware and Software 1.4 Sensor Network's Features 2. Middleware for Sensor Network. 2.1Why do we need Middleware for SN? 2.2 Challenges in designing middleware. 2.3 Middleware approaches for SN. 2.4 Example: Mires, A Message-Oriented Middleware

  33. Middleware approaches for WSN. • Virtual Machine (Cluster-Based) • Because of its similarity to the virtual machine concept in traditional distributed systems in terms of providing application semantic transparency from the physical infrastructure. • Pros: • Common abstraction. • Sand-boxing. • Cons: • High overhead • Difficult to exploit heterogeneity. • Example 1 - Maté: • Power-centric abstraction. • Tied to TinyOS. • Broken up into 24 byte-long instruction capsules, easy for distribution. • Provide simple programming interface to sensor nodes. i.e. 6 instructions only for sense and send program. • Communication in synchronous, less complex in programming. • No support for message buffering / large storage.

  34. Middleware approaches for WSN. • Example 2, MagnetOS: • Power-aware, adaptive OS. • The whole network appears as a single JVM. • Standard Java programs are re-written by MAGNET as network components. • Components may then be ‘injected’ into the network using a power-optimized scheme.

  35. Middleware approaches for WSN. • Mobile Agents (Modular programming) • Pros: • Only parts of the program need to be updated, propagate efficiently. • Cons: • High overhead, Doesn’t allow hardware heterogeneity. • Example: • IMPALA • As modular as possible, efficiency of updates and support dynamic applications. • The nature of its code instruction doesn't allow hardware heterogeneity. • Application Adaption with different profiles possible. (energy efficient) • Use in the ZebraNet project (wildlife monitoring).

  36. Middleware approaches for WSN. • Database • Pros: • Entire sensor network is abstracted as a virtual relational database. Ease to interoperate with existing systems. • Cons: • Doesn’t support real-time applications, and provides only approximate results. • Example: • Cougar • Represents all sensors and sensor data in a relational database. • Control of sensors and extracting data occurs through special SQL-like queries. • Allows the scheduling of ongoing queries that provide incremental results. • Decentralized Implementation, message passing based on controlled flooding. • SINA (System Information Networking Architecture) • Based on a spreadsheet database, wherein network is a collection of data-sheets and cells are attributes. • Attribute-based naming, e.g. [type=temperature, location=N-E, temperature=50]. • Queries again performed in an SQL-like language. • Decentralized Implementation based on clustering.

  37. Middleware approaches for WSN. • Message Oriented • Pros: • Use Publish-subscribe to support asynchronous communication, allowing a loose coupling between the sender and the receiver • Cons: • Overhead • Example: • MIRES • Publish-subscribe • Multi-Hop Routing • Additional Service (e.g. data Aggregation) • Sense – advertise over P/S and route to Sink.

  38. Agenda 1. Introduction of Sensor Network 1.1 Application Examples 1.2 Sensor Network Architecture 1.3 Hardware and Software 1.4 Sensor Network's Features 2. Middleware for Sensor Network. 2.1Why do we need Middleware for SN? 2.2 Challenges in designing middleware. 2.3 Middleware approaches for SN. 2.4 Example: Mires, A Message-Oriented Middleware

  39. A Message-Oriented Middleware for Sensor Networks - Mires • In general, it facilitates the development of network-applications over the WSN and providing common application services. • Problem: Thousands of sensor nodes and redundant data. Low availability of resources and processing capacity of the sensor nodes. • How does it help: Message-oriented which aggregate data, Multi-Hop routing and greatly reduce the among of transmissions, save lots of energy.

  40. Traditional request/response approach is not suitable for event-driven communication model. Publish/subscribe approach is used to query and extract data from the network. • In applications: Use in habitat monitoring, object tracking, precision agriculture, building monitoring and military systems.

  41. MIRES Architecture • Publish/Subscribe service • communication between middleware services. • Advertising the topics available. • Maintaining the list of topics subscribed by the node application • Publishing messages. • Routing • Multi-hop routing to the Sink • 3 types of notification events: • TopicArrival, • event signals that the node application has submitted data collected from sensors. • StateArrival • Event signals that data received from the network. • TopicSetupArrival • the subscribe message broadcasted from the user application.

  42. Publish/Subscribe Service • PublishState interface define the command used by ServiceX to publish their processing results. • Notifier interface defines 3 events • MultiHopRouter-route to the sink • BCast-Boardcast Setup info.

  43. Topic advertisement sequence diagram

  44. Topic subscription sequence diagram

  45. Data publishing sequence diagram

  46. An Environment-monitoring application example Temperature, humidity, sound and luminosity sensors Cluster Head Cluster Sink

  47. Graphical User Interface Example

  48. Conclusions • Sensor Network can be used in many applications, such as Military, Environmental and Health…etc. • Its characteristics are tiny node, low power, limited resources, dynamic network topology and various scales of network deployment. • Middleware is used to connect the network hardware, operating systems, network stacks, and applications in different approaches. • For examples, Virtual Machine, Mobile Agent, Database and Message Oriented.

More Related