This repository contains the agenda and materials for the FMI Beginner's tutorial presented at the 16th International Modelica & FMI Conference.
A Video Recording is available on YouTube
| Time | Topic |
|---|---|
| 13:30 | Introduction to the FMI (Christian Bertsch) |
| 14:15 | Working with FMUs (Claudio Gomes) |
| 14:45 | Break |
| 15:15 | Connecting Multiple FMUs (Maurizio Palmieri) |
| 16:00 | Outlook to FMI 3.0 (Christian Bertsch) |
| 16:20 | Q&A |
| 16:30 | End Tutorial |
Presentation covering
- MATLAB/Simulink (optional)
- Dymola (optional)
- the motivation and history of FMI
- general technical concepts
- tool support
- an outlook on FMI 3.0
- FMU export (in Dymola: open
MODELICA_Demo.Driveexport it as a source code FMU) - FMU import in MATLAB/Simulink
Live demo + Jupyter notebook
- Validation of FMUs on the Website
- Validate and simulate FMUs with fmusim
- work with FMUs in FMPy
- set up FMPy (with mambaforge)
- open GUI, create file association, create desktop shortcut
- view the model info
- view the documentation
- simulate the Drive FMU and plot the result
- create an input CSV file
- set the stop time, parameters, output interval (loadInertia1.J = 10)
- validate the Drive FMU
- compile platform binary for the Drive FMU
- log debug info and FMI calls + short discussion of FMI calling sequence
- generate a Jupyter notebook from the FMU and run it
- Optional requisites for following along in the live demo:
- fmpy
- Have a Google account that you can use for Google Colab.
- Create a Container FMU with fmpy
- Simulate the container FMU in fmpy or fmusim
- Using Google Colab, run the Jupyter notebook found in part3/tutorial_multiple_FMUs
- Measure Accuracy of the Co-simulation Wrt to Baseline
- Co-simulation Scenario with Baseline
- Impact of Step Size on the Accuracy
Slides can be downloaded here.
FMI 3.0 examples:
- Outlook on FMI 3.0 Features
- Synchronous Clocks Example
Code and documentation copyright (C) 2023 the Modelica Association Project FMI. Code released under the 2-Clause BSD License. Docs released under Attribution-ShareAlike 4.0 International.
We are thankful to Torsten Sommer for his contributions to this tutorial materials, and to Kenneth Lausdahl as well as the other developers of the INTO-CPS tool and Maestro. In addition, part of this work has been supported by the DIGIT-Bench project (case no. 640222-497272), funded by the Energy Technology Development and Demonstration Programme (EUDP).
