280 likes | 404 Views
declarative sensor networks. with applications in landslide detection. David Chu Computer Science Division EECS Department UC Berkeley. iCAST/CMU/TRUST Joint Conference 9 January 2007. Leach's Storm Petrel. context. Sensor Networks 10’s – 100’s – 1000’s – 10,000’s. context.
E N D
declarativesensor networks with applications in landslide detection David Chu Computer Science Division EECS Department UC Berkeley iCAST/CMU/TRUST Joint Conference 9 January 2007
Leach's Storm Petrel context Sensor Networks 10’s – 100’s – 1000’s – 10,000’s
context Sensor Networks early experiences
motivation programming sensor networks is difficult! building entire sensor systems is even harder!!
inspiration s e n s o rn e t w o r k s network design data management
inspiration : data management • declarative is widely used in data management • relational databases • spreadsheets • abstract “what” from “how” • (Sensor-Network-As-Database)
inspiration : network design • declarative is new idea in networking • compact • flexible • analyzable, optimizable • Internet Routing, Overlays built declaratively • (the P2 project)
inspiration s e n s o rn e t w o r k s ( DSN ) network design data management
what we did • adapted declarative language • built compiler & runtime for sensornets • wrote declarative examples
10x6 topology 30x2 topology … from original Trickle paper … DSN specification P. Levis, N. Patel, D. Culler, S. Shenker. "Trickle: A Self-Regulating Algorithm for Code Propagation and Maintenance in Wireless Sensor Networks." NSDI 2004.
agenda • language overview • declarative sensornet examples • system architecture • feasibility assessment • application to landslide detection
brief language overview Rule1: implies don’t care join Rule2: Fact: Built-ins:
S C1 Z C2 D S C D a full example : tree
and others… link estimator localization tracking geographic routing* *fallback routing not shown
arch : compiler Snlog Compiler/Optimizer store(…) :- prod(…), cons(…). … path(…) :- link(…), dest(…). … Snlog Program Snlog Frontend Execution Planner nesC Backend GenericPredicateTemplate … … nesC Templates RuntimeTemplate … … Generated nesC code Database Operators Built-in Predicates nesC Compiler Runtime Components Type system Network support DSN Runtime Support Binary Image
tupleready sendready sendready tupleready arch : runtime Join Join Proj runtime daemon tupleready … … … … … … … Sel Ag Proj tupleready mac daemon push interfaces database operators (compiler’s library) Join Sel Agg Proj pull interfaces table (compiler generated) thread of control builtin (user’s library) event signal the network
implementation challenges • predictable execution → dynamic vs. static allocation • memory constraints → memory footprint optimizations no temporary tables, join/agg operator choice • asynchrony → rule-level atomicity priorities
evaluating tree-collection messages sent (similar performance) hop-counts
compiled size TelosB mote code space = 48KB, data space = 10KB
application large scale and fine-grained debris flow monitoring
[Left] La Conchita, California – a small seaside community along Highway 101 south of Santa Barbara. This landslide and debris flow occurred in the spring of 1995. A reoccurrence in 2005 claimed 4 lives and resulted in 29 missing persons. [Right] Chehalis, Washington - landslides and debris flows during the winter storms of February 1996. Photographs by R.L. Schuster, U.S. Geological Survey.
Day Fire Harvard Burn Site [Above] The locations of the 2005-2006 and 2006-2007 debris flow deployment sites. [Top Right] Smoke from the Day Fire. [Middle Right] Recently burned hillside in Burbank, CA was the site of two debris flows in 2005-2006 Winter season. [Bottom Right] Base of the channel after debris flow with remaining sediment. [Bottom Left] Burn-resilient vegetation is quickly recovering just a few months after the fires and debris flows.
[Above] Parshall flume used in conjunction with water level logger at the channel’s choke-point. [Top Right] Custom overland flow sensor for fine-grained detection of water runoff. [Bottom Right] Solar-powered base station for actuating and gathering data from the wireless sensor network, shown here connected to laptop during testing.
conclusion • sensor networks → data + communication • several examples of functional programs • feasible for today’s hardware platforms • preparing for landslide deployment
thanks collaborators Joe Hellerstein, Scott Shenker, Ion Stoica Arsalan Tavakoli, Lucian Popa Tsung-Te Lai Phil Levis, Jung Woo Lee, Aby John Daniel Malmon