Info

이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.

How to work on objects in the workspace from Simulink

조회 수: 1 (최근 30일)
FP24
FP24 2018년 9월 4일
마감: MATLAB Answer Bot 2021년 8월 20일
I'm using the Automated Driving Toolbox, for example. It provides some objects data type (vehicle, actor, drivingScenario) that i use in matlab, but i can not use them (read or modify) from the simulink model, also if these objects are already defined in the base workspace that this simulink model can access.
Thank you in advance for you help Cheers

답변 (1개)

TAB
TAB 2018년 9월 5일
If these objrcts are not supported by any Simulink toolbox, then you can not use them directly in Simulink.
But you can extract required numeric values/array/matrix from these objects, save them in base workspace and use them for further processing in Simulink.
For value extraction you can run your Matlab code/function in Model Callback or Block callback functions of simulink.
  댓글 수: 1
FP24
FP24 2018년 9월 7일
thanks. But if I need to use some functions (provided in the same toolboxes) on these objects? For example I need the function targetOutlines(ac), where ac is an actor object defined in the Automated Driving Toolbox. How can I do? Thank you again

제품


릴리스

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by