structure variable with double vectors in a field using in a SIMEVENT block is not working
2 ビュー (過去 30 日間)
古いコメントを表示
Hi together,
I actually have a problem even with a structure variable with double vectors in a field using in a SIMEVENT block.
I created a struct with 17 fields and I get an error, if i try to include it in simevents entity and server block called ROS(1).L2_3.
if i type isstruct(ROS) or isstruct(ROS1) i get true, and isvector(ROS(1).L2_3) is also true but i get the follwoing issue:
"Data type of parameter 'ROS' is not supported in event actions. For more information about supported data types, see Supported data types in the documentation. "
The strange thing is, that it worked once, and i can not remember, that i changed anything...
But the answer in https://de.mathworks.com/matlabcentral/answers/316166-structure-of-variables-in-simevents clearly says, that structs are usable.
When i save ROS(1).L2_3 into a new plain variable, i can use it. But what i wanne achieve, is to use more than one of the variable in the struct ROS(1) per mask parameter of the uper subsystem block and this subsystem block is copied 17 times and uses ROS(x) with different x. Is there any easier solution to that?
Regards,
Christoph
Here you can visually see what im trying to achieve and what the error is
0 件のコメント
回答 (1 件)
Abdolkarim Mohammadi
2020 年 12 月 11 日
One way to achieve what you want is composite entities. It enables you to use a structure-like dot notation in event actions. See:
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Discrete-Event Simulation についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!