CS 240E: Embedded Wireless Systems

Spring Quarter, 2014
Wed 3:15-5:05, 200-034
Instructor: Philip Levis
  • Office hours: Mon. 2-3, Gates 412
  • TA: Shantanu Joshi
  • Office hours: TueTh 4-6, Gates B26A

  • CS 240E is an introduction to embedded wireless systems. It assumes a basic background in networking and systems software. CS110 (or equivalent) is a prerequisite, CS140 is recommended (but not required).

    The class meets once weekly, on Wednesdays. Class time is split into two halves. In the first half of class will cover engineering fundamentals in embedded systems. This part of the class will ground the ideas we read about in current technology. For students with more of an application background, this part will explain how the systems in question work and their engineering tradeoffs. For example, when we cover hardware platforms, it will not only explain the devices we're using in class but also devices like the Nest thermostate, Fitbit, and Up.

    The second half will cover 1-2 research papers. Students are expected to have read the papers before class and to participate in discussion. 1-2 students will be assigned to help lead the discussion. This discussion is not solely a factual presention of the paper, but also interpretation and opinions of the work. For example, preparation should consider prior and later work. The goal is that the presenting student reads the paper deeply, places it in the context of the broader research literature, and presents his or her own thoughts. Students who are not helping in presenting also read the paper; class is an open discussion.

    The beginning of the quarter will have lab sessions to help you get up to speed on either the Intel Galileo (Arduino) or TMote (TinyOS) embedded platforms. There will be one programming assignment to keep everyone on track to implement a new idea in their research project. We'll settle on the the exact dates and times based on student schedules.

    While not officially listed as an equivalent EE 300-level class, its research component means I'll sign petitions to that effect.


    Date Fundamentals Reading Assignment
    4/2 Overview of embedded systems, their hardware, hardware/software interface, energy vs. power, and networking No papers; short presentations on Telos/TinyOS and Galileo/Arduino
    4/9 Microcontrollers vs. processors; MSP430, AVR, ARM A* and Cortex M*, sensors, wireless, duty cycling, flash vs. RAM, Harvard architectures, memory mapped I/O, one-wire, I2C, SPI, UART, GPIO, ADC Telos and Epic
    4/16 Threads and events; hardware considerations, programming models, state management, RAM needs, continuations, tasks, protothreads, fibers, finite state machines Events, Threads, and TOSThreads Project pre-proposal
    4/23 Energy and power; batteries, sleep current, wakeup latency, triggers, relative power costs and lifetime breakdown, circuit design, clocks, harvesting, markets vs. fundamentals CargoNet, drivers Project proposal
    4/30 Applications; personal versus environmental sensing, successes and failures, hardware specialization, physical considerations, scale Steam, Static, H1N1
    5/7 Storage; EEPROM, NOR/NAND flash, [PFM]RAM, blocks, pages, erase, wear-leveling, log structured storage, abstractions, delay tolerance, indexing Capsule, StonesDB Project presentation
    5/14 Sensing; energy considerations, data rates, buffering, spatial vs. temporal density, noise, modeling ExaScale, BBQ
    5/21 Networking; physical layer model, symbols, multipath, LQI/RSSI, channel hopping, FEC, link layer, addressing, acknowledgements, routing, queueing, reliability Bus, IP
    5/28 Programming Models; isolation/safety, data centric, databases, scripting, macroprogramming, frameworks, Android Wear 2 of TinyDB, MacroLab, Céu, SNACK
    6/4 No class Project paper


    Course grades will be split evenly between participation in class (presentation, discussion) and the final project. An initial programming assignment is worth approximately 10\% of your final grade (a letter grade).

    There are two initial programming assignments, depending on whether you wish to use TinyOS or Arduino:

    Both are due at the end of the second week of class. Send your source code to Shantanu and Phil. You must work individually.

    Research projects last over the entire quarter. Projects may range from low-level systems research to a new application or software service. Projects involve running code directly on embedded system hardware. Students can choose to use either Arduino-based Intel Galileo devices (for applications and simple services) or TinyOS-based TMote devices (for systems and protocols). Students who do not have an ongoing research project should talk with the instructors in the first week to discuss and decide on their project. There are four major milestones in the project:

    1. a short presentation to the class mid-quarter on the problem and approach,
    2. a 3-4 paper describing the problem and approach due mid-quarter,
    3. a short presentation to the class at the end of the quarter showing results
    4. a 6-10 page paper in conference proceedings format describing the project results.

    Students will join the instructors in reading and reviewing assignment 2, focusing on constructive feedback to the authors.

    Some project ideas:

    • Design and implement hardware-independent DAC/PWM interfaces
    • Confidential storage that offloads encryption to a radio module
    • A general storage layer for non-volatile data structures, which would allow packet queues, routing tables, and other important information to exist across complete power-downs and relieve RAM pressure.
    • A network link manager that provides quality of service or other guarantees to competing packet streams
    • Design and implement expressive yet efficient abstraction for BTLE
    • A declarative macroprogramming language that enables efficient yet simple programs for a selected application domain
    • An analysis of data retention/buffering strategies for applications and defining a set of core primitives for delay-tolerant embedded communication with limited storage
    • A on-node storage system that can efficiently index complex data traces, such as neural traces, object movement, or home energy use.
    • A event-driven programming model for novice programmers (e.g., Arduino-level)
    • A library/framework for commands and processing on a centralized server to reliably manipulate what an embedded device displays
    • A distributed model-view-controller architecture for embedded applications that integrate with phones.
    • A set of libraries and services that enable simple management and control of a personal area network from a phone
    • Integrating Arduino with Android Wear
    • Use Microsoft Kinect (or Myo) to recognise gestures and communicate them to Galileo , this can be used for applications like home automation.
    • Wearable wireless Biometric sensor to keep tabs on an individuals vital signs with anomaly detection.
    • Connect the Galileo to appropriate sensors of your choice and create your own home surveillance system
    • Build an adaptive cruise control system for a toy car




    Threads and events

    Energy and power