MATLAB Answers

Can I call variables from a mask dialogue box in an Embedded MATLAB function block without having to connect variable blocks

78 ビュー (過去 30 日間)
Diarmaid
Diarmaid 2012 年 9 月 11 日
コメント済み: Walter Roberson 2019 年 10 月 25 日
Hi,
I'm looking to use an Embedded MATLAB Function block to calculate two output variables based on a selection of user inputs into the dialogue box.
I've chosen the Embedded MATLAB Function block due to an S-Function block seeming complicated.
As the function is developing the number of inputs to the block is becoming unwieldy, since I'm connecting constant blocks declaring the variables explicitly and connecting them. Is there a simpler way?

  0 件のコメント

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

採用された回答

Kaustubha Govind
Kaustubha Govind 2012 年 9 月 11 日
編集済み: Rik 2019 年 10 月 25 日
Yes, you can convert your inputs to parameters (whose names must match that of the workspace variables). You simply need to change the "Scope" from Input to Parameter on the Ports and Data Manager.

  4 件のコメント

表示 1 件の古いコメント
Azzi Abdelmalek
Azzi Abdelmalek 2014 年 2 月 24 日
Kaustubha, I don't know what happened to your link: Ports and Data Manager, it should be

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

その他の回答 (0 件)

Community Treasure Hunt

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

Start Hunting!

Translated by