Using Simscape Model (code generated or just protected) to run Simulation on PC with just Matlab/Simulink

조회 수: 8 (최근 30일)
Would it be possible to use Simscape blocksets/Simscape sourcecode in a Simulink model, which could be used by another system (having just Matlab/Simulink/Stateflow licence) to run the SImulation? If yes, how to proceed with it? Thank you.

답변 (2개)

Javier Gazzarri
Javier Gazzarri 2023년 7월 24일
Hello Hitesh. This is indeed possible and there are a couple of options:
1) Create a Protected Model Reference as described here: Explore Protected Model Capabilities - MATLAB & Simulink (mathworks.com). This is a good option to share models that the user can re-parameterize while not having access to the subsystem's details.
Both cases require you to use sensors and sources from Simscape so that the boundaries are crossed by Simulink signals, as opposed to physical connections.
Please let me know if this helps.
Javier
  댓글 수: 1
Hitesh
Hitesh 2023년 7월 25일
Hello @Javier Gazzarri, thank you for your response. As I don't have Simulink Coder licence, I am trying the second option. Is it possible to carry out the second option (i.e create an FMU) without creating a project?

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


Javier Gazzarri
Javier Gazzarri 2023년 7월 25일
Hi Hitesh,
Yes, you don't need to create a project for this. From the top level of the model, please go to:
SAVE -> Standalone FMU
and follow the directions. This will create a file with .fmu extension whose name you can then use in the Simulink's FMU block. The latter will be functional as the original model but concealed from the user.
Best regards,
Javier
  댓글 수: 1
Hitesh
Hitesh 2023년 7월 26일
@Javier Gazzarri, thank you for your response. As I can't see the option of Standalone FMU in save drop down Menu. I presume Simulink Compiler licence would be required for FMU creation and that is the reason I can't save as Standalone FMU. Could you please confirm the same?

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

카테고리

Help CenterFile Exchange에서 Create Standalone FMU에 대해 자세히 알아보기

제품


릴리스

R2023a

Community Treasure Hunt

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

Start Hunting!

Translated by