How to change Simulink Block properties from Command Window
6 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Yatish Chandra Chitluri
el 20 de En. de 2021
Comentada: Fangjun Jiang
el 20 de En. de 2021
Hello Everyone,
I'm trying to change a block properties from command window.
For example, in, "Revolute Joint: Revolute" How to change Torque from None to Automatically Computed.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/494584/image.png)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/494589/image.png)
I'm trying to use, "set_param" but It is not usefull.
Can someone please help me.
Thanks in advance.
Regards,
Yatish.
0 comentarios
Respuesta aceptada
Fangjun Jiang
el 20 de En. de 2021
set_param('YourBlockPath','TorqueActuationMode','ComputedTorque')
2 comentarios
Fangjun Jiang
el 20 de En. de 2021
Usually here web(fullfile(docroot, 'simulink/slref/block-specific-parameters.html#bvegf16')) but this is a masked parameter so you need to follow masked parameters.
I set the block parameter manually and use get_param() to get the actual value.
Más respuestas (0)
Ver también
Categorías
Más información sobre Programmatic Model Editing en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!