フィルターのクリア

How to run simulink and m-file simulataneouly?

1 回表示 (過去 30 日間)
Harinee Kannan
Harinee Kannan 2017 年 4 月 11 日
コメント済み: Harinee Kannan 2017 年 4 月 14 日
I have been trying to get data from simulink and use it in m-file but since the size of the simulink output is 1000001x1 i am not able to process the data effectively. So,is there a way to prpocess the data from simulink during simulation it self like an online process. What are the procedures or functions to be used?

採用された回答

Sebastian Castro
Sebastian Castro 2017 年 4 月 11 日
Looks like it would be easier to process the data in Simulink by calling the MATLAB code from the model.
The typical way of doing this is by taking your existing function and calling it in a MATLAB Function block ( See example ).
Note that if your MATLAB file does things that are not supported for code generation, like plotting, user input, certain functions, you will have to either change your code or tell Simulink to run it using the MATLAB interpreter ( See documentation ). This is fine so long as you're staying within MATLAB/Simulink and do not need to generate code from your model.
- Sebastian
  1 件のコメント
Harinee Kannan
Harinee Kannan 2017 年 4 月 14 日
Thank for the help.

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeSimulink Functions についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by