Creating and exporting FMU > FMU Export via scripting
Principle of operation
The name of the script is: fmi_export.pyc.
The location of the script is: %AME%\interfaces\fmi under Windows, or $AME/interfaces/fmi under Linux.
The script must be called using the Python distribution provided with Simcenter Amesim, the AME environment variable must be set to the Simcenter Amesim installation path.
Call under Windows:
%AME%\python.bat %AME%\interfaces\fmi\fmi_export.pyc <ame_model> <FMI_type> <FMI_version> [options]Call under Linux:
$AME/python.bat $AME/interfaces/fmi/fmi_export.pyc <ame_model> <FMI_type> <FMI_version> [options]
| Arguments and options | |
|---|---|
| ame_model | Full path of the amesim model file [MANDATORY] |
| FMI_type | Type of FMU: model exchange (me) or co-simulation (cs) [MANDATORY] |
| FMI_version | FMI standard version 1.0, 2.0 or 3.0 [MANDATORY] |
| -h | Displays the script help and does nothing else |
| -F [LOG_FILE] | Create a log file whose full path is LOG_FILE, by default: interf.log |
| -L LOG_LEVEL | Adjust the log level to LOG_LEVEL: {CRITICAL,ERROR,WARNING,INFO,DEBUG} |
| -a FMU_ARCH | Add a target platform and architecture to the FMU [MANDATORY at least one] |
| -o OUT_PATH | Set the output path where the FMU will be created |
| -v visibility_level | Set the visibility level of the FMU to {all, watch, none} |
| -e | Embed Amesim model table [HIGHLY RECOMMENDED] |
| -c | Prepare tool coupling FMU |
| -g | Compile the FMU in debug mode |
| -d | Add direct derivatives capability |
| -l | Generate a FMU license free |
| -deps | Add external dependencies required by some specific models |
| -omp | Option for specific tire submodels requiring OpenMP |
Source: https://docs.sw.siemens.com/en-US/doc/254352342/PL20250521841123434.amesim_collection.Functional_Mockup_Interface/xid2290030 · retrieved 2026-07-17