How to set Stateflow properties in Stateflow Model Explorer using matlab script?
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Shady Nada
le 22 Juin 2018
Modifié(e) : Shady Nada
le 26 Juin 2018
Hi all, I know that in Simulink Block Properties / Handles can be called and set using the set_param and get_param commands, respectively. How to do so for Stateflow Model Explorer Properties using matlab script?
>> Example: I have a model called “TestModel.mdl” which contains a Stateflow Chart “MyChart” at a deeper level: ‘TestModel/SubSystem_A/MyChart’. I would like to Add Data in the Model Explorer by means of a command in a m-file, with example properties;
Name: "PresParam_A"
Scope: Parameter
Size: <empty>
Complexity: Off
Type: Double
0 commentaires
Réponse acceptée
Fangjun Jiang
le 22 Juin 2018
Modifié(e) : Fangjun Jiang
le 25 Juin 2018
clear;close all;
sfnew;
rt=sfroot;
ch=rt.find('-isa','Stateflow.Chart');
d1=Stateflow.Data(ch)
then specify the properties of the data
3 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Programmatic Model Editing dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!