[Error] - SubSystem block does not have a parameter named 'u'

11 次查看(过去 30 天)
I have a simple simulink model,
  1. two states - On and OFF
  2. one output - y, attached to a scope
  3. one parameter - u
  4. transition rules - when u < 0 goto OFF, when u > 0 go to ON
I'm trying to do the following from the workspace,
set_param ('Model/Block','u','1')
and I'm getting 'subsystem block does not have a parameter named 'u''...all I want to do is to toggle the parameter 'u' from 0 to 1 and 1 to 0 to observe the effect on the scope..
Can someone plz point out where I have gone wrong?
Many thanks, Luke
  1 个评论
A Jenkins
A Jenkins 2013-9-1
编辑:A Jenkins 2013-9-1
Can you be more clear about what kind of parameter 'u' is? Is it a constant block? A mask parameter? A parameter in the model workspace?
Try
get_param('Model/Block', 'ObjectParameters')
to see what you are allowed to set.

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Subsystems 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by