How to write customer struct in TLC file for inline SFunction C++?

I have already rebuilt my C++ code in SFunction, and use "mex xxxxxx.cpp xxxxx.cpp " to run normal.
Next, I want to transform this SFunction to inline SFunction, and meet some problems.
In my code, I use
"typedef struct
{
}PIDController;
"
A customer struct, and work well.
Now, I want to use it in tlc file, how to do it?
Thank you all!!!

댓글 수: 3

Additional, this struct is init in mdlstart, and update in mdloutput.
Hello everyone, this is a simple PIDController S-Function, work well in mex and cannot work in inline mode.
Maybe there is some mistake in mine tlc file, can someon help me?

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

 채택된 답변

sy
sy 2024년 6월 2일

0 개 추천

I have done it.
Hope this could help someone.

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Simulink Coder에 대해 자세히 알아보기

제품

릴리스

R2022a

질문:

sy
2024년 5월 31일

답변:

sy
2024년 6월 2일

Community Treasure Hunt

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

Start Hunting!

Translated by