Archived OpenModelica forums. Posting is disabled.

Alternative forums include GitHub discussions or StackOverflow (make sure to read the Stack Overflow rules; you need to have well-formed questions)


Forgot password? | Forgot username? | Register

FMU Import (Co-Simulation)

FMU Import (Co-Simulation)

Hi everyone,

i tried to import a FMU (from RecurDyn) to OmEdit (1.12.0, x64) on Win10. The FMU version is 1.0 and "Co-Simulation" (FMI2.0 doesn't work in OmEdit and fails with error message that FMI2.0 is not supported).

When to co-simulate, RecurDyn should open, load its model file (.rdyn) and start to simulate (with animation). I have tested the FMU with FMUChecker and it seems ok.

When i start simulation (compilation finished successfully), i get following output messages:
c:/Users/Robert/AppData/Local/Temp/OpenModelica/OMEdit/Test.exe -port=51069 -logFormat=xmltcp -override=startTime=0,stopTime=10,stepSize=0.001,toleranze=1e-6,solver=dassl,outputFormat=mat,variableFilter=.* -r=Test.res.mat -w -lv=LOG_STATS


[INFO][RDFMICS][log][FMU status:OK] fmiSetDebugLogging: loggingOn=0

The initialization finished successfully without homotopy method.
    fmiInitializeSlave,....
   
    endtime = 1.00000000
   
=== Error Message ======================================

The RecurDyn model has already opened or isn't in working foler. (sic!)

=== Error Message ======================================

The RecurDyn model has abnormally stopped.

...


Last error message, i get hundreds of times. RecurDyn does not open or start its application! So, no Co-Simulation is in process.

I think it is a simple path problem, but i have also tried unsuccessfully:
-Importing FMU and set/unset unzipping path manually. I copied my .rdyn-File to unzip path.
-Copying my .rdyn-File also to working path (-> got path from "Tools"->"Open Working Directory")
-Synchronized time steps with FMU, also time end.
-I have also edited the XML from the FMU to an absolute file path for the .rdyn-File.
-I have set to debug level when importing the FMU, i get some additional lines in my output:
[INFO][RDFMICS][log][FMU status:OK] fmitGetReadl: #r151# = 0
[INFO][RDFMICS][log][FMU status:OK] fmitGetReadl: #r152# = 0
[INFO][RDFMICS][log][FMU status:OK] fmiDoStep: currentCommunicationPoint = 0e-99,
and so on.

Some other mysterious things:
-No batch-file is created to start RecurDyn - is this correct? From others tools i recognized there will be a batch file created to start RecurDyn.
-In RDFMICS_cs_st_FMU.mo there is on second line:
constant String fmuLocation = "file://c:/Users/Robert/AppData/Local/Temp/OpenModelica/OMEdit/resources";
This path does not exist (and is also not created)! I have also tested with manually creating the path and copying all possible files (FMU, unzipped FMU, xml, .rdyn etc.) to this path. Also same errors.

Some additional notes:
-After importing the FMU, i see the FMU in the navigator and it seems to be ok (FMI1CoSimulation with constructor, destructor and fmi1Functions ...)
-Check of the model: All seems to be ok: "Check of RDFMICS_cs_st_FMU completed successfully. Class RDFMICS_cs_st_FMU has 4 equation(s) and 4 variable(s). 2 of these are trivial equation(s)."
-I have also tested with nightly build (1.13.0) from 10-10-18: Same problems.

My questions:
-What am i doing wrong?
-Is FMI1.0-Co-Simulation possible with/in OmEdit when the FMI slave application needs to be started? I have also tried to simulate a FMU1.0Co-Simulation from another programm a while ago and it also fails, but it seems there was a bug with the FMU itself (FMUChecker generated errors) and not with OmEdit.

Thanks in advance for your help!

Greetings,
Robert





There are 0 guests and 0 other users also viewing this topic