The OpenModelica FMI & SSP-based co-simulation environment.
OMSimulator can be used as:
pip install OMSimulator
)OMSimulator is also included with the OpenModelica installer, which includes OMEdit, a graphical editor.
Latest documentation:
Ensure you have initialized OMSimulator submodules:
git submodule update --init --recursive
Or, when cloning:
git clone https://github.com/OpenModelica/OMSimulator.git --recurse-submodules
Configure OMSimulator:
cd OMSimulator
cmake -S . -B build/ -DCMAKE_INSTALL_PREFIX=install/
Build and Install:
cmake --build build/ --target install
./install/bin/OMSimulator --version
Set Up OMDev:
git clone https://openmodelica.org/git/OMDev.git
OMDev/INSTALL.txt
Configure OMSimulator:
cd OMSimulator
cmake -S . -B build/ -G "MSYS Makefiles" -DCMAKE_INSTALL_PREFIX=install/
Build and Install:
cmake --build build/ --target install
./install/bin/OMSimulator --version
Open Visual Studio Command Prompt
Configure OMSimulator:
cd OMSimulator
cmake -S . -B build/ -DCMAKE_INSTALL_PREFIX=install/
Build and Install:
cmake --build build/ --config Release --target install
./install/bin/OMSimulator.exe --version
OMSimulator tests are automatically run on Jenkins, see latest test reports. To verify your build:
Build Test Dependencies:
cmake --build build/ --target testsuite-depends
Run Tests:
cd testsuite/partest/
./runtests.pl -j4
-jN
to specify N
threads.Testing requires the OMDev mingw shell:
Build Test Dependencies:
cmake --build build/ --target testsuite-depends
Run Tests:
cd testsuite/partest/
./runtests.pl -j4 -platform=win
-jN
to specify N
threads.