Problem with Building tmc-file / tmx-file from Simulink Model to load into Twincat 3
61 次查看(过去 30 天)
显示 更早的评论
After i installed the TE14xx Toolbox from Beckhoff, to compile a C++ - Code to represent my Simulink Model in Twincat3, i receive the following error Message.
All components that are required are installed. VS2019, test mode within Windows for signing the certificates and the drivers and of course the certificate that has been created. It looks like I am missing a toolset for compiling. What strange is that along with VS2019 I also have the latest MSVC v142 buildtools.
I think it is a very easy solution for this, but i cannot see it.
Is their a point where i have to link the compiler to matlab?
Warning: No appropriate platform toolset was found
ERROR: Unable to find compatible C++ platform toolset version.
ERROR: Can't create log file "C"
### Starting build procedure for: AnBeckhoff
################################################################################
### Starting TwinCAT TE1400 Simulink Model Verification
### Model Name: AnBeckhoff
### MATLAB Version: R2021b (win64)
### TE1400 Version: 2.3.1.1
################################################################################
################################################################################
### Generating code and artifacts to 'Model specific' folder structure
### Generating code into build folder: C:\test\AnBeckhoff_tcgrt
### Invoking Target Language Compiler on AnBeckhoff.rtw
### Using System Target File: C:\TwinCAT\Functions\TE14xx-ToolsForMatlabAndSimulink\TE140x\Simulink\TLC\TwinCatGrt.tlc
### Loading TLC function libraries
### Initial pass through model to cache user defined code
### Caching model source code
### Writing header file AnBeckhoff_types.h
### Writing header file AnBeckhoff.h
### Writing header file rtwtypes.h
### Writing header file multiword_types.h
### Writing source file AnBeckhoff.cpp
### Writing header file AnBeckhoff_private.h
### Writing header file rtmodel.h
.
### Writing source file AnBeckhoff_data.cpp
### Writing header file rt_nonfinite.h
### Writing source file rt_nonfinite.cpp
### Writing header file rtGetInf.h
### Writing source file rtGetInf.cpp
### Writing header file rtGetNaN.h
.
### Writing source file rtGetNaN.cpp
### TLC code generation complete.
....### Creating HTML report file index.html
### Saving binary information cache.
.
### Processing Template Makefile: C:\TwinCAT\Functions\TE14xx-ToolsForMatlabAndSimulink\TE140x\Simulink\TLC\tcgrt_msbuild.tmf
### Makefile C:\test\AnBeckhoff_tcgrt\AnBeckhoff.mk is up to date
################################################################################
### Starting TwinCAT TE1400 Simulink Model Export
################################################################################
Warning: Unable to get handle of subsystem <S51>: Unable to locate Simulink Coder block or system name '<S51>' in model 'AnBeckhoff'
Model hierarchy export finished successfully
Warning: No appropriate platform toolset was found
ERROR: Unable to find compatible C++ platform toolset version.
ERROR: Can't create log file "C"
[Info]
[Info#ModuleGenerator]
ProductId: TE140x
ProductName: TE140x-TargetForMatlabSimulink
Version: 2.3.1.1
InstallDir: C:\TwinCAT\Functions\TE14xx-ToolsForMatlabAndSimulink\TE140x
SDK: C:\TwinCAT\Functions\TE14xx-ToolsForMatlabAndSimulink\TE140x\SDK
[Info#ModuleGeneratorHost]
Description: MATLAB 9.11.0.1837725 (R2021b) Update 2 (win64)
InstallDir: C:\Program Files\MATLAB\R2021b
[Info#TE140x]
SDK: C:\TwinCAT\Functions\TE14xx-ToolsForMatlabAndSimulink\TE140x\SDK
[Create Project]
[Export Classes]
[Export Classes#License]
[License#AnBeckhoff]
Warning: ExportAnBeckhoff
[Generate#AnBeckhoff#TcCom]
Implement interfaces
### Build procedure for AnBeckhoff aborted due to an error.
Build Summary
Top model targets built:
Model Action Rebuild Reason
======================================================================
AnBeckhoff Failed Code generation information file does not exist.
0 of 1 models built (0 models already up to date)
Build duration: 0h 0m 14.445s
The call to TwinCatGrt_make_rtw_hook, during the after_make hook generated the following error:
Project preparation failed
The build process will terminate as a result.
Caused by: Project preparation failed
0 个评论
回答(2 个)
Taranjit Singh
2022-8-8
Were you able to solve this problem ?
2 个评论
Fabian Bause
2022-11-4
Hi,
I am not aware of any issues of our TwinCAT Targets with Visual Studio 2019. Maybe you missed to install the C++ develeopent kits with VS2019? You need to select those manually when installing VS2019. Also it is important to first install VS with C++ kit and then install TwinCAT 3. TwinCAT 3 creats platformtoolsets on top of the toolsets provided by the C++ kit. If they do not exist, TwinCAT does not install the TwinCAT platformtoolsets.
Anyway, I am happy to hear that you have a running developement system.
If further questions arise regading our TwinCAT Target for Simulink or TwinCAT Target for MATLAB, please don't hesitate to contact your local Beckhoff Support Team.
Thanks,
Fabian
(Product management TwinCAT)
gregory pais
2023-10-31
Hi,
I had this issue with same messages
Warning: No appropriate platform toolset was found
ERROR: Unable to find compatible C++ platform toolset version.
I ran vs_installer.exe from "C:\Program Files (x86)\Microsoft Visual Studio\Installer"
To check my VS installation and if Visual C++ was correcty installed.
But two products was installed:
- Visual Studio build tools 2019
- Visual Studio Community 2019
This issue was solved after deinstalation of VS build tools
0 个评论
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!