MATLAB: How to set parameters of a M-S-Function on a simulink model from GUI?

guim-s-functionMATLABparameterssimulink

Hi there! I know that we can use 'set_param' to change a parameter in one simulink block from a MatLab GUI. http://www.mathworks.fr/fr/help/simulink/slref/set_param.html
But I use a Level2 M-S-Function block on a simulink model that uses two parameters. How can I change those parameters during the simulation of the model through the GUI??
Thank you very much!
Natxo

Best Answer

just in case you're as dumb as me, if you're looking for the answer: Remember that a MS Function is just another block, so you can access its parameters like another one:
Build a string like : params = 'val_param1 , val_param2 , val_param3...'
set_param('Path_to_your_block','Parameteres', params );
And there you go (at least, it worked for me).
Related Question