Message Boards Message Boards

GROUPS:

Cannot import or simulate FMU from JModelica2.4 due to different platforms

Posted 9 months ago
1351 Views
|
4 Replies
|
1 Total Likes
|

Hi,

since my work depends on the fluid subpackage from modelica, I have to build the model in OpenModelica and then compile it with JModelica2.4 by using a 32-bit python version on a Windows 10 system. This took me some time to figure it out, but so far so good.

However, I am currently failing to load and simulate the model in SystemModeler 12 on Windows. The following error message appears persistently:

Building "DH_Test_fmu" as experiment "DH_Test_fmu 1" started at 17:56:44 
[:0:0-0:0] Error: Assertion triggered during translation: "Imported FMU does not support the current platform (as determined by ModelicaServices.target=i686-pc-win32), supported platforms: x86_64-pc-win32"
Build finished at 17:57:44 (took 01:00).
Error: No executable generated C:/Users/xxx/AppData/Local/Temp/WolframSystemModeler-12.0/sme.12.0.0_1564156604_23281.exe
Error: No settings file generated C:/Users/xxx/AppData/Local/Temp/WolframSystemModeler-12.0/sme.12.0.0_1564156604_23281.sim

So far I have tried to set different compiler options in JModelica, for example FMU-ME, FMU-CS as well as FMU-ME/CS. But all without success. I have managed to built, compile and simulate a small test model with SystemModeler. At the moment I am not sure what to do next.

I'm asking for help, Yours sincerely

4 Replies

Your FMU seems to be compiled as a 64-bit DLL so you need to build your simulations as a 64-bit executable. You can change that in Tools > Options > General > Compiler, change target to x86_64.

Otto

He seems to be saying 32bit support interface was dropped and has no explanation for the lack of care.

If you can do as he suggests depends upon whether you control it (in which case your time is burned not his) or you do not (meaning the modules were purchased and will never be re-released ever).

Nothing has been dropped, but if you have a 64-bit FMU you need to compile your simulation as a 64-bit application. Now, he clearly controls both ends (since he compiled the FMU him self) so he has two options

  1. Configure JModelica to compile a 32-bit FMU and stick to 32-bit simulations in SystemModeler.
  2. Configure SystemModeler to compile a 64-bit simulation and stick to 64-bit FMUs from JModelica.

I know how to do 2 so that is what I can suggest, for 1 I would suggest to search for help in a more appropriate place.

Otto

Posted 8 months ago

Dear Otto,

Thank You for your fast and straightforward assistance. My problem could be solved with solution 2.

Kind regards Frank

Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract