- Follow the steps below to create a mask variable marked as a model argument: Create and Reference a Masked Model
- Then, convert the model reference to protected.
- Right click and select “Block Parameters” and add “.slxp” to the “Model name” field.
- Set the mask, save the model and simulate it.
How to select a structure as a tunable parameter for a protected model?
8 views (last 30 days)
Show older comments
I create a structure in base workspace then use it to configure my simulink subsystem through mask, everything goes well. But once I protect the subsystem, the subsystem configuration remains unchanged even if the structure in base workspace is changed, and I cannot select the structure as the tunable parameter for the generated protected model, how can I solve this problem?
0 Comments
Answers (1)
Alan
on 5 Aug 2025
Hello Haotian,
I assume you are providing a structure as a tunable parameter using the “Simulink.Bus” class. I am also not able to find tunable parameters while creating a protected model.
The following workflow is an alternate workflow I tried with Simulink R2025a and R2025a Update 1.
However, I was not able to edit the block parameters through the mask, even for variables of other data types, not just structures.
This could be a bug. The next step could be to reach out to MathWorks Technical support: Contact Support - MATLAB & Simulink
Regards,
Alan
0 Comments
See Also
Categories
Find more on Model Protection in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!