Opened 5 years ago

Last modified 5 years ago

#5820 new defect

OMJulia ModelicaSystem - BouncingBall.mo! NotFound

Reported by: Oliver Lenord Owned by: Adrian Pop
Priority: high Milestone:
Component: OMJulia Version: v.1.15.0-dev
Keywords: Cc:

Description

Following the example at https://openmodelica.org/doc/OpenModelicaUsersGuide/latest/omjulia.html

using OMJulia
mod = OMJulia.OMCSession()
ModelicaSystem(mod,"BouncingBall.mo","BouncingBall")

I get the error message:
BouncingBall.mo! NotFound

Do I need to set a path or anything?

(There is no component OMJulia, therefore I assigned it to OMPython.)

Change History (2)

comment:1 by Adrian Pop, 5 years ago

Component: OMPythonOMJulia
Keywords: OMJulia removed
Owner: changed from Alachew Mengist to Adrian Pop

Yes, you need to full path to the mo file. In Windows that's in the installation directory
share/doc/omc/testmodels.

comment:2 by Oliver Lenord, 5 years ago

Using "./MyModel.mo" for a model stored in the work directory finally worked for me.

Would be good to mention the prerequisites for successfully running a test code.

I'm still wondering why the following doesn't work:

ModelicaSystem(mod, "Modelica.Electrical.Analog.Examples.CauerLowPassAnalog", ["Modelica"])
Modelica.Electrical.Analog.Examples.CauerLowPassAnalog! NotFound
Note: See TracTickets for help on using tickets.