Mode dependency
Relationships
Main Description

Short Description

Modes capture certain states in a system where it is supposed to operate in a certain way. For instance, if the hazard warning signal is turned on, then the warning lights would be flashed synchronously with a certain periodicity and when the signal is turned off then the system should return to its usual mode, where the lights do not flash. Obviously, timing constraints should also be possible to associate with modes since different modes of operation have different timing requirements, on different events.

TADL2 therefore allows a timing constraint to be dependent on a mode. When a mode is turned on then all its dependent timing constraints become active, and they remain so until the mode is turned off when they are again deactivated.

TADL2 does not provide any means to define modes: it assumes that, for each mode m, there is a special event turning m on and off. These events provide the interface of TADL2 for modes. A time interval between an event occurrence turning on m, and the subsequent event occurrence turning it off, is a "mode window" for m: the timing constraints that depend on m are active exactly in these windows.

TADL2 does not require that modes are mutually exclusive. However, a timing constraint can only be dependent on one mode. If a constraint is to be active in several modes, then a "super-mode" corresponding to the union of these modes has to be defined outside TADL2. The constraint can then be triggered by an event for that super-mode.

An exact semantics has been defined for mode-dependent timing constraints, which specifies exactly what it means for a timing constraint to be active during a mode. See deliverable D11.

Links to TADL2 concepts

All TADL2 timing constraints can be made mode dependent. See List of TADL constraints below.

Abstraction level specific list of applicable events

·         Concrete TimingDescriptionEvents in the AUTOSAR model of the EAST-ADL Implementation Level. These events are used for mode switches:

o   Timing events at the Virtual Function Bus level

§  TDEventModeDeclaration

·         modeDeclarationSwitchCompleted

·         modeDeclarationSwitchInitiated

o   Timing events related to Basic Software modules (BswModuleDescription)

§  TDEventBswModeDeclaration

·         modeDeclarationRequested

·         modeDeclarationSwitchCompleted

·         modeDeclarationSwitchInitiated

 

Context Specific Example

For a braking system, with an event chain c containing a brake pedal actuator event as stimulus and a brake event as response, we may have a mode-dependent reaction constraint where the upper limit for the constraint depends on the velocity v as follows:

·         mode1: v in [50,60) km/h => upper = 23.3 ms

·         mode2: v in [60,80) km/h => upper = 17.5 ms

·         mode3: v in [80,90) km/h => upper = 15.6 ms

This can be expressed in TADL2 as three mode-dependent reaction constraints as follows:

 

 R1 = reactionConstraint {

          scope = c,

          upper = 23.3 ms,

          mode = mode1

      }

 

 

 R2 = reactionConstraint {

          scope = c,

          upper = 17.5 ms,

          mode = mode2

      }

 

 

 R3 = reactionConstraint {

          scope = c,

          upper = 15.6 ms,

          mode = mode3

      }

 

Note that TADL2 has no means to define the modes themselves: thus, the definiitions of mode1 – mode3 in terms of the velocity will have to be done outside TADL2.


 

More Information
Examples
Supporting Materials