Cancel
Showing results for 
Search instead for 
Did you mean: 

Compilation Error: AMESim to Simulink interface

Experimenter
Experimenter

Hi,

 

I was just getting started with AMESim to Simulink Co-Simulation.

I am using LMS AMESim 15 and Matlab 2014b (64-bit) on Windows 7 (64-bit).

In advance I have carried out the installation orders for Windows SDK 7.1 to use the Visual C++ Compiler as described in: https://community.plm.automation.siemens.com/t5/1D-Simulation-Knowledge-Base/Tips-amp-tricks-How-to-...

 

Compiling the the skyhook example from LMS Amehelp lead to the error message:

"Make failed: Unable to create an executable for the System"

 

And the following compilation details:

 

C:\Program Files (x86)\LMS\LMS Imagine.Lab\v1500\Amesim\AMEcompile.bat initiates a 64 bit compilation

 

ERROR: The system was unable to find the specified registry key or value.

 

Setting SDK environment relative to C:\Program Files\Microsoft SDKs\Windows\v7.1\.

 

Targeting Windows 7 x64 Debug

 

 

 

 

Microsoft (R) Program Maintenance Utility Version 10.00.40219.01

Copyright (C) Microsoft Corporation. All rights reserved.

 

 

"C:\Program Files (x86)\LMS\LMS Imagine.Lab\v1500\Amesim\interfaces\simulink\win32\amemexcompile" cl.exe -c -DWIN32 -DAMESIMULINK -I"C:\Program Files\MATLAB\R2014b/extern/include" -I"C:\Program Files\MATLAB\R2014b/simulink/include" -I"C:\Program Files (x86)\LMS\LMS Imagine.Lab\v1500\Amesim/interfaces/simulink" -I"C:\Program Files (x86)\LMS\LMS Imagine.Lab\v1500\Amesim/interfaces" -I"C:\Program Files (x86)\LMS\LMS Imagine.Lab\v1500\Amesim\lib" -nologo -DWIN32 -MT -W3 -Od -D "_MBCS" -EHsc -wd4996 -bigobj -o skyhook_.obj skyhook_.c

 

.

Executing cl.exe "-c" "-DWIN32" "-DAMESIMULINK" "-IC:\Program Files\MATLAB\R2014b/extern/include" "-IC:\Program Files\MATLAB\R2014b/simulink/include" "-IC:\Program Files (x86)\LMS\LMS Imagine.Lab\v1500\Amesim/interfaces/simulink" "-IC:\Program Files (x86)\LMS\LMS Imagine.Lab\v1500\Amesim/interfaces" "-IC:\Program Files (x86)\LMS\LMS Imagine.Lab\v1500\Amesim\lib" "-nologo" "-DWIN32" "-MT" "-W3" "-Od" "-D" "_MBCS" "-EHsc" "-wd4996" "-bigobj" "-o" "skyhook_.obj" "skyhook_.c"

 

cl : Command line warning D9035 : option 'o' has been deprecated and will be removed in a future release

 

skyhook_.c

 

skyhook_.c(1138) : warning C4267: 'initializing' : conversion from 'size_t' to 'int', possible loss of data

skyhook_.c(1139) : warning C4267: 'initializing' : conversion from 'size_t' to 'int', possible loss of data

skyhook_.c(1140) : warning C4267: 'initializing' : conversion from 'size_t' to 'int', possible loss of data

 

skyhook_.c(1192) : warning C4267: 'initializing' : conversion from 'size_t' to 'int', possible loss of data

skyhook_.c(1193) : warning C4267: 'initializing' : conversion from 'size_t' to 'int', possible loss of data

skyhook_.c(1194) : warning C4267: 'initializing' : conversion from 'size_t' to 'int', possible loss of data

skyhook_.c(1239) : warning C4267: 'initializing' : conversion from 'size_t' to 'int', possible loss of data

skyhook_.c(1244) : warning C4267: '=' : conversion from 'size_t' to 'int', possible loss of data

 

skyhook_.c(1672) : warning C4267: '=' : conversion from 'size_t' to 'unsigned long', possible loss of data

skyhook_.c(1678) : warning C4267: '+=' : conversion from 'size_t' to 'unsigned long', possible loss of data

skyhook_.c(1690) : warning C4267: '=' : conversion from 'size_t' to 'unsigned long', possible loss of data

skyhook_.c(1696) : warning C4267: '+=' : conversion from 'size_t' to 'unsigned long', possible loss of data

skyhook_.c(1706) : warning C4267: '=' : conversion from 'size_t' to 'unsigned long', possible loss of data

skyhook_.c(1712) : warning C4267: '+=' : conversion from 'size_t' to 'unsigned long', possible loss of data

 

skyhook_.c(1792) : warning C4267: '=' : conversion from 'size_t' to 'int', possible loss of data

skyhook_.c(1817) : warning C4267: '=' : conversion from 'size_t' to 'int', possible loss of data

 

skyhook_.c(2018) : warning C4101: 'errmsg' : unreferenced local variable

 

skyhook_.make.link_args =

 

"c:/program files (x86)/lms/lms imagine.lab/v1500/amesim/libmec/submodels/win64/F000.obj" "c:/program files (x86)/lms/lms imagine.lab/v1500/amesim/libmec/submodels/win64/MECDS0A.obj" "c:/program files (x86)/lms/lms imagine.lab/v1500/amesim/libmec/submodels/win64/MECVS0A.obj" "c:/program files (x86)/lms/lms imagine.lab/v1500/amesim/libmec/submodels/win64/SPR000A.obj" "c:/program files (x86)/lms/lms imagine.lab/v1500/amesim/libmec/submodels/win64/FORC.obj" "c:/program files (x86)/lms/lms imagine.lab/v1500/amesim/libmec/submodels/win64/LCON13.obj" "c:/program files (x86)/lms/lms imagine.lab/v1500/amesim/libsig/submodels/win64/SPLT0.obj" "c:/program files (x86)/lms/lms imagine.lab/v1500/amesim/libmec/submodels/win64/MAS002.obj" "c:/program files (x86)/lms/lms imagine.lab/v1500/amesim/libmec/submodels/win64/XVLC01.obj" "C:/Program Files (x86)/LMS/LMS Imagine.Lab/v1500/Amesim/libsig/lib/win64/SIG.lib" "C:/Program Files (x86)/LMS/LMS Imagine.Lab/v1500/Amesim/libmec/lib/win64/MEC.lib" "C:/Program Files (x86)/LMS/LMS Imagine.Lab/v1500/Amesim/libhydr/lib/win64/HYDR.lib" "C:/Program Files (x86)/LMS/LMS Imagine.Lab/v1500/Amesim/libplm/lib/win64/PLM.lib" "C:/Program Files (x86)/LMS/LMS Imagine.Lab/v1500/Amesim/libmotion/lib/win64/AMEMOTION.lib"

 

"C:\Program Files (x86)\LMS\LMS Imagine.Lab\v1500\Amesim\interfaces\simulink\win32\amemex" -o skyhook_.mexw64 skyhook_.obj @"skyhook_.make.link_args" "C:\Program Files (x86)\LMS\LMS Imagine.Lab\v1500\Amesim\lib\win64\AME.lib" -link -nologo -NODEFAULTLIB:LIBCD.LIB -NODEFAULTLIB:LIBC.LIB -NODEFAULTLIB:LIBCMTD.LIB -NODEFAULTLIB:LIBCP.LIB -NODEFAULTLIB:LIBCPD.LIB

 

***************************************************

*

* Creating LMS Amesim => Simulink S-Function

* $Date: 2014-10-16 14:22:03 +0200 (Thu, 16 Oct 2014) $

*

* using MATLAB: 'C:\Program Files\MATLAB\R2014b'

* which seems to be a 64-bit MATLAB

*

*

***************************************************

.

Executing "C:\Program Files\MATLAB\R2014b\bin\mex.bat" skyhook_.obj @skyhook_.make.link_args @skyhook_objfilelist.txt

 

LINK : fatal error LNK1181: cannot open input file 'kernel32.lib'

 

 

 

Building with 'Microsoft Windows SDK 7.1 (C)'.

 

NMAKE : fatal error U1077: '"C:\Program Files (x86)\LMS\LMS Imagine.Lab\v1500\Amesim\interfaces\simulink\win32\amemex.EXE"' : return code '0xffffffff'

Stop.

 

\LMS\LMS was unexpected at this time.

 

It would be nice if anyone could help me with this issue.

 

Thanks in advance,

Valentin

 

4 REPLIES

Re: Compilation Error: AMESim to Simulink interface

Siemens Phenom Siemens Phenom
Siemens Phenom
Hi,

personally I still install Amesim and Matlab in paths without blank spaces i.e. no Program Files but D:/Amesim And D:/Matlab. I can't say if that would solve your issue but the "\LMS\LMS was unexpected at this time" lets me think it could be related.

Re: Compilation Error: AMESim to Simulink interface

Experimenter
Experimenter

Hi Emmanuel,

 

due to given Installation packages at my company I cannot choose the installation directory of Matlab.

However, I reinstalled AMESim in my C:\ directory.

 

I still get an error message similar to the one before, except for the last lines.

 

Instead of "\LMS\LMS was unexpected at this time."  I do now get

 

"For free edition of Microsoft Visual Studio, you may need to set the MSSDK environment variable to the installation directory of your MS Windows SDK

System build error!"

 

Re: Compilation Error: AMESim to Simulink interface

Siemens Phenom Siemens Phenom
Siemens Phenom
Hi Valentin,

try to define this MSSDK environment variable (user or system) if you can, on my machine it is set to:
MSSDK="C:\Program Files\Microsoft SDKs\Windows\v7.1"

Make sure to restart Amesim when you have done so.

If that still fail I advise you get in touch with the hotline (GTAC).

Re: Compilation Error: AMESim to Simulink interface

Experimenter
Experimenter
Ok thank you. Unfortunately this didn't do the trick.

I am now in contact with GTAC and will post any news on this issue.