TinyOS 2.0 Tutorials
Last updated 14 Jun 2006
These brief tutorials are intended to get you started with TinyOS. They show you the basics of writing, compiling, and installing TinyOS applications. They introduce the basic TinyOS abstractions: computation, communication, sensing, and storage. The later tutorials go a little deeper into some of the more advanced areas of TinyOS, such as handling interrupts, power management, and how platforms are organized. For the beta2 release, only tutorials 1-5 are ready.

Lesson 1: TinyOS

Lesson 1 introduces the major concepts of TinyOS: components, modules, configurations and interfaces. It shows you how to compile and install a TinyOS program on a mote.

Lesson 2: Modules and the TinyOS Execution Model

Lesson 2 explains the TinyOS execution model, looking more closely at modules. It explains events, commands and their relationships to interfaces in greater depth, introducing split-phase operations. It explains tasks, the basic mechanism in TinyOS for components to cooperatively share the processor.

Lesson 3: Mote-mote radio communication

Lesson 3 introduces the TinyOS communication model. There is an exercise that illustrates sending and receiving messages.

Lesson 4: Mote-PC serial communication and SerialForwarder

Lesson 4 introduces the the TinyOS toolchain for PCs and laptops to communicate with motes. It describes the concept of a packet source, the mig tool, and SerialForwarder.

Lesson 5: Sensing

Lesson 5 explains how to sample sensors in TinyOS. There is an exercise that periodically samples a sensor and displays the value on the leds.

Lesson 6: Boot Sequence

Lesson 6 details the boot sequence and, in doing so, answers the question, "But where is main()?".

Lesson 7: Storage

Lesson 7 introduces the TinyOS model model. A sample application illustrates storing data.

Lesson 8: Power Management

Lesson 8 introduces the TinyOS power management model. There is an exercise that illustrates how to turn components on and off.

Lesson 9: Concurrency

Lesson 9 introduces the TinyOS concurrency model. Tasks are revisited and async code is introduced.

Lesson 10: Platforms

- chips vs. platforms - Telescoping abstractions - Sensorboards

Lesson 11: TOSSIM

Lesson 11 introduces TOSSIM, a TinyOS simulator. TOSSIM allows you to compile your TinyOS applications into a simulation framework, where you can perform reproducible tests and debug your code with standard development tools.