Simulink: System Generator Model Warning

Hi Team,
I have this warning in my model developed in simulink in Vitis Model Composer (System Generator).
Warning: Getting parameter 'Parent' of the default block diagram will not be supported in a future release.
The model generates like 4000 warnings but i can't figure out how to remove it or where is the problem in my model.
Thank you all!

답변 (1개)

akshatsood
akshatsood 2023년 11월 6일
편집: akshatsood 2023년 11월 6일

0 개 추천

I understand that you are encountering several warnings in a model developed in Simulink. Have a look at the R2022a Release Notes attached herewith (with "get_param" highlighted) R2022a Release Notes
These mention that the use of "get_param(0,...)" will be deprecated and getting parameters of the default block diagram will not be supported in a future release. It is important to note that there is no problem with your model, rather the warnings are raised because of using "get_param" function to get the model parameters of the default block diagram.
For suppressing these warning, have a look at the following references
I hope this helps.

댓글 수: 4

Lucian George
Lucian George 2023년 11월 27일
편집: Lucian George 2023년 11월 27일
Thanks for your reply. I'll try to suppress this warning, executing the following comands:
model_name = 'Simulink_model_name';
set_param(model_name,'ReturnWorkspaceOutputs','on');
out = sim(model_name);
diag = getDiagnosticObjects(out);
Simulink.suppressDiagnostic(model_name,diag);
out = sim(model_name);
diag = getDiagnosticObjects(out);
However this not solve my problem. The getDiagnosticObjects returns always a struct with warning errors of this type (there are like 5000 warnings):
Is very annoing to have so much warning of this type.
How i can solve that? Can you provide me an example code pls.
Thank you very much.
-Lucian
akshatsood
akshatsood 2023년 11월 27일
Hi Lucian,
I understand your frustration regarding the warnings generated by the "getDiagnosticObjects" function on running the above set of commands. Could you please provide me with the model so that I can replicate the problem and provide a more accurate solution.
Thank You
Lucian George
Lucian George 2023년 11월 28일
Thank you for your fast reply. Unfortunately i can't provide the Simulink model for security reasons.
Can we try to solve the problem in a different way?
Thank you very much,
-Lucian
akshatsood
akshatsood 2023년 11월 30일
편집: akshatsood 2023년 11월 30일
Certainly, Lucian. I completely understand the security concerns. We can absolutely explore alternative approaches to address the issue you are facing with the Simulink model. Please execute the following command in the MATLAB command window to turn off all warnings.
warning('off','all');
Let me know if ths issue still persists
Thank You

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

카테고리

도움말 센터File Exchange에서 Startup and Shutdown에 대해 자세히 알아보기

제품

릴리스

R2022a

질문:

2023년 10월 30일

편집:

2023년 11월 30일

Community Treasure Hunt

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

Start Hunting!

Translated by