200 likes | 373 Views
Development of a Mica2 Mote Sensor Network. Cliff Macklin Bill Ehrbar December 8, 2004. University of Colorado, Colorado Springs. Introduction. nesC TinyOS Hardware Applications Architecture Building Blocks Blink Application Architecture Overview.
E N D
Development of a Mica2 Mote Sensor Network Cliff Macklin Bill Ehrbar December 8, 2004 University of Colorado, Colorado Springs
Introduction • nesC • TinyOS • Hardware • Applications • Architecture Building Blocks • Blink Application Architecture • Overview University of Colorado, Colorado Springs
nesC • Event Driven Language • Separation of construction and composition • Specification of component behavior in terms of set of interfaces which are bidirectional • Components are statically linked to each other via their interfaces University of Colorado, Colorado Springs
TinyOS • Designed for sensor networks that have very limited resources • Allows for concurrency management • TinyOS executes only one program consisting of selected system components and custom components needed for a single application University of Colorado, Colorado Springs
Hardware Our research used the following components MIB510 Programming Bd. MPR400CB Sensor Bd. MTS300 Sensor University of Colorado, Colorado Springs
Hardware Continued • 422 Mhz processor • 512 KB of memory • Sensor contained Buzzer, Light, Microphone, Magnetometer, and Thermistor University of Colorado, Colorado Springs
Applications for a Sensor Network • Means of providing critical information in disaster environments • Light, temperature, and soil conditions within a green house • Frost detection and warning • Indoor comfort monitoring, including HVAC tune-up • Security applications University of Colorado, Colorado Springs
Application SW Architecture • Modular Approach • Somewhat Object Oriented • Object abstraction • Layered “inheritance” approach • Similar to an HDL in structure (VHDL, Verilog, etc.) • Wired interfaces • Bi-directional interfaces University of Colorado, Colorado Springs
Application Building Blocks • Interface Description (Module & Configuration files) Sample configuration file: configuration Blink {} implementation { components Main, BlinkM, SingleTimer, LedsC; Main.StdControl -> SingleTimer.StdControl; Main.StdControl -> BlinkM.StdControl; BlinkM.Timer -> SingleTimer.Timer; BlinkM.Leds -> LedsC; } • Implementation (Module files) University of Colorado, Colorado Springs
Application Building Blocks Sample module file: module BlinkM { provides { interface StdControl; } uses { interface Timer; interface Leds; } } implementation { /**ACTUAL INSTRUCTIONS HERE **/ } University of Colorado, Colorado Springs
Application Building Blocks Sample module file implementation excerpt: /** Initialize the component. **/ command result_t StdControl.init() { call Leds.init(); return SUCCESS; } /** Start things up. This just sets the rate for the clock component. **/ command result_t StdControl.start() { // Start a repeating timer that fires every 1000ms return call Timer.start(TIMER_REPEAT, 1000); } … /** Toggle the red LED in response to the <code>Timer.fired</code> event. **/ event result_t Timer.fired() { call Leds.redToggle(); return SUCCESS; } University of Colorado, Colorado Springs
Blink Application Architecture University of Colorado, Colorado Springs
Wireless Applications Overview • Active Messaging Model • Simple message structure • Assigned handler by message ID • Handled completely by handler • Zero Copy Stack for memory and speed efficiency • Range limitations can be overcome with multi-hop configuration University of Colorado, Colorado Springs
Sensor Network Limitations • Power Management • Memory Limitations • Mote Failure and Run-Time Errors • Security University of Colorado, Colorado Springs
References • D. Gay, P. Levis, D. Culler, E. Brewer. nesC 1.1 Language Referrence Manual, May 2005. http://www.tinyos.net/tingos-1.x/doc/nesc/ref.pdf. 20 Nov. 04. • TinyOS Tutorial, September 2003. http://www.tinyos.net/tinyos-1.x/doc/tutorial. 15 Nov. 04. • D. Gay, P. Levis, D. Culler, E. Brewer, R. von Behren, M. Welsh. The nesC Language: A Holistic Approach to Networked Embedded Systems, June 2003. http://nescc.sourceforge.net/papers/nesc-pldi-2003.pdf. 27 Nov. 04. • C. Chow and G. Godavari. First Response Sensor Network (FRNS) Final Report for NISSC Fall 2003 Project. • P. Buonadonna, J. Hill, D. Culler. Active Message Communication for Tiny Networked Sensors. • MPR – Mote Processor Readio Board – MIB – Mote Interface/Programming Board User’s Manual. 2004. http://www.xbow.com. 15 Nov. 04. • Wireless Systems for Environmental Monitoring. http://www.xbow.com. 1 Dec. 04. • Product Info Guide. http://www.xbow.com. 1 Dec. 04. • Edward Chow. “Class Lecture”, 22 Nov. 04. University of Colorado, Colorado Springs