embeded matlab function

조회 수: 1 (최근 30일)
harish bharadwaj
harish bharadwaj 2011년 7월 27일
hi,
i am using matlab funtion in my simulink module. i am using matlab2010a version. whenever i run this module an error has been displaying as there is no appropriate compiler and check for it using mex -setup.......could anyone please give solution for this
Thanks

답변 (2개)

Fangjun Jiang
Fangjun Jiang 2011년 7월 27일
You type the following line in Command window and then follow instructions:
mex -setup
  댓글 수: 2
harish bharadwaj
harish bharadwaj 2011년 7월 28일
i tried this but did not work
Fangjun Jiang
Fangjun Jiang 2011년 7월 28일
I merely explain that error message to you. Did you run it? What C compiler do you have? MATLAB provides the lcc compiler. What error do you have now when you try to simulate the model? Do you use "Fcn" block, or "MATLAB Fcn" block or "Embedded MATLAB Function" block? You got to be specific and provide more details about your question.

댓글을 달려면 로그인하십시오.


Arnaud Miege
Arnaud Miege 2011년 7월 28일
Have a look on the MathWorks web site at the list of supported compilers.
Embedded MATLAB Function blocks use C code generation, and that C code needs to be compiled with a C compiler, so you need to have one installed. As already mentioned, the way to set up the C compiler for use with MATLAB and Simulink (once it's installed on your machine) is to run mex -setup.
For more details, see the documentation about Building MEX-Files.
HTH,
Arnaud

카테고리

Help CenterFile Exchange에서 Introduction to Installation and Licensing에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by