I have to change function visibility of simulink function block using M-Script.
2 ビュー (過去 30 日間)
古いコメントを表示
I have simulink function block in which I have to change functional visibility scoped to global using M-Script commands. How to do this?![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1387859/image.png)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1387859/image.png)
0 件のコメント
回答 (1 件)
Suman
2024 年 7 月 31 日
Hi Umesh,
In order to modify some dialog parameter value, you can find out the actual parameter name in the following way:
>> path = 'model_name/Simulink_Function_block_name/trigger_port_block_name';
>> get_param(path, 'DialogParameters');
This will give you all the dialog parameters for the block that can be modified programatically using the get_param, set_param functions.
For a trigger port, inside the Simulink Function subsystem block, you will find a "FunctionVisibility" property. You can set its value using the set_param function:
>> set_param(path, 'FunctionVisibility', 'global');
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Programmatic Model Editing についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!