I'm trying to create a time varying system in simulink using matlab function block but even if the logic is correct it says the value which i'm calling form workspace is not Simulink.Signal

조회 수: 3 (최근 30일)
function y = fcn %#codegen for i=1:1:100 U_b(:,i)=x_storage(14,i)-(K(1,:,i)'*(X_bar(i,:)')); end y = U_b;
K,x_storage, X_bar comes from workspace and i've changed the data type to data store memory I tried to use the input option also it did not work out. X_bar is a syms data type

답변 (1개)

Zhao Wang
Zhao Wang 2016년 9월 28일
This happens maybe because you have an object defined in the base workspace and you are using a data store with the 'Data store name must resolve to Simulink signal object' option checked. Since you set the name of the data store to be the same as the name of the object (or a variable) in the base workspace, this error occurs because the object type is not 'Simulink.Signal'. Consider changing the name of the data store or the object. Alternatively, consider unchecking the 'Data store name must resolve to Simulink signal object' option.
  댓글 수: 1
sabyasachi Neogi
sabyasachi Neogi 2016년 9월 29일
My target is to bring the object or variable(3-d matrices) from the base workspace to the matlab function block so the first option can't be done. Regarding the unchecking the 'Data store name must resolve to Simulink signal object' option where i will find the check box to uncheck it.Unable to locate in model explorer.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Modeling에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by