fmi-standard
fmi-standard copied to clipboard
Handling of time-based Clocks with interval=0
In section 2.3.5. State: Event Mode in the description of the fmi3SetClock function the following restriction is made for time-based clocks:
"Only time-based Clocks must not be active for more than one call of fmi3UpdateDiscreteStates per Event Mode."
This restriction contradicts the possibility for aperiodic time-based clocks to return an interval=0, which is possible according to the interval definition for, e.g., changing clocks:
The restriction should only be made for periodic clocks: "Only ~time-based Clocks~ periodic Clocks must not be active for more ..."
FMI Design Webmeeting:
Klaus: is it possible to call fmi3getInterval in event mode? Patrick: yes Klaus: This question sound familiar ... Implicitely we would make a time-based clock a triggered clock. This was perhaps the intention. Patrick: But allowing an interval=0 is a contradiction.
Does someone remember why we have it as it is defined currently?
Any new insights here?
"Only time-based-clock must not be active for more than one call of [fmi3UpdateDiscreteStates] per [Event Mode]"
is very hard to understand, it would be good to reformulate this phrase to be easier to read.
Yes, I agree that a changing clock (which is apriodic) can have a zero Time Interval. So it contradicts.
How would you propose to fix that? I think it makes sense to allow interval=0 for aperiodic and triggered clocks and to disallow it for periodic clocks.
I agree with this change..