Presentation is loading. Please wait.

Presentation is loading. Please wait.

Implementing Context Aware Applications Class 5. Agenda Review of TinyOS execution model Tutorial on TinyOS Code walk through Code quiz Assignment 2.

Similar presentations


Presentation on theme: "Implementing Context Aware Applications Class 5. Agenda Review of TinyOS execution model Tutorial on TinyOS Code walk through Code quiz Assignment 2."— Presentation transcript:

1 Implementing Context Aware Applications Class 5

2 Agenda Review of TinyOS execution model Tutorial on TinyOS Code walk through Code quiz Assignment 2

3 Tiny OS Concepts Scheduler + Graph of Components  constrained two-level scheduling model: threads + events Component:  Commands,  Event Handlers  Frame (storage)  Tasks (concurrency) Constrained Storage Model  frame per component, shared stack, no heap Very lean multithreading Efficient Layering Messaging Component init Power(mode) TX_packet(buf) TX_packet _done (success) RX_packet_ done (buffer) Internal State init power(mode) send_msg (addr, type, data) msg_rec(type, data) msg_sen d_done) internal thread Commands Events

4 commands request action  ack/nack at every boundary  call cmd or post task events notify occurrence  HW intrpt at lowest level  may signal events  call cmds  post tasks Tasks provide logical concurrency  preempted by events Migration of HW/SW boundary TOS Execution Model RFM Radio byte Radio Packet bit byte packet event-driven bit-pump event-driven byte-pump event-driven packet-pump message-event driven active message application comp encode/decode crc data processing

5 Hardware Abstraction Architecture for TinyOS 2.x Combine the component model with a flexible, three-tier organization of the hardware abstraction HW platform 2 HPL 2 HAL 2 HIL 2 HW platform 3 HPL 3 HAL 3 HIL 3 HW platform 1 HPL 1 HAL 1 HIL 1 HW platform 4 HPL 4 HAL 4 HIL 4 Platform-specific applications Platform-specific applications Cross-platform applications Platform-independent hardware interface HW/SW boundary Hardware independence

6 TinyOS Tutorial


Download ppt "Implementing Context Aware Applications Class 5. Agenda Review of TinyOS execution model Tutorial on TinyOS Code walk through Code quiz Assignment 2."

Similar presentations


Ads by Google