INTO-CPS-Association / unifmu

A universal mechanism for implementing Functional Mock-up Units (FMUs) in various languages
41 stars 4 forks source link

FMU in Model Exchange standard #36

Closed LGentilePL closed 3 months ago

LGentilePL commented 3 years ago

Is it possible to generate FMUs in Model exchange standard through unifmu?

clegaard commented 3 years ago

I recently added defined the message types corresponding to the model exchange functionality. If there is interest in ME functionality, it should be relatively straightforward to introduce the functionality :)

LGentilePL commented 3 years ago

Hi, I am personally very interested. I am quite new to this kind of standard, and I struggle to understand the steps to follow. I suppose changing the modelDescription.xml is not enough because, looking at the functions implemented, I don't see

clegaard commented 3 years ago

cosimulation (CS) and model exchange (ME) are two fundamentally different ways of using FMUs. In a nutshell:

I have only ever used FMUs that implement the cosim part of FMI and it is my impression that it is the most commonly used type of FMU. Are there any specific features you need from ME?

LGentilePL commented 3 years ago

I am going to embed the model into the Modelica framework. At the moment, only CS FMUs 1.0 are supported but still not trivial to integrate. Contrarily, embedding ME 1.0 or 2.0 should be much easier.

clegaard commented 3 years ago

It seems that you are right: https://openmodelica.org/doc/OpenModelicaUsersGuide/v1.11.0/fmi.html#fmi-import

I am open to implementing support, however, I can't allocate time for implementing it at the moment. From the top of my head adding support would look something like:

If you are interested in helping, a good starting point would be an example of ME FMU written in python.

clagms commented 3 months ago

Hi @LGentilePL . I hope its ok with you that we close this. For the moment we do not have the capability to support ME. We're trying to get support for FMI 3.0 out asap though. Hope that's ok!