0

I am using:

I can't run dymola.simulateModel. If I do I get this error, which is quite long:

dymola.dymola_exception.DymolaFunctionException: Failed to parse JSON response. Invalid \escape: line 1 column 3152 (char 3151) {"result": "Translation of <a href=\"Modelica://Modelica.Mechanics.Rotational.Examples.CoupledClutches\">Modelica.Mechanics.Rotational.Examples.CoupledClutches</a>:\nThe DAE has 106 scalar unknowns and 106 scalar equations.\n\nStatistics\n\nOriginal Model\n  Number of components: 14\n  Variables: 180\n  Constants: 21 (21 scalars)\n  Parameters: 53 (56 scalars)\n  Unknowns: 106 (106 scalars)\n  Differentiated variables: 14 scalars\n  Equations: 98\n  Nontrivial: 79\nTranslated Model\n  Constants: 36 scalars\n  Free parameters: 39 scalars\n  Parameter depending: 6 scalars\n  Continuous time states: 8 scalars\n  Time-varying variables: 51 scalars\n  Alias variables: 51 scalars\n  Number of mixed real/discrete systems of equations: 1\n  Sizes of linear systems of equations: {13}\n  Sizes after manipulation of the linear systems: {4}\n  Sizes of nonlinear systems of equations: { }\n  Sizes after manipulation of the nonlinear systems: { }\n  Number of numerical Jacobians: 0\n\nSelected continuous time states\nStatically selected continuous time states\n  clutch1.phi_rel\n  clutch1.w_rel\n  clutch2.phi_rel\n  clutch2.w_rel\n  clutch3.phi_rel\n  clutch3.w_rel\n  J1.phi\n  J1.w\n\nError: Compilation of <a href=\"Modelica://Modelica.Mechanics.Rotational.Examples.CoupledClutches\">Modelica.Mechanics.Rotational.Examples.CoupledClutches</a> failed.\n\nNote: There were translation errors that might explain the problem.\nCompiler message:\n \nCompiling and linking the model (Visual C++). \n \n**********************************************************************\n** Visual Studio 2017 Developer Command Prompt v15.9.50\n** Copyright (c) 2017 Microsoft Corporation\n**********************************************************************\n[vcvarsall.bat] Environment initialized for: &#39;x86&#39;\ndsmodel.c\n   Bibliothek &quot;dymosim.lib&quot; und Objekt &quot;dymosim.exp&quot; werden erstellt.\nlibds.lib(udsshare.obj) : warning LNK4049: Lokal definiertes Symbol &quot;_sprintf&quot; wurde importiert.\nlibds.lib(dymf2c.obj) : warning LNK4049: Lokal definiertes Symbol &quot;_sprintf&quot; wurde importiert.\nlibds.lib(usertab.obj) : warning LNK4049: Lokal definiertes Symbol &quot;_sprintf&quot; wurde importiert.\nlibds.lib(dsres.obj) : warning LNK4049: Lokal definiertes Symbol &quot;_sprintf&quot; wurde importiert.\nlibds.lib(mess.obj) : warning LNK4049: Lokal definiertes Symbol &quot;_sprintf&quot; wurde importiert.\nlibds.lib(dymtable.obj) : warning LNK4049: Lokal definiertes Symbol &quot;_sprintf&quot; wurde importiert.\nlibds.lib(dslin.obj) : warning LNK4049: Lokal definiertes Symbol &quot;_sprintf&quot; wurde importiert.\nlibds.lib(matrixop.obj) : warning LNK4217: Lokal definiertes Symbol &quot;_sprintf&quot; wurde in _Real2String-Funktion importiert.\nlibds.lib(delay.obj) : warning LNK4049: Lokal definiertes Symbol &quot;_sprintf&quot; wurde importiert.\nlibds.lib(dserr.obj) : warning LNK4049: Lokal definiertes Symbol &quot;_sprintf&quot; wurde importiert.\nlibds.lib(dsadd.obj) : warning LNK4049: Lokal definiertes Symbol &quot;_sprintf&quot; wurde importiert.\nlibds.lib(amat.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;__imp____iob_func&quot;.\nlibds.lib(dymosim2.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;__imp____iob_func&quot;.\nlibds.lib(aprint.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;__imp____iob_func&quot;.\nlibds.lib(dsres.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;__imp____iob_func&quot;.\nlibds.lib(rsyaux.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;__imp____iob_func&quot;.\nlibds.lib(matrixop.obj) : error LNK2019: Verweis auf nicht aufgel\366stes externes Symbol &quot;__imp___vsnprintf&quot; in Funktion &quot;_ModelicaFormatError&quot;.\nlibds.lib(delay.obj) : error LNK2019: Verweis auf nicht aufgel\366stes externes Symbol &quot;__imp__printf&quot; in Funktion &quot;_delayget&quot;.\nlibds.lib(localeless.obj) : error LNK2019: Verweis auf nicht aufgel\366stes externes Symbol &quot;__imp___fscanf_l&quot; in Funktion &quot;_fscanfC_Bracket_255s&quot;.\nlibds.lib(localeless.obj) : error LNK2019: Verweis auf nicht aufgel\366stes externes Symbol &quot;__imp___sscanf_l&quot; in Funktion &quot;_sscanfCd&quot;.\nlibds.lib(localeless.obj) : error LNK2019: Verweis auf nicht aufgel\366stes externes Symbol &quot;__imp___vsprintf_l&quot; in Funktion &quot;_sprintfC&quot;.\nlibds.lib(localeless.obj) : error LNK2019: Verweis auf nicht aufgel\366stes externes Symbol &quot;__imp___vfprintf_l&quot; in Funktion &quot;_fprintfC&quot;.\nlibds.lib(localeless.obj) : error LNK2019: Verweis auf nicht aufgel\366stes externes Symbol &quot;__imp___vsnprintf_l&quot; in Funktion &quot;_vsnprintfC&quot;.\nlibds.lib(mess.obj) : error LNK2019: Verweis auf nicht aufgel\366stes externes Symbol &quot;__imp__sscanf&quot; in Funktion &quot;_MyHandleRequest&quot;.\nlibds.lib(rsyaux.obj) : error LNK2019: Verweis auf nicht aufgel\366stes externes Symbol &quot;__imp__fprintf&quot; in Funktion &quot;_rsyspg_&quot;.\nlibds.lib(amat.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;__imp__fprintf&quot;.\nlibds.lib(l_prikey.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;___iob_func&quot;.\nlibds.lib(lm_pconf.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;___iob_func&quot;.\nlibds.lib(lm_free_job.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;___iob_func&quot;.\nlibds.lib(l_check.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;___iob_func&quot;.\nlibds.lib(lm_perror.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;___iob_func&quot;.\nlibds.lib(lm_init.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;___iob_func&quot;.\nlibds.lib(http_lib.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(l_validdate.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(lm_chk_conf.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(lm_crypt.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(l_msghello.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(l_master_lis.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(l_pack.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(l_wdec.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(l_package.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(lm_crstr.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(lm_feat_list.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(l_get_lfile.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(l_get_id.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(l_init_file.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(lm_get_redir.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(l_parse_attr.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(l_encode.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(l_borrow.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(l_allfeat.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(flex_version_sig.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(lm_ckout.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(l_check.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(l_date.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(lm_getid_typ.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_sscanf&quot;.\nlibds.lib(lm_pconf.obj) : error LNK2019: Verweis auf nicht aufgel\366stes externes Symbol &quot;_fprintf&quot; in Funktion &quot;_ofIvx7SqNtK1B5kO3s&quot;.\nlibds.lib(l_check.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_fprintf&quot;.\nlibds.lib(lm_perror.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_fprintf&quot;.\nlibds.lib(lm_init.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_fprintf&quot;.\nlibds.lib(l_prikey.obj) : error LNK2001: Nicht aufgel\366stes externes Symbol &quot;_fprintf&quot;.\nlibds.lib(lm_init.obj) : error LNK2019: Verweis auf nicht aufgel\366stes externes Symbol &quot;_vsprintf&quot; in Funktion &quot;_kPJ76ESxaBOx_mV&quot;.\ndymosim.exe : fatal error LNK1120: 14 nicht aufgel\366ste Externe\n \nError generating Dymosim. \n \nErrors were found\nError: Did not find finalNames element:  J1.w,\n J4.w in call to simulateExtendedModel.\n = false, {0.0, 0.0}\n", "error": null, "id": 6}

Thanks for the effort you put in to help me

2 Answers2

2

Dymola 2017 FD01 supports Visual Studio 2015 (and earlier versions), and you used Visual Studio 2017.

It may work without being officially supported, but that is somewhat complicated by the breaking changes in stdio-library introduced in Visual Studio 2015 (and figuring out that it is needed for an unknown Visual Studio version).

I would first try to investigate if you can translate models in Dymola without using the Python interface. Or just upgrade Dymola to a later version.

Hans Olsson
  • 11,123
  • 15
  • 38
1

Dymola 2017 FD01 supports the Microsoft Visual Studio 2015, both the Express and Professional edition. The error message that you have attached shows that you have used MSVS 2017. You can use MSVS 2015 or a lower version of MSVS. [Different compiler options in Dymola FD01] 1. When I changed the compiler settings to MSVS 2017, I got a error in compilation. The error message says that it fails to link the model to the C++ compiler because it is using an unsupported MSVS compiler. [Compiler Error Message while using MSVS 2017] 2 . This could be the issue in your case, you can try to use a lower version of MSVS to overcome this issue.