You are on page 1of 11

Design-driven Development of Dependable Applications:

A Case Study in Avionics


Quentin Enard, Stéphanie Gatti, Julien Bruneau, Young-Joo Moon, Emilie
Balland, Charles Consel

To cite this version:


Quentin Enard, Stéphanie Gatti, Julien Bruneau, Young-Joo Moon, Emilie Balland, et al.. Design-
driven Development of Dependable Applications: A Case Study in Avionics. César Benavente-Peces
and Joaquim Filipe. PECCS - 3rd International Conference on Pervasive and Embedded Computing
and Communication Systems, Feb 2013, Barcelona, Spain. SciTePress, 2013. <hal-00794329>

HAL Id: hal-00794329


https://hal.inria.fr/hal-00794329
Submitted on 25 Feb 2013

HAL is a multi-disciplinary open access L’archive ouverte pluridisciplinaire HAL, est


archive for the deposit and dissemination of sci- destinée au dépôt et à la diffusion de documents
entific research documents, whether they are pub- scientifiques de niveau recherche, publiés ou non,
lished or not. The documents may come from émanant des établissements d’enseignement et de
teaching and research institutions in France or recherche français ou étrangers, des laboratoires
abroad, or from public or private research centers. publics ou privés.
Design-driven Development of Dependable Applications:
A Case Study in Avionics

Quentin Enard1,2 , Stéphanie Gatti1,2 , Julien Bruneau2 , Young-Joo Moon2 , Emilie Balland2
and Charles Consel2
1
Thales Airborne Systems
2
INRIA / University of Bordeaux, France
first.last@inria.fr

Keywords:
Generative programming, Error handling, QoS Monitoring, Real-time systems, Software architecture

Abstract:
Making an application dependable demands that its functional and non-functional requirements
be stringently fulfilled throughout its development process. In this context, a design-driven
development approach has the key advantage of enabling requirements to be traced from their
high-level design forms to the resulting executable artifact. However, because such approaches
are mostly general purpose, they provide little design guidance, if any. This situation makes
unpredictable the coherence and the conformance of an application with respect to its requirements.
To address this situation, we propose an approach that leverages a design-driven development
process dedicated to a specific paradigm. This approach guides the verification of the coherence
and conformance of an application throughout its development. We demonstrate the benefits of
our approach by applying it to a realistic case study in the avionics domain.

1 Introduction Coherence. Because functional and non-functional


aspects are inherently coupled, ensuring their
coherence is critical to avoid unpredicted fail-
Dependability of a system is the ability to
ures [Littlewood and Strigini, 2000]. For example,
avoid service failures that are more frequent and
fault-tolerance mechanisms may significantly de-
more severe than is acceptable [Avizienis et al.,
teriorate the application performance. Generally,
2004]. This generic concept includes attributes
this kind of issues are detected at the late stages
such as availability, integrity and reliability. De-
of the development process, increasing the devel-
pendable systems are now pervasive in a range of
opment cost of applications [Amey, 2002].
domains (e.g., railway, avionics, automotive) and
require a certification process. The main goal of Conformance. Ensuring that an application is in
certification is to demonstrate that a system is conformance with its high-level requirements is
conform to its high-level requirements, resulting typically done by tracing their propagation across
from functional and safety analyses. the development stages. In practice, this process
Software plays an increasingly important role is human-intensive and error prone because it is
in dependable systems; software development is performed manually [Lasnier et al., 2009].
thus required to be certified. In particular, the Certifying a development process requires a
stakeholders have to pay attention to the coher- variety of activities. In industry, the usual pro-
ence of the functional and non-functional aspects cedures involve holding peer review sessions for
of an application to demonstrate the conformance coherence verification, and writing traceability
of the software with the high-level requirements. documents for conformance certification. In this
Non-functional aspects of a system refer to con- context, design-driven development approaches
straints on the manner in which this system imple- are of paramount importance because the design
ments and delivers its functionality (e.g., perfor- drives the development of the application and
mance, reliability, security) [Taylor et al., 2009]. provides a basis for tracing requirements [Volter
et al., 2006]. However, because most existing ap- of the high-level requirements cannot be ensured
proaches are general purpose, their guidance is at design time (e.g., time-related performance),
limited, causing inconsistencies to be introduced we provide further testing support to validate the
in the design and along the development process. implementation with respect to these remaining
This situation calls for an integrated development requirements. This support leverages a realistic
process centered around a conceptual framework flight simulator, namely FlightGear [Perry, 2004].
that allows to guide the certification process in a Validation in avionics. We validate our approach
systematic manner. In response to this situation, by developing a realistic case study in avionics.
we proposed a design-driven development method- Following the DiaSuite methodology, we have de-
ology, named DiaSuite [Cassou et al., 2011], which veloped an aircraft flight guidance system and
is dedicated to the Sense/Compute/Control (SCC) tested it on FlightGear. Additionally, we have
paradigm [Taylor et al., 2009]. As demonstrated duplicated this case study in the context of a com-
by Shaw, the use of a specific paradigm provides mercial drone system, namely Parrot AR.Drone.1
a conceptual framework, leading to a more disci-
plined engineering process and guiding the verifi-
cation process [Shaw, 1995]. An SCC application
is one that interacts with a physical environment. 2 Background
Such applications are typical of domains such as
home/building automation, robotics and avionics. We first present an overview of the DiaSuite
In this paper, we show the benefits of DiaSuite development methodology. Then, we introduce
for the development of dependable SCC applica- the working example used throughout this paper,
tions. This approach is applied to a realistic case namely an application for aircraft flight guidance.
study in the avionics domain, in the context of two
non-functional aspects, namely time-related per- 2.1 Overview of DiaSuite
formance and reliability. The DiaSuite design lan-
guage, named DiaSpec, offers declarations cover- DiaSuite is a design-driven development methodol-
ing both functional and non-functional dimensions ogy dedicated to the SCC paradigm [Cassou et al.,
of an SCC application [Cassou et al., 2011, Mer- 2011]. This paradigm originates from the Sense/-
cadal et al., 2010, Gatti et al., 2011]. However, Compute/Control architectural pattern, promoted
so far, the DiaSuite methodology has only been by Taylor et al. [Taylor et al., 2009]. This pattern
used to study each dimension in isolation, leaving ideally fits applications that interact with an ex-
open the problems of coherence and conformance ternal environment. Such applications are typical
when considering multiple dimensions. This pa- of domains such as home/building automation,
per integrates all these dimensions, enabling the robotics, automotive and avionics.
generation of validation support. More precisely, orders
the paper makes the following contributions:
Controllers act on
Design coherence over functional and non- Actions
context
functional dimensions. We use the DiaSpec data Entities Environment
sensed by
language to describe both functional and non- Contexts
Sources

functional aspects of an application and apply raw data


this approach to a realistic case study. A DiaSpec
description is verified at design time for coherence Figure 1: The SCC paradigm
of its declarations. This verification is performed
with respect to a formal model generated from a As depicted in Figure 1, this architectural pat-
DiaSpec description. tern consists of three types of components: (1)
entities correspond to devices, whether hardware
Design conformance through the development pro- or software, and interact with the external en-
cess. At design time, we provide verification vironment through their sensing and actuating
support to check the conformance between the capabilities; (2) context components refine (filter,
specification and the formalized form of the high- aggregate and interpret) raw data sensed by the
level requirements. At implementation time, we entities; (3) controller components use this refined
guarantee the conformance between the applica- information to control the environment by trigger-
tion code and the previously verified requirements. ing actions on entities.
This process is automatically done by leveraging
1
the generative approach of DiaSuite. As some http://ardrone.parrot.com
pilot specifies a heading to follow, the application
Designers Testers Developers
compares it to the current heading, sensed by de-
vices such as the Inertial Reference Unit (IRU),
Simulation Application
and maneuvers the ailerons accordingly. Each
4 3 navigation mode is generally associated to a func-
Programming framework
tional chain, representing a chain of computations,
1
Application 2 from sensors to actuators [Windsor and Hjortnaes,
Design
DiaSpec
Compiler Execution platform back-end 2009].
5 In the avionics domain, safety analyses are con-
Implementation Support
ducted to identify hazardous situations, resulting
Figure 2: The DiaSuite tool-based methodology in safety requirements [ARP-4761, 1996]. Here are
some examples of high-level requirements for the
flight guidance application, as defined by domain
As depicted in Figure 2, the DiaSuite tool
experts:
suite leverages the SCC paradigm to support each
stage of the development process, from design Req1. The execution time of the functional chain
to deployment. At the design stage, the Dia- associated with the heading mode must not
Spec language provides SCC-specific declaration exceed 650 ms.
constructs (stage À in Figure 2). These constructs Req2. The freshness of the navigation data used
cover both the functional aspects of an application, by the application must be less than 200 ms.
such as data and control flows [Cassou et al., 2011], Req3. The malfunction or failure of a sensor must
and the non-functional aspects, such as QoS [Gatti be systematically signaled to the pilot, within
et al., 2011] and error handling [Mercadal et al., 300 ms.
2010]. Req4. A navigation mode should be deactivated
From a DiaSpec description, a programming safely if a sensor involved in its computation
framework is generated to guide and support the fails.
programmer (stages Á and  in Figure 2). Addi-
Translating these requirements into a coherent
tionally, the DiaSpec compiler generates testing
design and ensuring their traceability across the
support, targeting a simulator specific to a given
development process is mandatory for the certifi-
domain (stage à in Figure 2). Finally, DiaSuite
cation, strongly suggesting an integrated design-
offers support for deploying an application using
driven development methodology like DiaSuite.
several distributed systems technologies such as
Web Services, RMI and SIP (stage Ä in Figure 2).
More details about DiaSuite can be found in our
previous publications [Cassou et al., 2009, Cassou 3 Design
et al., 2011].
This section presents our design approach for
2.2 Flight Guidance Application dependable SCC applications and the validation
support generated at the design stage. These con-
To illustrate the DiaSuite development methodol- tributions are illustrated with the heading mode
ogy for dependable SCC applications, we choose of the flight guidance application, introduced in
an application of aircraft flight guidance. Because Section 2.2.
it is safety critical, this application has to respect
stringent high-level requirements. 3.1 Our Approach
The flight guidance application is in charge of
the aircraft navigation and is under the supervi- Like a programming paradigm, the DiaSuite de-
sion of the pilot [Miller, 1998]. For example, the sign paradigm provides SCC-specific concepts and
pilot can directly specify parameters during the abstractions to solve a software engineering prob-
flight (e.g., the altitude) or define a flight plan that lem. However, these concepts and abstractions
is automatically followed. Each parameter is han- are dedicated to a design style, raising the level
dled by a specific navigation mode (e.g., altitude of abstraction above programming. In this pa-
mode, heading mode). Once a mode is selected per, we propose to use this paradigm to uniformly
by the pilot, the flight guidance application is in describe both the functional and non-functional
charge of operating the ailerons and the elevators aspects of an application. As shown in Figure 3,
to reach the target position. For example, if the our approach consists of layering the design of an
application into the logic of the functional plane device IRU {
source h e a d i n g as F l o a t [ frequency 200 ms ] ;
and the supervision of the non-functional aspects. source p o s i t i o n as C o o r d i n a t e s ;
When a non-functional situation is detected at the source r o l l as F l o a t ;
...
functional layer (e.g., a device failure), an event action D e a c t i v a t e ;
raises FailureException ;
is raised, giving control to the supervisory layer. }
device NavMMI {
source t a r g e t H e a d i n g as F l o a t ;
Supervisory ...
Control a c t i o n Dis ableMo de ;
Compute action D i s p l a y ;
}
Sense
Environment
action Co ntro l {
Functional i n c l i n e ( t a r g e t R o l l as F l o a t ) ;
Control }
device A i l e r o n {
Compute
action Co ntro l ;
Sense }

Figure 3: Layered view of the SCC paradigm Figure 4: Extract of the flight guidance taxonomy

This layered design allows to factorize the su-


pervisory treatments such as error recovery. For This design can be enriched with QoS and
example, the Req4 requirement entails to deac- error-handling declarations. For example, in Fig-
tivate the navigation modes that rely on faulty ure 4, the IRU entity is declared as raising an
sensors. In this case, if a navigation sensor fails, error of type FailureException. Figure 4 spec-
an event (i.e., an error) is raised, giving control ifies that the IRU entity produces the heading
to a supervisory chain of operations, aimed to information with a frequency of 200 ms. For more
deactivate the dependent navigation modes. details about these non-functional declarations,
The design of the flight guidance application the reader can refer to previous publications [Mer-
can thus be decomposed into several functional cadal et al., 2010, Gatti et al., 2011].
and supervisory chains: one functional chain for Using this taxonomy of entities, the specifi-
each navigation mode and one supervisory chain cation of an application is defined using context
for each supervisory treatment (e.g., reconfigura- and controller components. For example, in the
tion, logging, pilot warning). In the rest of this design of the heading mode, the IntHeading con-
section, we focus on the functional chains of the text component computes an intermediate heading
heading mode and the supervisory chain dedicated from the current plane heading given by the IRU
to deactivating the dependent navigation modes. entity and the target heading given by the NavMMI
entity. From this intermediate heading and the
3.2 Functional Layer current plane roll (i.e., its rotation on the longi-
tudinal axis) given by the IRU entity, the Target-
Following the SCC paradigm, the DiaSpec design Roll context component computes a target roll.
language provides specific declarations for entities, This target roll is used by AileronController to
context and controller components. An entity is control the ailerons and reach the target heading.
defined as a set of sensing and actuating capa- The specification of an SCC component is il-
bilities. Figure 4 presents the taxonomy of the lustrated in Figure 5. This DiaSpec fragment
entities used by the heading mode of the flight declares the IntHeading context component as
guidance application. The IRU entity senses the producing an intermediate heading of a Float
position, the heading and the roll of the plane type from values of two input entities, declared
from the environment, as indicated by the source with the source keyword. The control flow of
keyword. The NavMMI entity abstracts over the this process is specified by an interaction contract
pilot interaction and directly provides the target introduced by the interaction clause. It declares
heading set by the pilot. The Aileron entity that, when IntHeading receives a heading infor-
provides the Control interface to act on the en- mation from the IRU entity, it may access the
vironment, as indicated by the action keyword. targetHeading value provided by the NavMMI en-
The high-level nature of the entity declaration tity. The always publish clause specifies that
facilitates the integration of Commercial Off-The- the context systematically publishes a value once
Shelf (COTS) components: any implementation it receives a heading information. Alternatively,
complying with the entity declaration can be used a context component can be declared as either
by an application. maybe or never publishing a result.
Data publishing
context I n t H e a d i n g as F l o a t { Aileron IRU NavMMI
source h e a d i n g from IRU ; Data access
Exceptional Control Deactivate DisableMode
source t a r g e t H e a d i n g from NavMMI ;
interaction { Event
Aileron Mode
when provided h e a d i n g from IRU ; Controller Controller
get t a r g e t H e a d i n g from NavMMI [650ms WCET]
i n 100 ms [ mandatory catch ] ;
always publish ; TargetRoll
}
} Data
IntHeading
[200ms, skipped] Availability
Figure 5: Specification of IntHeading [200ms] [100ms, mandatory]
roll heading targetHeading
IRU IRU NavMMI

In the interaction contract of IntHeading,


Figure 6: Extract of the flight guidance application
the response time of NavMMI has to be at most design
100 ms. The [mandatory catch] annotation in-
dicates that the IntHeading context must com-
pensate the errors when accessing targetHeading 3.4 Verification Support
data. In contrast, the [skipped catch] annota-
tion indicates that a context is not allowed to Because the DiaSpec design language makes flow
handle the errors. information explicit, a range of properties can be
checked at design time. Indeed, a formal model
can be generated from a DiaSpec specification,
3.3 Supervisory Layer allowing the early verification of coherence and
conformance. Unlike our previous work [Cassou
Figure 6 summarizes the design of the heading et al., 2011], we now generate models expressed
mode by a data-flow directed graph, where a node with timed automata, capturing time-related dec-
is an SCC component and the edges indicate data larations. A DiaSpec specification is translated
exchange between the components. This figure into a network of timed automata where each
shows another QoS declaration: a Worst Case Ex- automaton describes the behavior of a DiaSpec
ecution Time (WCET) is specified on the Aileron component.2 The resulting network of timed au-
controller to cope with the Req1 requirement. tomata allows to verify safety properties using
model-checking techniques. Here, we use UP-
Alongside the application logic, supervisory
PAAL, an integrated tool environment dedicated
treatments can be specified in DiaSpec using sep-
to modeling, validation and verification of net-
arate SCC chains. In the avionics domain, these
works of timed automata [Behrmann et al., 2004].
treatments typically involve monitoring the appli-
To illustrate this early verification process, we
cation and triggering reconfigurations, as required
present examples of coherence and conformance
by the Req3 and Req4 requirements expressed
verifications on the design of the flight guidance
in Section 2.2. Specifically, these treatments allow
application.
to (1) inform the pilot in case of a device failure or
unavailable data, (2) deactivate the modes that de-
pend on unavailable data, and (3) log information Coherence verification. Incoherence between
for maintenance purposes. For example, the right the time-related constraints can be automatically
part of Figure 6 depicts the supervisory chain cor- detected by the UPPAAL model checker. Time-
responding to the deactivation of the dependent related properties depend on communication as-
navigation modes. sumptions (e.g., asynchronous/synchronous com-
munication, data buffering). These assumptions
These supervisory chains are specified with
are expressed in terms of parameters of the gener-
respect to non-functional information defined in
ated UPPAAL model. In the model of the heading
the taxonomy and the application design. For
mode, we specify that the components have no
instance, errors raised by entities or violations of
buffer and thus consume values immediately. In
timing constraints are used as sources of informa-
this case, a deadlock state is detected if the NavMMI
tion for the supervisory treatments. In Figure 6,
takes more than 200 ms to answer to a request
the availability of IRU data is checked through
from the IntHeading context component. Indeed,
the DataAvailability context component and is
this context component is not able to handle the
then used by the ModeController component to
enable/disable navigation modes and deactivate 2
A detailed presentation of this translation can be
the faulty sensors. found at http://diasuite.inria.fr/validation.
heading data published every 200 ms by the IRU guides the developer by providing high-level op-
entity. This verification has led us to enrich the erations for entity binding and component inter-
design with a timing constraint indicating that actions. Additionally, our strategy to generate an
the response time of NavMMI has to be at most abstract class relies on the Java language and its
100 ms. A more complex example is the interac- type system to enforce the declared interaction
tion between the TargetRoll context component contracts. As shown in Figure 8, when extend-
and the IRU entity. A deadlock is detected when ing the AbstractIntHeading abstract class, the
the pulling process takes more than 300 ms. The developer is required to implement the onHeading-
shortest counter-example includes three data re- FromIRU abstract method to receive a value pub-
quests and thus cannot be easily identified by lished by this device. In addition to this value,
hand. this method is passed support objects to request
data from a device (binding).
Conformance verification. We use properties
based on temporal logic to express high-level public a b s t r a c t c l a s s A b s t r a c t I n t H e a d i n g {
public a b s t r a c t F l o a t onHeadingFromIRU (
requirements and check them on the design of Float heading , Binding binding ) ;
the application. The UPPAAL model checker ...
}
relies on a subset of TCTL (Timed Computa-
tion Tree Logic) [Henzinger et al., 1994]. An Figure 7: Extract of the AbstractIntHeading class
example of TCTL properties is “IRU.Failure
NavMMI.DisableMode”, corresponding to the
Req4 requirement. When the IRU automaton public c l a s s I n t H e a d i n g extends
is in the IRU.Failure state, the NavMMI automa- AbstractIntHeading {
public F l o a t onHeadingFromIRU ( F l o a t h e a d i n g ,
ton will eventually be in the NavMMI.DisableMode Binding binding ) {
NavMMI mmi = b i n d i n g . navMMI ( ) ;
state, which corresponds to the deactivation of the F l o a t t a r g e t H e a d i n g = mmi . g e t T a r g e t H e a d i n g (
navigation modes that depend on the IRU sensor. new T a r g e t H e a d i n g C o n t i n u a t i o n ( ) {
public F l o a t o n E r r o r ( ) {
Even if conformance and coherence cannot be return DEFAULT_VALUE; } } ) ;
return
fully guaranteed at design time, providing such c o n t r o l l e r P I D . compute ( h e a d i n g ,
validation support guides the design with regard targetHeading ) ;
}
to the high-level requirements. Indeed, when a }
property is not satisfiable, a counter-example is
generated by UPPAAL, helping the designer to Figure 8: Extract of the IntHeading context imple-
improve the DiaSpec specification. Moreover, our mentation
generative approach ensures that the implemen-
The inversion of control principle is uniformly
tation is conform to the design, preserving these
applied to an SCC-generated programming frame-
properties in the subsequent stages of the devel-
work to guarantee that the interaction between the
opment process.
components is conform to the design. Specifically,
the abstract methods to be implemented by the
developer are only called by the framework, ensur-
4 Implementation ing that a DiaSpec software system is compliant
with its DiaSpec design.
When developing dependable applications, a Similarly, the non-functional declarations are
key goal is to preserve the high-level requirements traceable throughout the implementation stage by
throughout the development process. To do so, generating dedicated programming support. For
the DiaSuite approach relies on a compiler that example, the IRU entity was declared in the tax-
generates a dedicated programming framework onomy (Figure 4) as raising FailureException
from a DiaSpec design. As depicted in Figure 2, errors. Consequently, a specific method is gen-
the compiler takes as input the DiaSpec specifica- erated in the corresponding entity abstract class
tion of the application and generates a dedicated to allow error signaling to be introduced by the
Java programming framework that ensures the developer when implementing an instance of this
conformance between the design and the imple- entity [Mercadal et al., 2010]. Another exam-
mentation [Cassou et al., 2011]. ple is the mandatory catch declaration in the
For example, Figure 7 shows the abstract IntHeading interaction contract presented in Fig-
class generated from the specification of the Int- ure 5. This declaration imposes the IntHeading
Heading context component. This abstract class implementation to handle potential errors when
requesting the targetHeading data from NavMMI. namely FlightGear [Perry, 2004], to simulate the
As shown in Figure 8, this mandatory error han- external environment.
dling is enforced by introducing a continuation Using a Java library that interfaces with Flight-
parameter in the method supplied to the devel- Gear, the testers can easily implement simulated
oper to request the targetHeading data (i.e., versions of entities. Figure 9 presents an extract
getTargetHeading). This continuation provides of the implementation of a simulated IRU.
a default value in case of an error. The SimulatedIRU entity is implemented by
Timing constraints specified at design time inheriting the AbstractIRU class, provided by the
are also traceable in the generated programming programming framework. To interact with the
framework. Indeed, these constraints are auto- simulated environment, the entity implements the
matically monitored in the programming frame- SimulatorListener interface. This interface de-
work [Gatti et al., 2011]. For instance, this mon- fines a method named simulationUpdated, which
itoring layer measures the time spent by the is called periodically by the simulation library.
IntHeading context component to retrieve the The model parameter allows to read/write the
targetHeading data. If this time is greater than current state of the FlightGear simulator. In
100 ms (as specified in Figure 5), an error is auto- Figure 9, the position of the plane is published
matically raised by the framework. by calling the publishPosition method of the
As shown in Section 3, the supervisory treat- AbstractIRU class.
ments are handled independently from the func-
tional treatments. This separation of concerns
allows a developer to focus on a specific non-
functional aspect. For example, the developer
of the DataAvailability context component can
concentrate on implementing algorithms to detect
data availability. Because of the programming
framework support, the developer does not need
to mix supervisory operations, to detect and han-
dle errors, with the functional treatments.
Figure 10: Screenshot of a simulated flight

5 Testing Once the simulated entities are implemented,


the flight guidance application is tested by con-
The implementation of each SCC chain can be trolling a simulated plane within FlightGear. An
tested independently. For example, the functional example of testing scenarios is to provide a desired
aspect of the application can be tested using a heading via the autopilot interface of the flight
simulated external environment. The taxonomy guidance application and to verify that the appli-
definition allows to validate the functional imple- cation controls the ailerons of the simulated plane
mentation using mock-up entities that rely on the as expected. Figure 10 presents a screenshot of
simulated environment. This is done without any our testing environment. In the main window, the
impact on the rest of the application. FlightGear simulator allows to control and visual-
ize the simulated plane. In the top-left corner, the
public c l a s s SimulatedIRU extends AbstractIRU
implements S i m u l a t o r L i s t e n e r {
autopilot interface allows testers to select a navi-
public SimulatedIRU ( FGModel model ) { gation mode. In this case, the "Route Manager"
model . a d d L i s t e n e r ( t h i s ) ;
} mode is selected to follow the flight plan defined
public void s i m u l a t i o n U p d a t e d ( FGModel model ) { via the map displayed in the bottom-left corner.
p u b l i s h P o s i t i o n ( model . g e t I n e r t i a l P o s i t i o n ( ) ) ;
} The simulated environment is also useful for
}
testing the supervisory SCC chains. Device fail-
Figure 9: Extract of the simulated IRU class ures can be directly simulated using FlightGear.
We also provide a simple testing support to inject
In avionics, it is required to verify the behavior errors from the simulated entities as illustrated
of the application in specific environmental con- by the FaultInjector window in the top-right
ditions. Because some scenarios are difficult to corner. Then, the window in the bottom-right
create (e.g., extreme flight conditions), we provide of the screenshot displays the errors monitored
a testing support that relies on a flight simulator, by the application. This particular testing sup-
port eases the verification of the conformance with matically preserved thanks to the generated pro-
the requirements such as the Req3 requirement gramming framework. Indeed, the support gen-
presented in Section 2.2 erated for error handling, such as in the Data-
Finally, it is required to realize integration test- Availability context component presented in
ing on a test bench to ensure that the application Section 4, prevents developers from implementing
behaves correctly for a specific deployment config- ad-hoc code for error propagation. Concerning
uration. An advantage of our simulation support the QoS declarations, the generated support con-
is that simulated and real entities can be com- sists of monitors integrated in the programming
bined in a hybrid environment. Indeed, as both framework. These guards do not ensure coherence
real and simulated versions of an entity extend the by themselves but guide the coherence verification
same abstract class, the nature of an entity has at runtime. Indeed, when a QoS contract is not
no impact on the rest of the application. Deploy- fulfilled, a specific exception is raised, pinpointing
ing an application on a test bench is a daunting the involved component.
task that has to be repeated each time an error is
detected. Testing by simulation may avoid some 6.2 Conformance
unnecessary deployments.
To ensure the conformance with respect to the
high-level requirements, we provide validation sup-
6 Assessment port along the development process. We illustrate
how this support guides the conformance verifica-
We now outline the benefits of our approach, tion using the Req3 requirement. This require-
focusing on the coherence and conformance verifi- ment indicates that the malfunction or failure of
cation. As shown in the previous sections, we have a sensor must be systematically signaled to the
developed an avionics flight guidance application pilot, within 300 ms.
and tested it on a realistic flight simulator, namely At design time, this requirement leads to the
FlightGear [Perry, 2004]. Additionally, we have specification of an SCC supervisory chain dedi-
duplicated this case study in the context of the cated to the signaling of the failure to the pilot.
commercial Parrot AR.Drone system.3 The early-verification support presented in Sec-
tion 3 allows to statically verify that an excep-
6.1 Coherence tional event raised by the IRU entity systematically
results in the triggering of the Display action on
To ensure coherence at design time, the DiaSuite the NavMMI entity.
methodology relies on a unique design language. At implementation time, the generation of
Unlike independent views (e.g., the collection of a programming framework ensures the confor-
UML diagrams), DiaSpec integrates functional mance of the application with the data and control
and non-functional declarations, contributing to flow specifications as demonstrated in previous
prevent most inconsistencies. For example, the work [Cassou et al., 2011]. However, the time-
coherence between error-handling declarations can related aspect of the Req3 requirement cannot be
be statically checked as they directly refine the verified at design time as it depends on runtime
interaction contracts describing the control flow. specificities (e.g., the properties of the execution
If the designer declares an entity as raising an platform). To ease the verification of such re-
exception, compile-time verifications ensure that quirements, the programming framework provides
there is an error-handling declaration for each dedicated monitors to detect the violation of the
component requiring data from this entity. Con- time-related constraints during the testing stage.
cerning the QoS declarations, their coherence is Moreover, the generated testing support provides
directly verified on the formal model generated error-injection capabilities, allowing to validate
from the DiaSpec specification. Indeed, any incon- the Req3 requirement, even if the IRU entity is
sistencies between the timing constraints result in not yet implemented.
a deadlock, as shown in Section 3.
At implementation time, the coherence be-
tween the error-handling declarations is auto- 7 Related Work
3
The DiaSpec specification and a video demonstrat-
ing this application are available at http://diasuite. Several design-driven development approaches
inria.fr/avionics/ardrone. are dedicated to dependable applications.
In the domain of architecture description lan- real-time systems. To allow the formal verifica-
guages, the Architecture Analysis & Design Lan- tion of a whole mechatronic system, the authors
guage (AADL) is a standard dedicated to real-time propose to develop a library of coordination pat-
embedded systems [Feiler, 2006]. AADL provides terns that define specific component roles, their
language constructs for the specification of soft- interactions and real-time constraints. Then, the
ware systems (e.g., component, port) and their components of the application are built using this
deployment on execution platforms (e.g., thread, library of patterns by specifying their roles and ad-
process, memory). Using AADL, designers specify ditional behavior details. The approach comprises
non-functional aspects by adding properties on lan- tool support for the specification, verification and
guage constructs (e.g., the period of a thread) or source code synthesis as a plug-in for the Fujaba
using language extensions such as the Error Model tool suite [Burmester et al., 2005]. The use of
Annex.4 The software design concepts of AADL coordination patterns can be seen as a paradigm
are still rather general purpose and give little guid- that guides the design of mechatronic systems.
ance to the designer. At the expense of generality, Contrary to ours, their approach does not pro-
our approach makes explicit domain-specific con- vide support for error handling but focuses on the
cepts in the design specification of dependable time-related aspects.
applications, namely sensors, contexts, controllers, Another development methodology for depend-
actuators. This approach enables further devel- able applications is SCADE (Safety Critical Ap-
opment support for the design, programming and plication Development Environment) [Dion, 2004].
testing stages. SCADE is based on a synchronous language and
As AADL is a standard, a lot of research has relies on hierarchical state machines for the speci-
been devoted to provide it with analysis and de- fication of dependable applications. An applica-
velopment tool support. For example, Dissaux tion is specified using state machines, enabling
et al. present performance analysis of real-time the verification of coherence at design time. The
architectures [Dissaux and Singhoff, 2008]. They synchronous paradigm ensures by construction
propose a set of AADL design patterns to model the determinism of a specification, and thus eases
real-time issues, such as thread synchronization. these verifications. The approach abstracts over
For each pattern, they list a set of performance physical time allowing real-time properties to be
criteria (e.g., the bounds on a thread waiting verified at the code level. Our design methodology
time due to access data) that can be checked is similar to this approach but lifts constraints
with a performance analysis tool [Singhoff et al., inherent to the determinism of the specification.
2004]. In comparison, our approach allows to spec- SCADE could be used to specify more precisely
ify timing constraints on component interactions, the internal behavior of critical DiaSpec compo-
enabling the verification of time-related proper- nents.
ties at a higher level of abstraction. As AADL
mainly focuses on deployment concerns, it is com-
plementary to our approach and could be used
for the deployment specification and analysis of
applications designed with DiaSpec. While most 8 Conclusion and Future Works
ADLs provide little or no implementation support,
the Ocarina environment allows the generation
of programming support dedicated to an AADL In this paper, we have shown the benefits of
description [Hugues et al., 2008]. However, this the DiaSuite methodology for the development
programming support consists of glue code for and the verification of dependable applications.
a real-time middleware and does not guide nor We have applied this methodology to a realistic
constrain the application logic implementation. case study in the avionics domain and covered the
In model-driven engineering, several ap- entire development process, from design to testing,
proaches focus on dependable applications. For leveraging an existing flight simulator.
example, Burmester et al. propose a develop-
ment approach dedicated to mechatronic sys- We are currently working on the specification
tems [Burmester et al., 2004]. This approach is of fault tolerance strategies to improve the gener-
based on a domain-specific extension of UML for ated support for error handling. Another direc-
tion concerns the deployment stage. We plan on
4 reusing existing avionics deployment technologies
The Error Model Annex is a standardized AADL
extension for the description of errors [Vestal, 2005]. to provide deployment support.
REFERENCES of the 14th European Conference on Fundamental
Approaches to Software Engineering, pages 217–
Amey, P. (2002). Correctness by Construction: Better 231.
Can Also Be Cheaper. CrossTalk: the Journal of Henzinger, T. A., Nicollin, X., Sifakis, J., and Yovine,
Defense Software Engineering, 2:24–28. S. (1994). Symbolic Model Checking for Real-
ARP-4761 (1996). ARP-4761, Guidelines and Methods Time Systems. Inf. Comput., 111(2):193–244.
for Conducting the Safety Assessment Process on Hugues, J., Zalila, B., Pautet, L., and Kordon, F.
Civil Airborne Systems and Equipment (SAE). (2008). From the Prototype to the Final Embed-
Avizienis, A., Laprie, J., Randell, B., and Landwehr, ded System Using the Ocarina AADL Tool Suite.
C. (2004). Basic Concepts and Taxonomy of ACM Transactions on Embedded Computing Sys-
Dependable and Secure Computing. Dependable tems, 7:1–25.
and Secure Computing, IEEE Transactions on, Lasnier, G., Zalila, B., Pautet, L., and Hugues, J.
1(1):11–33. (2009). OCARINA: An Environment for AADL
Behrmann, G., David, A., and Larsen, K. (2004). A Models Analysis and Automatic Code Generation
Tutorial on Uppaal. Formal methods for the for High Integrity Applications. Reliable Software
design of real-time systems, pages 33–35. Technologies–Ada-Europe 2009, pages 237–250.
Burmester, S., Giese, H., Hirsch, M., Schilling, D., Littlewood, B. and Strigini, L. (2000). Software Re-
and Tichy, M. (2005). The Fujaba Real-Time liability and Dependability: a Roadmap. In
Tool Suite: Model-Driven Development of Safety- ICSE’00: Proceedings of the Conference on The
Critical, Real-Time Systems. In ICSE’05: Pro- Future of Software Engineering, pages 175–188.
ceedings of the 27th International Conference on ACM.
Software Engineering, pages 670–671. ACM. Mercadal, J., Enard, Q., Consel, C., and Loriant, N.
Burmester, S., Tichy, M., and Giese, H. (2004). Mod- (2010). A Domain-Specific Approach to Architec-
eling Reconfigurable Mechatronic Systems with turing Error Handling in Pervasive Computing.
Mechatronic UML. In Proceedings of Model- In OOPSLA’10: Proceedings of the Conference
Driven Architecture: Foundations and Applica- on Object Oriented Programming Systems Lan-
tions (MDAFA 2004), Linköping, Sweden, pages guages and Applications, volume 45, pages 47–61.
155–169. Miller, S. (1998). Specifying the Mode Logic of a
Cassou, D., Balland, E., Consel, C., and Lawall, J. Flight Guidance System in CoRE and SCR. In
(2011). Leveraging Software Architectures to FMSP’98: Proceedings of the Second Workshop
Guide and Verify the Development of Sense/Com- on Formal Methods in Software Practice, pages
pute/Control Applications. In ICSE’11: Pro- 44–53. ACM.
ceedings of the 33rd International Conference on Perry, A. R. (2004). The FlightGear Flight Simulator.
Software Engineering, pages 431–440. ACM. In Proceedings of the USENIX Annual Technical
Cassou, D., Bertran, B., Loriant, N., and Consel, Conference.
C. (2009). A Generative Programming Ap- Shaw, M. (1995). Beyond Objects: A Software Design
proach to Developing Pervasive Computing Sys- Paradigm Based on Process Control. SIGSOFT
tems. In GPCE’09: Proceedings of the 8th In- Software Engineering Notes, 20:27–38.
ternational Conference on Generative Program- Singhoff, F., Legrand, J., Nana, L., and Marcé, L.
ming and Component Engineering, pages 137– (2004). Cheddar: a Flexible Real Time Schedul-
146. ACM Press. ing Framework. ACM SIGAda Ada Letters,
Cassou, D., Bruneau, J., Consel, C., and Balland, XXIV:1–8.
E. (2011). Towards A Tool-Based Development Taylor, R. N., Medvidovic, N., and Dashofy, E. M.
Methodology for Pervasive Computing Applica- (2009). Software Architecture: Foundations, The-
tions. Software Engineering, IEEE Transactions ory, and Practice. Wiley Publishing.
on, PP(99). Vestal, S. (2005). An Overview of the Architec-
Dion, B. (2004). Correct-By-Construction Methods for ture Analysis & Design Language (AADL) Error
the Development of Safety-Critical Applications. Model Annex. In AADL Workshop.
SAE transactions, 113(7):242–249. Volter, M., Stahl, T., Bettin, J., Haase, A., and Helsen,
Dissaux, P. and Singhoff, F. (2008). Stood and Ched- S. (2006). Model-driven Software Development:
dar: AADL as a Pivot Language for Analysing Technology, Engineering, Management. John Wi-
Performances of Real Time Architectures. In ley and Sons Ltd.
Proceedings of the European Real Time System Windsor, J. and Hjortnaes, K. (2009). Time and
conference. Toulouse, France. Space Partitioning in Spacecraft Avionics. In
Feiler, P. (2006). The Architecture Analysis & Design SMC-IT’09: Proceedings of the 3rd IEEE Inter-
Language (AADL): An Introduction. Technical national Conference on Space Mission Challenges
report, DTIC Document. for Information Technology, pages 13–20. IEEE.
Gatti, S., Balland, E., and Consel, C. (2011). A Step-
wise Approach for Integrating QoS throughout
Software Development. In FASE’11: Proceedings

You might also like