Use Case: Integrating Functional Mock-up Units for HIL Simulation
This use case demonstrates how functional mock-up units (FMUs) from different vendors can be integrated to make one real-time-capable application for hardware-in-the-loop (HIL) simulation.
The Use Case
The system consists of an electronic stability program (ESP) ECU connected to a dSPACE SCALEXIO HIL system with dSPACE ControlDesk and AURELION for controlling and visualizing the simulation run, and dSPACE ConfigurationDesk for integrating the models into one application.
Starting point is an existing ESP ECU HIL testing system with all model parts realized with dSPACE Automotive Simulation Models.
The objective is now to replace some parts of the virtual vehicle simulation model with new ones developed according to a physical modeling (acausal) approach, and with other tools than Simulink, providing export of the model as FMUs.
The vehicle dynamics and environment model remain modeled with dSPACE Automotive Simulation Models. The original engine and drivetrain ASM models were replaced by real-time-capable C code FMUs based on the Functional Mock-up Interface. The sample time of all the integrated model parts is 1 ms.
The screenshot is an example of the model communication interface in Simulink with the drivetrain FMU. Model port blocks are used to create the ports representing the FMU interface in the Simulink model. This interface can be analyzed and connected via ConfigurationDesk.
ConfigurationDesk is the graphical configuration and implementation software for SCALEXIO hardware, the MicroAutoBox III, and MicroLabBox II. The two FMUs are imported into ConfigurationDesk and integrated with the existing simulation model. This is done by connecting the FMU interfaces with the model port blocks created in Simulink to make one real-time-capable application. This overall simulation model is then downloaded onto the SCALEXIO HIL simulator. In this case model communication with Simulink is used to integrate the FMUs into the existing simulation model. Alternatively, an FMU could also be connected directly to I/O channels or to other FMUs in ConfigurationDesk.
ControlDesk is used to start and control the simulation run. The photorealistic experiment layouts give an impression of what the car dashboard can look like.
All model variables and parameters, such as the yaw rate, brake pressure and velocity, are displayed and plotted in real time during the simulation run to give you constantly up-to-date information about what is happening.
The system tests the functionalities of an ESP ECU. The same simulation scenario – a car braking on a slippery road – is performed twice for comparison: once with the ESP ECU turned off and once with it turned on.
AURELION visualizes the simulation run so that you can see how the car is behaving. In the first simulation run with the ESP ECU turned off, the car starts to skid during braking and spins round.