Error using mex file in S-function

Hi everyone,
I take a software package in this site: http://www.esi2.us.es/~eduardo/libro-s/libro.html
to simulate the plant in feedback control, but when i go to start the simulation some erros occur in simulink. The S-function don´t find the file, wich is a mex file. The files were created in matlab 4.2b, maybe this the reason for the error? If anyone can help me, i'll be greatfull. Sorry for my english. ;)
thx

回答 (2 件)

Fangjun Jiang
Fangjun Jiang 2011 年 10 月 10 日

0 投票

MATLAB 4.2b is too old. By looking at the year the book is published, the model probably was developed more than 15 years ago. The .mex files are in the package but probably are not compatible with the MATLAB version you are using.
Gustavo
Gustavo 2011 年 10 月 13 日

0 投票

So I need to modify the .mex files? How I convert .mex files to .m files?

2 件のコメント

Gagik Hakobyan
Gagik Hakobyan 2011 年 10 月 13 日
mex is executable file for matlab, so it can't be converted to .m file. You need to rebuild the sources using the if they are provided (using mex utility)
Fangjun Jiang
Fangjun Jiang 2011 年 10 月 13 日
.mex file is a binary file. Generally you can't convert .mex file to .m file. You best shot is to download the C version of the package, understand the details and develop the model yourself. Or, try to contact the author.

サインインしてコメントする。

カテゴリ

ヘルプ センター および File ExchangeBlock and Blockset Authoring についてさらに検索

質問済み:

2011 年 10 月 10 日

Community Treasure Hunt

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

Start Hunting!

Translated by