Post on 25-Jan-2021
Time-Portable Real-TimeProgramming with Exotasks
Christoph KirschUniversität Salzburg
Joint work with J. Auerbach, D. Bacon, D. Iercan,V.T. Rajan, H. Röck, and R. Trummer
CHESS Seminar, UC Berkeley, February 2007
© C. Kirsch 2007 2
Exotask Eclipse PluginExotaskGraph
Specification
© C. Kirsch 2007 2
Exotask Eclipse Plugin
Exotask
Exotask
Exotask
© C. Kirsch 2007 2
Exotask Eclipse Plugin
Connection Connection
© C. Kirsch 2007 2
Exotask Eclipse PluginTiming
Grammar
© C. Kirsch 2007
Exotasks in Java
3
public class Controller implements Runnable { // Code generated from the specification: private ExotaskInputPort in0; private ExotaskOutputPort out0; public Controller(ExotaskInputPort in0, ExotaskOutputPort out0) { this.in0 = in0; this.out0 = out0; } // Code written by the user: public void run() { double[] sensorData = (double[]) in0.getValue(); out0.setValue( new Double(control(sensorData))); } private double control(double[] sensors) { ... the actual control algorithm ... }}
© C. Kirsch 2007
TT Grammar
4
0 1 2 3 4 5 6 7 8 9 10
© C. Kirsch 2007
TT Grammar
4
0 1 2 3 4 5 6 7 8 9 10
Period
© C. Kirsch 2007
TT Grammar
4
0 1 2 3 4 5 6 7 8 9 10
TimeOffset
TimeOffset
© C. Kirsch 2007
Logical Execution Time
0 1 2 3 4 5 6 7 8 9 10
Plant
Control System
SensorTask
Actuator
Logical Execution Time
5
© C. Kirsch 2007
Actual Execution Time
0 1 2 3 4 5 6 7 8 9 10
Plant
Control System
Sensor
Deadline
ActuatorTask
6
© C. Kirsch 2007
Actual Execution Time
0 1 2 3 4 5 6 7 8 9 10
Plant
Control System
Sensor
Deadline
ActuatorTask
6
© C. Kirsch 2007
Time PortabilityPlant
Control System
A system’s I/O behavior is input-determined if,for all sequences I of input values and times,
the system always producesunique sequences f(I) of output values and times.
7
© C. Kirsch 2007
Exotask Isolation
8
Private Heaps
© C. Kirsch 2007
1. Validate, 2. Instantiate,3. Schedule & Execute
9
Exotask Runtime System
public class Controller implements Runnable { // Code generated from the specification: private ExotaskInputPort in0; private ExotaskOutputPort out0; public Controller(ExotaskInputPort in0, ExotaskOutputPort out0) { this.in0 = in0; this.out0 = out0; } // Code written by the user: public void run() { double[] sensorData = (double[]) in0.getValue(); out0.setValue( new Double(control(sensorData))); } private double control(double[] sensors) { ... the actual control algorithm ... }}Exotask Graph
Exotask CodeExotask GraphSpecification
schedule execute
instantiatevalidate
invokes
The JAviator
© C. Kirsch 2007 11
50Hz Hard Real Time
© C. Kirsch 2007 12
JAviator Controller
© C. Kirsch 2007
Control Terminal
13
© C. Kirsch 2007 14
Control Terminal Exotask Controller
Demo
Mock JAviator
© C. Kirsch 2007
IBM’s TuningFork
15
© C. Kirsch 2007 16
TuningFork InstrumentedExotask System
Experiments
© C. Kirsch 2007
No GC in Progress
17~3ms
© C. Kirsch 2007
During GC
18
© C. Kirsch 2007
1.4GHz Laptop
19~4ms
© C. Kirsch 2007
Clamp-free Hover
20
Thank you