Rust FMU Runner library
A high level Rust wrapper for executing FMU's that follow the FMI 2.0 standard.
This library contains bindings to the fmi-standard and offers a high-level, safe API for unpacking, parsing, loading and executing FMU's.
Example
use ;
use ;
let fmu = unpack?
.load?;
let fmu_cs = instantiate?;
let signals = fmu_cs.lib.variables;
fmu_cs.setup_experiment?;
// Set initial height to 10m.
fmu_cs.set_reals?;
// Initialize model.
fmu_cs.enter_initialization_mode?;
fmu_cs.exit_initialization_mode?;
// Step model 1 second.
fmu_cs.do_step?;
// Get the current height.
let outputs = fmu_cs.get_reals?;
println!;