在尝试使用Simulink中的fmu文件模拟模型时遇到了一个问题:
我将Modelon FMI工具箱用于Dymola / Simulink接口,将模型交换类型的fmu文件(版本1.0)导入到Simulink模型中。我有一个Matlab m文件,该文件以编程方式依次模拟模型,在下一次模拟中保存模型的最终内部状态以进行初始化。模拟的第一次迭代运行时没有错误,但在第二次迭代中,Matlab在模拟调用时返回以下错误:
module = partial_run_sim2/BasicModels.System_model_final_Sim, log
level = ERROR: [][FMU status:Error] fmiInitialize: dsblock_ failed,
QiErr = 1
module = partial_run_sim2/BasicModels.System_model_final_Sim, log level =
ERROR: [][FMU status:Error] Possible errors (non-exhaustive): 1. The
license file was not found. Use the environment variable
"DYMOLA_RUNTIME_LICENSE" to specify your Dymola license file. 2. The
model references external data that is not present on the target
machine, at least not with the same location. Error reported by
S-function 'sfun_fmu_me_1_0' in