Model-Based Design in the Ptolemy Project A Chess Project Center for Hybrid and Embedded Software Systems Edward A. Lee UC Berkeley Presented at Boeing,

Slides:



Advertisements
Similar presentations
ACM SIGPLAN 2001 Workshop on Languages, Compilers, and Tools for Embedded Systems (LCTES'2001) Jun 22-23, 2001, Snowbird, Utah, USA Embedded Software from.
Advertisements

PTIDES: Programming Temporally Integrated Distributed Embedded Systems Yang Zhao, EECS, UC Berkeley Edward A. Lee, EECS, UC Berkeley Jie Liu, Microsoft.
Process-Based Software Components for Networked Embedded Systems Edward A. Lee, PI UC Berkeley Core Technical Team (Mobies, SEC, and GSRC): Christopher.
Center for Hybrid and Embedded Software Systems College of Engineering, University of California at Berkeley Presented by: Edward A. Lee, EECS, UC Berkeley.
SRC ETAB Summer Study Colorado Springs, June 25-26, 2001 Model-Based Approaches to Embedded Software Design Edward A. Lee UC Berkeley & GSRC.
Overview of Ptolemy II Edward A. Lee Professor UC Berkeley October 9, 2003.
Advanced Tool Architectures Supporting Interface-Based Design
Integrated Design and Analysis Tools for Software-Based Control Systems Shankar Sastry (PI) Tom Henzinger Edward Lee University of California, Berkeley.
NSF Foundations of Hybrid and Embedded Software Systems UC Berkeley: Chess Vanderbilt University: ISIS University of Memphis: MSI A New System Science.
February 21, 2008 Center for Hybrid and Embedded Software Systems Organization Board of Directors Edward A. Lee, UC Berkeley.
Mobies Phase 1 UC Berkeley 1 Agenda 8:00-8:30 Continental breakfast 8:30-9:00 Overview of Mobies Phase 1 effort (Edward A. Lee) 9:00-9:40 Introduction.
Type System, March 12, Data Types and Behavioral Types Yuhong Xiong Edward A. Lee Department of Electrical Engineering and Computer Sciences University.
Department of Electrical Engineering and Computer Sciences University of California at Berkeley Behavioral Types for Actor-Oriented Design Edward A. Lee.
Behavioral Types as Interface Definitions for Concurrent Components Center for Hybrid and Embedded Software Systems Edward A. Lee Professor UC Berkeley.
Building Unreliable Systems out of Reliable Components: The Real Time Story Edward A. Lee Professor, Chair of EE, and Associate Chair of EECS CHESS: Center.
Ptolemy Miniconference May 9, 2003 Berkeley, CA Ptolemy Project Status and Overview Edward A. Lee Professor Ptolemy Project Director.
February 11, 2010 Center for Hybrid and Embedded Software Systems Ptolemy II - Heterogeneous Concurrent Modeling and Design.
Component-Based Design of Embedded Control Systems Luca Dealfaro Chamberlain Fong Tom Henzinger Christopher Hylands John Koo Edward A. Lee Jie Liu Xiaojun.
Chess Review October 4, 2006 Alexandria, VA Edited and presented by Advanced Tool Architectures Edward A. Lee UC Berkeley.
Chess Review November 21, 2005 Berkeley, CA Edited and presented by Advanced Tool Architectures Edward A. Lee UC Berkeley.
Heterogeneous Modeling and Design in Ptolemy II Johan Eker UC Berkeley with material courtesy of Edward Lee and the Ptolemy group ECE Seminar Series, Carnegie.
Mobies Phase 1 UC Berkeley 1 Process-Based Software Components Mobies Phase 1, UC Berkeley Edward A. Lee and Tom Henzinger (with contributions from Steve.
6th Biennial Ptolemy Miniconference Berkeley, CA May 12, 2005 Ptolemy Project Status and Overview Edward A. Lee Ptolemy Project Director, UC Berkeley.
Modeling Heterogeneous Systems Edward Lee UC Berkeley Design for Safety Workshop NASA Ames Research Center Mountain View, CA 11 October, Design.
Are “Embedded Systems" Just Systems Made with Small Computers? Chess: Center for Hybrid and Embedded Software Systems Invited Talk Artist International.
Mobies Phase 1 UC Berkeley 1 Process-Based Software Components Mobies Phase 1, UC Berkeley Edward A. Lee and Tom Henzinger PI Meeting, Boca Raton January.
February 23, 2012 Center for Hybrid and Embedded Software Systems Organization Board of Directors Edward A. Lee, EECS Thomas.
Review of “Embedded Software” by E.A. Lee Katherine Barrow Vladimir Jakobac.
Actor-Oriented Design: A focus on domain-specific languages for embedded systems Edward A. Lee Professor, UC Berkeley Director, Center for Hybrid and Embedded.
Building Unreliable Systems out of Reliable Components: The Real Time Story Edward A. Lee Professor, Chair of EE, and Associate Chair of EECS CHESS: Center.
An Extensible Type System for Component-Based Design
Mixing Models of Computation Jie Liu Palo Alto Research Center (PARC) 3333 Coyote Hill Rd., Palo Alto, CA joint work with Prof. Edward.
Design of Fault Tolerant Data Flow in Ptolemy II Mark McKelvin EE290 N, Fall 2004 Final Project.
Chess Review November 21, 2005 Berkeley, CA Edited and presented by Causality Interfaces and Compositional Causality Analysis Rachel Zhou UC Berkeley.
MoBIES PI-Meeting, July 2001, Jackson Hole Controller Design Using Multiple Models of Computation Edward Lee Johan Eker with thanks to Paul Griffiths,
NSF Foundations of Hybrid and Embedded Software Systems UC Berkeley: Chess Vanderbilt University: ISIS University of Memphis: MSI A New System Science.
Ptolemy Miniconference May 9, 2003 Berkeley, CA Ptolemy Project Plans for the Future Edward A. Lee Professor Ptolemy Project Director.
SEC PI Meeting Annapolis, May 8-9, 2001 Component-Based Design of Embedded Control Systems Edward A. Lee & Jie Liu UC Berkeley with thanks to the entire.
Department of Electrical Engineering and Computer Sciences University of California at Berkeley System-Level Types for Component-Based Design Edward A.
Department of Electrical Engineering and Computer Sciences University of California at Berkeley Concurrent Component Patterns, Models of Computation, and.
MoBIES Working group meeting, September 2001, Dearborn Ptolemy II The automotive challenge problems version 4.1 Johan Eker Edward Lee with thanks.
7th Biennial Ptolemy Miniconference Berkeley, CA February 13, 2007 PTIDES: A Programming Model for Time- Synchronized Distributed Real-time Systems Yang.
Process-Based Software Components Final Mobies Presentation Edward A. Lee Professor UC Berkeley PI Meeting, Savannah, GA January 21-23, 2004 PI: Edward.
Center for Hybrid and Embedded Software Systems Jonathan Sprinkle Executive Director, CHESS Center for Hybrid and Embedded Software Systems UC Berkeley.
State of the Art Lecture IEEE Instrumentation and Measurement Technology Conference Budapest, Hungary, May 21-23, 2001 Computing for Embedded Systems Edward.
Designing Predictable and Robust Systems Tom Henzinger UC Berkeley and EPFL.
Embedded Software: Leveraging Concurrent Models of Computation Edward A. Lee Professor, UC Berkeley Center for Hybrid and Embedded Software Systems (CHESS)
Ptolemy Project 1 Streaming Models of Computation in The Ptolemy Project Edward A. Lee Professor UC Berkeley Workshop on Streaming Systems, Endicott House,
Embedded Software Challenges for the Next 10 Years Chess: Center for Hybrid and Embedded Software Systems Infineon Embedded Software Days Munich, Sept.
Panel: What Comes After C++ in System-Level Specification Edward Lee UC Berkeley Forum on Design Languages Workshop on System Specification & Design Languages.
Lee & Henzinger ESWG #1 UC Berkeley Mobies Technology Project Process-Based Software Components for Networked Embedded Systems PI: Edward Lee CoPI: Tom.
MOBIES Project Progress Report Engine Throttle Controller Design Using Multiple Models of Computation Edward Lee Haiyang Zheng with thanks to Ptolemy Group.
Model-Driven Development From Object-Oriented Design to Actor-Oriented Design Chess: Center for Hybrid and Embedded Software Systems Edward A. Lee Professor.
System-Level Types for Component-Based Design Paper by: Edward A. Lee and Yuhong Xiong Presentation by: Dan Patterson.
Department of Electrical Engineering and Computer Sciences University of California at Berkeley The Ptolemy II Framework for Visual Languages Xiaojun Liu.
An Overview of the Ptolemy Project and Actor-Oriented Design Edward A. Lee Professor UC Berkeley Center for Hybrid and embedded software systems OMG Technical.
Embedded Software: Building the Foundations Edward A. Lee Professor, Chair of EE, and Associate Chair of EECS CHESS: Center for Hybrid and Embedded Software.
Design Languages in 2010 Chess: Center for Hybrid and Embedded Software Systems Edward A. Lee Professor UC Berkeley Panel Position Statement Forum on Design.
Actor Networks Edward A. Lee Robert S. Pepper Distinguished Professor Chair of EECS UC Berkeley Invited Talk Workshop Foundations and Applications of Component-based.
February 11, 2016 Center for Hybrid and Embedded Software Systems Organization Faculty Edward A. Lee, EECS Alberto Sangiovanni-Vincentelli,
February 14, 2013 Center for Hybrid and Embedded Software Systems Organization Faculty Edward A. Lee, EECS Alberto Sangiovanni-Vincentelli,
Ptolemy II - Heterogeneous Concurrent Modeling and Design in Java
An overview of the CHESS Center
TRUST:Team for Research in Ubiquitous Secure Technologies
Ptolemy II - Heterogeneous Concurrent Modeling and Design in Java
Retargetable Model-Based Code Generation in Ptolemy II
Ptolemy II - Heterogeneous Concurrent Modeling and Design in Java
An overview of the CHESS Center
Ptolemy II - Heterogeneous Concurrent Modeling and Design in Java
An overview of the CHESS Center
Presentation transcript:

Model-Based Design in the Ptolemy Project A Chess Project Center for Hybrid and Embedded Software Systems Edward A. Lee UC Berkeley Presented at Boeing, Seattle July 31, 2003 Chess Board of Directors Tom Henzinger Edward A. Lee Alberto Sangiovanni-Vincentelli Shankar Sastry Other key faculty Dave Auslander Ruzena Bajcsy Raz Bodik Karl Hedrick Kurt Keutzer George Necula Masayoshi Tomizuka Pravin Varaiya

Chess, UC Berkeley, E. A. Lee 2 Mission of Chess To provide an environment for graduate research on the design issues necessary for supporting next- generation embedded software systems. –Model-based design –Tool-supported methodologies For –Real-time –Fault-tolerant –Robust –Secure –Heterogeneous –Distributed Software The fate of computers lacking interaction with physical processes. We are on the line to create a “new systems science” that is at once computational and physical.

Chess, UC Berkeley, E. A. Lee 3 A Traditional Systems Science – Feedback Control Systems Models of continuous-time dynamics Sophisticated stability analysis But not accurate for software controllers

Chess, UC Berkeley, E. A. Lee 4 Discretized Model – A Step Towards Software Numerical integration techniques provided sophisticated ways to get from the continuous idealizations to computable algorithms. Discrete-time signal processing techniques offer the same sophisticated stability analysis as continuous-time methods. But it’s still not accurate for software controllers

Chess, UC Berkeley, E. A. Lee 5 Hybrid Systems – Reconciliation of Continuous & Discrete UCB researchers have contributed hugely to the theory and practice of blended discrete & continuous models. But it’s still not accurate for software controllers

Chess, UC Berkeley, E. A. Lee 6 Timing in Software is More Complex Than What the Theory Deals With An example, due to Jie Liu, models two controllers sharing a CPU under an RTOS. Under preemptive multitasking, only one can be made stable (depending on the relative priorities). Under non-preemptive multitasking, both can be made stable. Where is the theory for this?

Chess, UC Berkeley, E. A. Lee 7 Another Traditional Systems Science - Computation, Languages, and Semantics States = Bits* results + state out sequence f : States  States Everything “computable” can be given by a terminating sequential program. Functions on bit patterns Time is irrelevant Non-terminating programs are defective Alan Turing

Chess, UC Berkeley, E. A. Lee 8 Current fashion – Pay Attention to “Non-functional properties” Time Security Fault tolerance Power consumption Memory management But the formulation of the question is very telling: How is it that when a braking system applies the brakes is any less a function of the braking system than how much braking it applies?

Chess, UC Berkeley, E. A. Lee 9 Processes and Process Calculi incoming message outgoing message Infinite sequences of state transformations are called “processes” or “threads” In prevailing software practice, processes are sequences of external interactions (total orders). And messaging protocols are combined in ad hoc ways. Various messaging protocols lead to various formalisms.

Chess, UC Berkeley, E. A. Lee 10 stalled for rendezvous stalled by precedence timing dependence Interacting Processes – Concurrency as Afterthought Software realizing these interactions is written at a very low level (semaphores and mutexes). Very hard to get it right.

Chess, UC Berkeley, E. A. Lee 11 Interacting Processes – Not Compositional An aggregation of processes is not a process (a total order of external interactions). What is it? Many software failures are due to this ill- defined composition.

Chess, UC Berkeley, E. A. Lee 12 What Will Replace This Approach? Synchronous languages(e.g. Esterel)? Time-driven languages (e.g. Simulink, Giotto)? Push/Pull component interactions? Hybrid systems? Timed process networks? Discrete-event formalisms? Timed CSP? We intend to find out.

Chess, UC Berkeley, E. A. Lee 13 Ptolemy Project within Chess Objective is to unify: –modeling –specification –design –programming Define modeling & design “languages” with: –syntaxes that aid understanding –composable abstractions –understandable concurrency and time –predictable behavior –robust behavior All of these tasks are accomplished by the system designers.

Chess, UC Berkeley, E. A. Lee 14 Ptolemy Project Participants Director: Edward A. LeeEdward A. LeeStaff: Christopher HylandsChristopher Hylands Susan Gardner (Chess)Susan Gardner (Chess) Nuala MansardNuala Mansard Mary P. StewartMary P. Stewart Neil E. Turner (Chess)Neil E. Turner (Chess) Lea Turpin (Chess)Lea Turpin (Chess) Postdocs, Etc.: Joern Janneck, PostdocJoern Janneck, Postdoc Rowland R. Johnson, Visiting ScholarRowland R. Johnson, Visiting Scholar Kees Vissers, Visiting Industrial FellowKees Vissers, Visiting Industrial Fellow Daniel Lázaro Cuadrado, Visiting ScholarDaniel Lázaro Cuadrado, Visiting Scholar Graduate Students: J. Adam CataldoJ. Adam Cataldo Chris ChangChris Chang Elaine CheongElaine Cheong Sanjeev KohliSanjeev Kohli Xiaojun LiuXiaojun Liu Eleftherios D. MatsikoudisEleftherios D. Matsikoudis Stephen NeuendorfferStephen Neuendorffer James YehJames Yeh Yang ZhaoYang Zhao Haiyang ZhengHaiyang Zheng Rachel ZhouRachel Zhou

Chess, UC Berkeley, E. A. Lee 15 At Work in the Chess Software Lab

Chess, UC Berkeley, E. A. Lee 16 Software Legacy of the Project Gabriel ( ) –Written in Lisp –Aimed at signal processing –Synchronous dataflow (SDF) block diagrams –Parallel schedulers –Code generators for DSPs –Hardware/software co-simulators Ptolemy Classic ( ) –Written in C++ –Multiple models of computation –Hierarchical heterogeneity –Dataflow variants: BDF, DDF, PN –C/VHDL/DSP code generators –Optimizing SDF schedulers –Higher-order components Ptolemy II ( ) –Written in Java –Domain polymorphism –Multithreaded –Network integrated –Modal models –Sophisticated type system –CT, HDF, CI, GR, etc. Each of these served us, first-and- foremost, as a laboratory for investigating design. PtPlot (1997-??) –Java plotting package Tycho ( ) –Itcl/Tk GUI framework Diva ( ) –Java GUI framework

Chess, UC Berkeley, E. A. Lee 17 Ptolemy Classic Example Ptolemy application developed by Uwe Trautwein, Technical University of Ilmenau, Germany

Chess, UC Berkeley, E. A. Lee 18 Modeling Synthesis Heterogeneous, problem-level description Heterogeneous, implementation -level description Relating the problem level with the implementation level

Chess, UC Berkeley, E. A. Lee 19 Foundations Our contributions: Hierarchical Heterogeneity Behavioral Types Domain Polymorphism Responsible Frameworks Hybrid Systems Semantics Tagged Signal Model Discrete-Event Semantics Starcharts and Modal Model Semantics Continuous-Time Semantics Dataflow Semantics (SDF, BDF, DDF, PN, CI) Giving structure to the notion of “models of computation”

Chess, UC Berkeley, E. A. Lee 20 Hierarchical Heterogeneity In Ptolemy, the semantics of a block diagram is defined by a “director,” which is a component that the model builder places in the model. An “abstract semantics” defines the interaction across levels of hierarchy where the semantics differ. continuous environment modal model discrete controller example Ptolemy II model: hybrid control system

Chess, UC Berkeley, E. A. Lee 21 Actor-Oriented Design Actors with Ports and Attributes Model of Computation: Messaging schema Flow of control Concurrency Examples: Push/Pull Time triggered Process networks Discrete-event systems Dataflow systems Publish & subscribe Key idea: The model of computation is part of the framework within which components are embedded rather than part of the components themselves.

Chess, UC Berkeley, E. A. Lee 22 Actor View of Producer/Consumer Components Models of Computation: push/pull continuous-time dataflow rendezvous discrete events synchronous time-driven publish/subscribe … Many actor-oriented frameworks assume a producer/consumer metaphor for component interaction.

Chess, UC Berkeley, E. A. Lee 23 Examples of Actor-Oriented Component Frameworks Easy5 (Boeing) Simulink (The MathWorks) Labview (National Instruments) Modelica (Linkoping) OCP, open control platform (Boeing) GME, actor-oriented meta-modeling (Vanderbilt) SPW, signal processing worksystem (Cadence) System studio (Synopsys) ROOM, real-time object-oriented modeling (Rational) Port-based objects (U of Maryland) I/O automata (MIT) VHDL, Verilog, SystemC (Various) Polis & Metropolis (UC Berkeley) Ptolemy & Ptolemy II (UC Berkeley) …

Chess, UC Berkeley, E. A. Lee 24 Models of Computation Principles of Model Driven Architecture Continuous-time models Dataflow –synchronous dataflow –boolean/integer dataflow –dynamic dataflow –heterochronous dataflow Push/pull models Discrete-event models Synchronous/reactive models CSP models Discrete-time models Time-triggered models (TTA, Giotto) Modal models are possible in all cases

Chess, UC Berkeley, E. A. Lee 25 Ptolemy Project Principles Director from a library defines component interaction semantics Large, domain-polymorphic component library. Basic Ptolemy II infrastructure:

Chess, UC Berkeley, E. A. Lee 26 Continuous-Time Models Soft Walls Avionics System aircraft model criticality calculation pilot model bias control the wall

Chess, UC Berkeley, E. A. Lee 27 Synchronous Dataflow (SDF) SDF offers feedback, multirate, static scheduling, deadlock analysis, parallel scheduling, static memory allocation.

Chess, UC Berkeley, E. A. Lee 28 Parallel Scheduling of SDF Models A C D B Sequential (software)Parallel (hardware) SDF is suitable for automated mapping onto parallel processors

Chess, UC Berkeley, E. A. Lee 29 Other Dataflow Models Process Networks Challenge problem under DARPA Mobies (Model-based design of embedded software), Detection of unknown signal (PSK in this case) Output data sequence, at detected baud rate. (not known apriori) First Symbol Expected Symbol Drift caused by error in estimation

Chess, UC Berkeley, E. A. Lee 30 Discrete-Event Models Sensor Nets Modeling Ptolemy II model where actor icons depict sensor range and connectivity is not shown with wires This model shows the results of a power optimization where the green node issues a broadcast signal and the red ones retransmit to relay the signal.

Chess, UC Berkeley, E. A. Lee 31 Heterogeneous Models: Periodic/Time-Driven Control Inside Continuous Time Giotto director indicates a new model of computation. Domain-polymorphic component. Domains can be nested and mixed.

Chess, UC Berkeley, E. A. Lee 32 Heterogeneous Models Modal Controller Periodic, time-driven tasks Modes (normal & faulty) Controller task

Chess, UC Berkeley, E. A. Lee 33 Heterogeneous Models Hybrid Systems HyVisual is a branded tool based on Ptolemy II designed for hybrid system modeling.

Chess, UC Berkeley, E. A. Lee 34 Distributed Models, Middleware and Systems of Systems Currently, components are designed to the middleware APIs. Our objective is to define the components with middleware-polymorphic interfaces that declare precisely the assumptions and guarantees of the components. Middleware mediates communication. Platform 1Platform 2 Middleware

Chess, UC Berkeley, E. A. Lee 35 Distributed Models Using Mobile Models Model-based distributed task management: MobileModel actor accepts a StringToken containing an XML description of a model. It then executes that model on a stream of input data. PushConsumer actor receives pushed data provided via CORBA, where the data is an XML model of a signal analysis algorithm. Authors: Yang Zhao Steve Neuendorffer Xiaojun Liu A significant challenge here is achieving type safety and security.

Chess, UC Berkeley, E. A. Lee 36 MoML XML Schema Used to Transport Models Ptolemy II designs are represented in XML:

Chess, UC Berkeley, E. A. Lee 37 Verification & Validation What Many People Say They Want Push Me A button that they can push that when pushed will tell them whether or not the design is correct.

Chess, UC Berkeley, E. A. Lee 38 Behavioral Types – A More Practical Approach Capture the dynamic interaction of components in types Obtain benefits analogous to data typing. Call the result behavioral types. Communication has –data types –behavioral types Components have –data type signatures –domain type signatures Components are –data polymorphic –domain polymorphic

Chess, UC Berkeley, E. A. Lee 39 Receiver Interface These polymorphic methods implement the communication semantics of a domain in Ptolemy II. The receiver instance used in communication is supplied by the director, not by the component. Domain polymorphism is the idea that components can be defined to operate with multiple models of computation and multiple middleware frameworks.

Chess, UC Berkeley, E. A. Lee 40 Key to Domain Polymorphism: Receiver Object Model

Chess, UC Berkeley, E. A. Lee 41 Behavioral Type System execution interface communication interface A type signature for a consumer actor. We capture patterns of component interaction in a type system framework. We describe interaction types and component behavior using interface automata. We do type checking through automata composition (detect component incompatibilities) Subtyping order is given by the alternating simulation relation, supporting domain polymorphism.

Chess, UC Berkeley, E. A. Lee 42 Conclusion – What to Remember A new systems science –physical + computational Actor-oriented design –concurrent components interacting via ports Models of computation –principles of component interaction Hierarchical heterogeneity –principled mixing of models of computation Behavioral types –a practical approach to verification and interface definition Domain polymorphism –defining components for use in multiple contexts