+ All Categories
Home > Documents > SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and...

SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and...

Date post: 17-Jan-2016
Category:
Upload: shauna-francis
View: 219 times
Download: 0 times
Share this document with a friend
52
SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade Federal do Rio Grande do Sul Porto Alegre, Brazil Paderborn, 4th November 1999 UFRGS
Transcript
Page 1: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

SIMOO

A Platform for Object-Oriented Design and Simulation of

Embedded Electronic Systems and Real-Time Automation Systems

Flávio R. Wagner

Universidade Federal do Rio Grande do Sul

Porto Alegre, Brazil

Paderborn, 4th November 1999

UFRGS

Page 2: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Outline

1. Introduction

2. Basic modeling and simulation infra-structure

3. Hardware-software co-design methodology

4. Co-simulation infra-structure

5. Embedded electronic systems

6. Real-time automation systems

7. Final remarks

UFRGS

Page 3: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

SIMOO main features

• object-oriented modeling and simulation of discrete systems

• multiparadigm modeling

• visual interactive simulation

• graphical description of the static structure

• behavior described in C++ or state diagrams annotated with C++

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 4: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Design of embedded electronic systems

• goal: control of physical processes and equipments

• architecture– analog and digital hardware

– off-the-shelf or dedicated processors

– software

• requirements for a design environment– appropriate specification mechanisms for various

abstraction levels

– stepwise refinement process

– co-simulation

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 5: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Design of real-time automation systems

• goal: control of physical processes

• architecture– distributed system

– off-the-shelf microcontrollers or microprocessors

– real-time operating system

– real-time constraints

– analog interfaces

– software

• requirements for a design environment– appropriate specification mechanisms for various

abstraction levels

– stepwise refinement process

– co-simulation

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 6: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Multiparadigm modeling and simulation

• each class may have a different modeling paradigm

• modeling paradigms are obtained by combining approaches for different modeling aspects– client or server perspective

– behavior described by event-orientation or process-orientation

– communication by messages or ports

– active, semi-active or passive handling of messages

• other simulation packages or languages usually ...– offer a single or limited repertory of paradigms

– do not allow a combination of paradigms in the same model

• SIMOO approach enhances the reusability of models and classes

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 7: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Autonomous and interface objects

• autonomous objects– correspond to the entities of the model logic

– each object has ist own execution thread

– do not support shared variables

– communication through messages

• interface objects– visualization of results

– data collection

– interactive input of data

– share a single thread

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 8: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Software architecture

ModelEditorTool

library ofautonomous

objects

C++ code

SIMOOclass

library

executablecodecompiler

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 9: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Model Editor Tool

• supports construction of hierarchical object-oriented models

• models defined by hierarchical class diagrams and instance diagrams

• simulation-specific features: modeling paradigms

• access to user-defined class library

• class diagrams– relationships: inheritance, aggregation, acquaintance

• instance diagrams– concrete instantiation of the class diagram

– gives concrete values to n-to-m relationships and to class parameters

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 10: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Example of diagrams1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 11: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

MET - Describing behavior in C++1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 12: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

MET - State diagrams1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 13: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

MET - State diagrams1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 14: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

User interface

• default user interface automatically added to all models

• specific user interface built by interface objects

• separation between model logic and user interface– autonomous objects x interface objects

– increased reusability of autonomous and interface objects

– easier debugging of the model logic

• tool-oriented approach– dynamic mapping from interface to autonomous objects

– help verification and validation of models and closer inspection of desired model aspects

• a monitor controls the mappings– intercepts messages that modify attributes of autonomous

objects and sends copies to corresponding interface objects

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 15: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Basic user interface

• tracking variables

• modifying values of variables

• querying the model structure

• modifying the model structure– replacing methods that respond to messages

– creating and removing objects

– modifying mappings from interface objects to autonomous objects

• querying and modifying the event list

• time-stepping, stopping, resuming, setting breakpoints

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 16: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Future work

• synchronization between objects– current version: conservative protocol

– future: more optimistic protocol

• distributed version– current version: objects already have their own execution

threads

– distributed platform yet to define

– first prototype based on Java RMI is being implemented

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 17: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Basic design methodology

• initial specification– abstract behavior

– C++ or state diagrams annotated with C++

• objects corresponding to the physical world may be modeled by a continuous behavior

• validation by simulation

• design proceeds through a stepwise refinement– hierarchical refinement: same abstraction level

– abstraction refinement: design decisions are taken

• abstract objects are mapped into objects of a target architecture– digital or analog hardware, software

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 18: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Target architectures

• 1 or more processors– off-the-shelf microprocessors

– DSPs, RISCs, microcontrollers

– ASIPs

• specialized digital hardware– FPGAs

– ASICs

• analog hardware– DA and AD converters

– sensors and actuators

• software running on top of the chosen processor(s)

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 19: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Library-based synthesis

• selection of hardware objects from a previously built library of classes for the possible target architectures

• software objects may be automatically generated from the abstract specification– from C to assembly languages of the selected processors

• hardware objects must be described in an appropriate language (VHDL)

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 20: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Conclusions

• this methodology applies both to ...– embedded electronic systems

– real-time automation systems

• target architectures are similar– distributed systems containing analog and digital hardware

parts, processors, software

• specializations are necessary– in the target architecture

– in the design methodology

• co-simulation is necessary

• future work: hardware-in-the-loop

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 21: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Co-simulation requirements

• co-simulation for the validation of the initial specification– discrete behavior - algorithms or state diagrams

– continuous behavior - physical world

• co-simulation for the validation of possible implementations– discrete behavior - algorithms or state diagrams

• for parts that have not been refined yet

• for software parts

– continuous behavior• for the physical world

• for analog hardware

– VHDL• for digital hardware

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 22: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Coupling SIMOO and VHDL1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 23: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Coupling SIMOO and VHDL1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

SIMOO simulator VHDL simulator

Page 24: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Coupling SIMOO and VHDL

• interfaces in both domains are automatically generated– C-file in the VHDL domain

– interface object in the SIMOO domain

• interfaces are responsible for ...– communication - exchange of data and format conversion

– synchronization between simulators• conservative approach

• communication between simulators by sockets

• distributed simulation is possible– SIMOO currently runs on Windows

– VSS runs on Unix workstations

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 25: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Hybrid discrete-continuous simulation

• objects with analog behavior– modeled by a set of differential equations

– implement the numerical integration method

– object attribute defines integration time step

• signal-flow approach– mathematical functions from inputs to outputs

– appropriate for objects that ...• don´t have a physical implementation yet

• model the physical world

• are modeled at a higher abstraction level than basic components (PID controllers, converters, filters)

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 26: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Hybrid discrete-continuous simulation

• current situation– differential equations directly described in C++

– integration time step must be defined by the programmer

• scheduling the execution of analog objects– if there are more than one AO and they communicate with

each other, they must be scheduled at each time step and exchange messages

– if not, an AO may be scheduled at intervals that depend on the discrete objects and then execute several integration steps

• future work– better time advancement mechanism, including automatic

time step definition

– integration with Matlab / Simulink

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 27: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Design methodology

• object-oriented specification

• stepwise refinement

• co-simulation combining C++, VHDL, analog behavior

• synthesis to a multiprocessor platform

• each object or group of objects may be mapped to a different processor

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 28: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Example: crane

• benchmark for specification of heterogeneous systems

• physical plant: crane with a load, moving along a track

• control– assures smooth movement, without bumps and oscillations

– verifies if displacement does not exceed limits and if angle of the load is acceptable (emergency break)

– auto-test of sensors

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 29: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

First modeling of the crane1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

physical plant

drives the dc motor (speed),control breaks andemergency break

checks plausibility of car position and load angle

controls car movement,sensor checking,output forces to Actuators

Page 30: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

First modeling of the crane

• physical plant Plant_rk is an object with continuous behavior

• all other objects have discrete behavior

• M_Control combines two computation models– control algorithm for movement is a discrete computation of the

state-variable method

q n+1=A*q n + B*[Motor_Voltage Car_Position]T at each 10 ms

– sensor checking is an FSM

• Diagnosis is an FSM

• Actuators is an algorithm

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 31: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Second modeling of the crane1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

main control algorithm,arithmetic operations

M_Control split into two objects

FSM for sensor checking

Page 32: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Third modeling of the crane1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

FSMs (Job_Control and Diagnosis) merged into a single object tobe implemented as digital hardware and modeled in VHDL

Page 33: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Library of processors

• processors are characterized by attributessize of binary word

types of instructions

memory operand addressing modes

execution time (in clock cycles) of each instruction

number of busses to access memory

type of memory

number of registers

use of pipeline and depth of eventual pipeline

use of harvard architecture

• current library: C25, 8051, RISCO

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 34: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Characterizing the application1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

APP = P

P + M + C

APC = C

P + M + C

APM = M

P + M + C

C++ CDFG

machine-independent

3-addresscode

application is characterized as:- data-dominated- memory-dominated- control-dominated

Page 35: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Selecting the processor

• performance profiles measure, for the given application, the relative cost of the processor for each aspect (data, control, memory)

• selection algorithm weighs the performance profiles and chooses the processor best suited for the application

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

PPPi = Pi

Pi + Mi + Ci

PPCi = Ci

Pi + Mi + Ci

PPMi = Mi

Pi + Mi + Ci

Page 36: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Future work

• selection of processors considering a multi-dimensional space of aspects– cost, area, power consumption, performance

• automatic algorithm for exploring various partitionings of objects into processors

• library-based synthesis of communication– map abstract communication mechanisms of SIMOO (ports,

messages) to busses and channels

– measure communication costs

– select communication protocol according to application requirements

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 37: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Introduction

• SIMOO used as a front-end– extensions for the specification of real-time constraints

• back-end is AO/C++, an extension of C++ adapted for real-time systems

• target architecture is a distributed system composed of low-cost microcontrollers connected by an industrial bus

• methodology for the transition from the simulation model to the implementation code

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 38: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Extensions in the specification1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

cyclic methods

Page 39: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Extensions in the specification1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

timed methods (deadline)

default value for the deadline

Page 40: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Extensions in the specification1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

code for handling exceptions

Page 41: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

AO/C++ target language

• combines OO properties of C++ with benefits of Unix-RTOS– maps logically distributed OO model of C++ to physically

distributed process-oriented model of Unix-RTOS

• primitives added to C++– definition of active objects (own execution thread)

– time-triggered methods

– timing constraints (deadlines, cyclic operations, exception handling code)

• AO/C++ programs are parsed and converted to standard C++ with calls to the underlying run-time environment (Unix-RTOS)

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 42: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Example1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 43: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Example1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

cyclic methodfor sampling

physical plant

timed methodfor activating the pump

Page 44: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Example1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

cyclic methodfor sampling

physical plant

timed methodfor activating the pump

interfaceobjects are mappedto these autonomous objects

Page 45: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Generating the implementation model

• simulation model must be transformed into a model which is amenable for the physical implementation

• objects corresponding to the physical plant are removed

• objects corresponding to physical interfaces from the controlling host to the physical plant must be inserted

• interface objects are replaced by autonomous objects

• messages between objects are modified according to the AO/C++ communication paradigm

• in the example– SIMOO / Windows 2690 lines

– AO/C++ 730 lines

– C++ / QNX 2310 lines

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 46: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Example1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

PTSen:1PTSen:1 PTBomba:1PTBomba:1

TelaSNiveln

TelaBomban

PDriver:1PDriver:1

PDriver:1PDriver:1

PPar:1PPar:1

DrvBomba

PPar:1

n

PPar:1PPar:1

DrvSensor

PPar:1

n

PortaParn

PBomba:1PBomba:1PSNivel:1PSNivel:1

Tanque

PSNivel:1PBomba:1

n

Bomba

PDriver:1 PTBomba:1

n

SNivel

PTSen:1

n

Sensor

PDriver:1

n

SisTanque

physical interfaces

Page 47: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Example1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

PTSen:1PTSen:1 PTBomba:1PTBomba:1

TelaSNiveln

TelaBomban

PDriver:1PDriver:1

PDriver:1PDriver:1

PPar:1PPar:1

DrvBomba

PPar:1

n

PPar:1PPar:1

DrvSensor

PPar:1

n

PortaParn

PBomba:1PBomba:1PSNivel:1PSNivel:1

Tanque

PSNivel:1PBomba:1

n

Bomba

PDriver:1 PTBomba:1

n

SNivel

PTSen:1

n

Sensor

PDriver:1

n

SisTanque

interface objects

Page 48: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Future work

• more automatic generation of the implementation model

• automatic generation of the supervisory system– user interface in the simulation model is automatically

transformed into the supervisory system

• hardware-in-the-loop– smooth transition from the simulation model to the

implementation

– selective replacement of simulation objects by physical objects

– user interface is maintained

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 49: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Conclusions

• SIMOO is used as a high-level modeling and verification front-end

• back-ends for two different application fields – embedded electronic systems

– real-time automation systems

• co-simulation: SIMOO is used as a seamless environment for both high-level design and implementation– stepwise refinement: progressive replacement of abstract

descriptions by implementation descriptions

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 50: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Future work

• basic simulation infra-structure– optimize the hybrid simulation mechanisms

– distributed simulation with an optimistic protocol

• embedded electronic systems– communication synthesis

– find optimal selection algorithms

– explore partitioning of objects into processors

– model larger examples where multiprocessor platforms are needed

• real-time automation systems– automatic generation of the supervisory systems

• hardware-in-the-loop: progressive replacement of simulation objects by physical objects

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 51: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

Cooperation

• The research on embedded electronic systems is being performed in cooperation with Prof. Luigi Carro

• The research on real-time automation systems is being performed in cooperation with Prof. Carlos Eduardo Pereira

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

Page 52: SIMOO A Platform for Object-Oriented Design and Simulation of Embedded Electronic Systems and Real-Time Automation Systems Flávio R. Wagner Universidade.

For more information ...1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

1Introduction

2SIMOO

3Hw-Sw codesign

4Co-simulation

5Embeddedsystems

6Real-timeautomation

7Finalremarks

http://www.inf.ufrgs.br/gpesquisa/simoo

software for downloadinguser and programmer manualssmall examplespapers in pdf

http://www.inf.ufrgs.br/~flavio

[email protected]


Recommended