modelica / fmi-standard

Specification of the Functional Mock-up Interface (FMI)
https://fmi-standard.org/
Other
274 stars 85 forks source link

Where tunable parameters in FMI-Cosimulation can be updated? #1134

Closed masoud-najafi closed 4 years ago

masoud-najafi commented 4 years ago

In FMI-2.0 for CS, tunable parameters can only be updated at communication steps. In FMI-3.0, shouldn't restrict the update of tunable parameters to EventMode (similar to FMI-for-ME)? If yes, the table 10 in section 4.1.2 should be reviewed.

TorstenBlochwitz commented 4 years ago

If we restrict the change of tunable variables to Event Mode we cannot change them for FMUs which do not support Event Mode (hasEventMode = false) and in case of co-simulation algorithms which do not use Event Mode (eventModeRequired == fmi3False during instantiation).

For that reason I would propose to allow changes of tunable parameters in:

chrbertsch commented 4 years ago

Ticket-Reviewing-Meeting

Andreas: this gets more complicated with the XCP layered standard. An MCD tool would assume that changes immediately take effect Pierre: We have the same problem with SCP servers with real ECUs ... Christian: one should write recommendations for XCP within the layered standard , not in the FMI3 standard

Andreas: in which mode shall we not change tunable parameters. Pierre: If we have event mode, tunable parameters should only change in event mode. In non-event-CS FMUs, it should be possible to change them just as discrete inputs. Pierre: this forbids changes in intermedidateUpdateModel Klaus: what about configuration and reconfigurationMode? do we have to distinguish between tunable parameters and structural tunable parameters? Can one change inputs etc. in (re)configuration mode. Andreas: One should not allow more than in event mode Klaus: I want to avoid to allow changes to non-structural parameters in (re-)configuration mode Pierre: everything else (i.e., other tunable parameters) should be changed in event mode. Implicitely, if one wants reconfiguration, one needs event support.

@andreas-junghanns : I will create a PR for this

andreas-junghanns commented 4 years ago

This was essentially already marked out in the document as such. I added a few clarifications, cross references and cleaned up some left-overs in the PR I will link to this issue in a few minutes.