MEX Function Build with Visual Studio
1 view (last 30 days)
Show older comments

I had Simulink model and have generated C code from MATLAB. Basically Simulink Model has many functions and one S-Function with file extension .mexw32 (hex code). The process of C-code generation is working without any error. Now that I have C-code and header files of my model, I wanted to build the solution file(.bat file) from these files with Visual Studio.
When I tried to build the files then I am getting error as shown in attached picture. What I conclude is, there is a problem with the .mexw32 file to build. I dont have source code (c code) for these S-function .mexw32 file. I think that could be the problem while building the solution.
Do I need source code to build the solution or that doesnt matter if I have it or not? Because only the .mexw32 file is causing the problem during buiding the solution.
I am using cnp.tlc (CANape Target Lang. compiler) for code generation. Is there anything that I shall change in config. panel for code generation to generate code?
1 Comment
Mark Zurawski
on 15 Feb 2020
It looks like you are using the Vector defined TLC for this, but you are using some functions that may not have associated TLC files for the code generation. It may be that those functions are not intended for code generation. You may need to use alternative functions if those .mexw32 were only intended for Matlab only operations.
Answers (0)
See Also
Categories
Find more on Target Language Compiler in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!