BoundsError access Bool #65
Replies: 2 comments 3 replies
-
Okay, I just called the success, simData = fmiSimulate(myFMU, 0.0, 10.0; recordValues=["mass.s"]) but when I remove Is this a good idea to have the function interface change on a optional argument? I expected it to save all variables when I don't specifically tell fmiSimulate what I want to save, but instead it saved nothing. |
Beta Was this translation helpful? Give feedback.
-
Believe it or not: We already had this discussion internally :-D Should a function always return the same pattern? There are pros and cons, but we decided to don't return "dummy"-values if they are not needed/used. On the other hand many languages don't support this return feature, so for developers from these languages this behaviour is a bit unexpected. We decided to use the language features of Julia in this case. (you can call But I am open for other opinions of course! BTW: I will move this to discussions. |
Beta Was this translation helpful? Give feedback.
-
Description
When I simulate a FMU generated from the Modelica Standard Library I get a bounds error.
How to reproduce
Consider the following minimal example with a CS-ME 2.0 FMU
Modelica.Mechanics.Translational.Examples.Damper.fmu
generatet from OpenModelica (OMCompiler v1.19.0-dev.505+ga499198eb3):The error message:
OMSimulator can simulate the FMU fine, so I guess it is not an issue with the FMU. But I didn't test a non-OpenModelica tool on it.
Additional files
Here is the FMU (remove the .zip file extension) with Linux binaries:
Modelica.Mechanics.Translational.Examples.Damper.fmu.zip
Version 'n stuff
OS: Ubuntu 20.04
Julia:
OpenModelica: OMCompiler v1.18.1 and v1.19.0-dev.505+ga499198eb3
Beta Was this translation helpful? Give feedback.
All reactions