How to get the Port selected within the Architecture Model in System Composer?

1 vue (au cours des 30 derniers jours)
How to get the Port selected within the Architecture Model in System Composer?
This means you would like to get an object in the Workspace, this would be necessary for example to change the Stereotype programmatically.

Réponse acceptée

MathWorks Support Team
MathWorks Support Team le 2 Sep 2021
Modifié(e) : MathWorks Support Team le 17 Nov 2021
Right now there is no function implemented to do so.
But here you can find the files which are able to resolve the issue.
The first part is p-coded, because there are undocumented features in the script. We try to document these features in a future release in order to show the whole API.
The function is used to get the Port Handles inside the editor.
In order to use the functions, please download the attached files and run the function 'getSelectedPort' while having one or more Ports selected.
Then you will get the selected ports as an object in the MATLAB Base Workspace.
The API from System Composer which was used to write the function is documented here:

Plus de réponses (0)

Catégories

En savoir plus sur System Composer dans Help Center et File Exchange

Tags

Aucun tag saisi pour le moment.

Produits


Version

R2019a

Community Treasure Hunt

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

Start Hunting!

Translated by