PhD thesis defense.
Summary: Cyber-physical systems (CPSs) are becoming ever more important in both industry and our everyday lives. A CPS integrates software components (cyber) with physical components. Typically, the software controls physical processes, such as motors or other actuators, based on sensor input. Examples of CPSs are airplanes, modern cars and industrial production line robots. These systems are highly complex systems that are constructed of many components working together. The system components have a multidisciplinary nature, as a system might contain mechanical components, electrical components and software components. Every discipline has its own development methods and tools and, in the end, all separately developed components should work together as one system.
Using a model-based development approach, all disciplines develop component models using their own tools and development cycles. While these individual component models may be simulated to verify their behaviour, it is hard to simulate them together to get a better understanding of the designed system as a whole. Co-simulation of the models provides means to analyse the system behaviour before building a prototype and to check the collaboration of the components. Several techniques exist that support the co-simulation of many simulations. Examples are the High Level Architecture (HLA) and Functional Mock-up Interface (FMI) standards. HLA provides an interface and a set of rules to orchestrate a co-simulation execution, while FMI provides an interface for communicating with the simulation models. Both open source and commercial implementations of HLA are available and FMI is widely supported by modelling tools. The construction of a co-simulation using these standards, however, introduces a significant additional workload for the system designers. Especially when the component models change frequently during the design process, adapting these changes in the co-simulation framework quickly becomes a blocking factor.
This dissertation introduces a domain-specific language (DSL) called CoHLA that supports existing model-based methodologies for the design of CPSs to rapidly construct a co-simulation of the system under design. CoHLA uses the HLA standard for the co-simulation execution and the FMI standard to support simulation models created in many different modelling tools. Its aim is to minimise the overhead for developing and maintaining a co-simulation during the development. CoHLA allows the system architects to quickly specify simulation models in terms of input and output attributes, after which the co-simulation itself can be specified by connecting these attributes. Source code for the co-simulation framework is generated from the co-simulation specification.
The CoHLA framework features basic logging as well as the specification of reusable parameter configurations for the co-simulation. Additionally, it supports the measurement of basic performance metrics, the specification and replay of scenarios, fault injection and basic design space exploration. A collision detection extension that uses 3D drawings of the system's components to detect potential collisions was also implemented. This extension can also be used to render the system during the co-simulation execution to provide visual feedback to the user.
A number of case studies were conducted with CoHLA to analyse different aspects of the approach. A co-simulation of a domestic heating system was used as a basic example of a CPS to design using CoHLA. In collaboration with the University of Twente a slider system was designed and built that reflects relevant design aspects for industry such as collision detection. This case study showed that CoHLA enabled the construction of a co-simulation in an early phase during the design of a system, which also revealed potential design flaws in an early stage. Consequently, these errors could be addressed early in the design process. Even though the models changed from time to time throughout the development, these changes could be adapted quickly - within an hour - using CoHLA.
To analyse the trustworthiness of the co-simulation results, the impact of the HLA implementation and the CoHLA framework on the simulation timing has been measured. For one sample system, the co-simulation results from a CoHLA co-simulation were compared to the results when executing the same models in one integrated simulator. Even though small differences were found, the results were very similar. The results from a CoHLA co-simulation were also compared to an established co-simulation project by running identical co-simulations. Since these results were also nearly identical, the co-simulation results from a co-simulation as generated by CoHLA appear to be trustworthy.
Systems such as Internet of Things (IoT) systems are a class of CPSs that consist of large numbers of sensors and actuators. A case study on a smart lighting system was used as an example of an IoT system that could be designed following a similar approach using CoHLA. The focus of this case study was to analyse the scalability of HLA and CoHLA. Experiments were conducted by running the co-simulations in a distributed manner using a commercial cloud provider. The impact of distributing the individual simulations over a number of computation nodes was analysed. It was found that HLA scales rather good when distributed over a number of nodes. To simplify the specification of a smart lighting system in CoHLA, a separate DSL was developed. The approach of introducing a new DSL to specify a specific type of system proved to be beneficial for a specific set of systems.
Using co-simulation during system design allows for early system analysis and the development of system-level features. With CoHLA, the construction of a co-simulation from simulation models of different disciplines becomes less time consuming compared to other approaches. Also, adapting changes of the models in the co-simulation requires less effort, which makes the approach suitable for maintaining the co-simulation throughout the system design process.