Using a custom simscape component with a mask and promoted parameters gives warning that workspace variable already exist

I have a custom simscape component that is used in a model where a mask is applied to the component. The needed parameters are promoted so that the values can be entered in the model. When the model is run, warning are generated that the "The workspace variable 'xxxx' for block 'YYYYYY' already exist" for each parameter that is promoted. I cannot find a way to resolve the warnings, as I would like to use the masked block multiple times and the warning would be a major nuisance. Using R2016b, did not try in a previous version. Any suggestions?

Réponses (1)

Steve Miller
Steve Miller le 31 Jan 2018
Modifié(e) : Steve Miller le 31 Jan 2018
I tested this in R2016b and R2017b and it worked for me. See file attached to this answer. If you can attach your example, we could take a closer look.
Check Best Practices for Promoting Parameters to Mask for other things that might need adjusting.

Catégories

En savoir plus sur Foundation and Custom Domains dans Centre d'aide et File Exchange

Produits

Community Treasure Hunt

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

Start Hunting!

Translated by