This is an optional module that enables co-simulation capabilities in Chrono::Engine.
Read the introduction to modules for a technical background on the modularity of the Chrono::Engine project.
The COSIMULATION module allows users to perform cosimulation with other software that accept data exchange via TCP/IP sockets.
The most relevant case is the cosimulation with the Simulink product, to simulate subsystems like controls, pneumatic systems or electric circuits that interact with Chrono::Engine mechanisms.
The Simulink technology is well known for its ease of use: it is a graphical tool built on top of Matlab that allows the building of control systems, pneumatic and hydraulic circuits, drivetrains, electrical power systems, etc. By adopting a co-simulation approach, you can simulate, for example, an excavator bow with Chrono::Engine and its hydraulic subsystems with Simulink.
Here are the main features:
- easy C++ functions to send/receive datagrams using TCP/IP sockets from Chrono::Engine
- a CEcosimulation.mdl block is provided, to be inserted in your Simulink models as a ready-to-use interface to Chrono::Engine
- examples are provided.
- To run applications based on this module:
- To build this module:
- you must have a socket library (both Linux and Windows have these by default and you should not need to install any library)
- Repeat the instructions for the full installation, but when you see the CMake window, you must add the following steps:
- Set the
ENABLE_MODULE_COSIMULATIONas 'on', then press 'Configure' (to refresh the variable list)
- Press 'Configure' again, then 'Generate', and proceed as usual in the installation instructions.
Anyway, currently, only examples and files for Simulink are provided.