フィルターのクリア

Matlab coder returning non specific issue description during check for runtime issues step

3 ビュー (過去 30 日間)
Jonathan Elgavi
Jonathan Elgavi 2023 年 6 月 7 日
回答済み: Sachin Lodhi 2023 年 11 月 15 日
Hello,
For use in a student project, I am attempting to convert an audio-based transmitter/receiver function from Matlab to C/Cpp.
I went through the process of correcting various issues, brought up by the Matlab coder tool.
However, the latest issue brought up by the "Check for run-time issues" step does not mention any line / sub-function in the code. Instead, it simply states:
" Insufficient number of outputs from right hand side of equal sign to satisfy assignment.
Use help codegen for more information on using this command.
Insufficient number of outputs from right hand side of equal sign to satisfy assignment."
I do not know where in the code this issue is located, and given the project size, I would prefer not to start looking with no clear leads.
The function I am trying to convert is running correctly, and no issues are found before the runtime issues check (input types, %#codegen, etc.).
Any help in accessing a more detailed error message / pointing me in the right direction would be greatly appreciated.
Thanks (:
Jonathan
  1 件のコメント
Sakshi Sharma
Sakshi Sharma 2023 年 6 月 9 日
Hi could you please provide code and more details to look into the issue? Thanks

サインインしてコメントする。

回答 (1 件)

Sachin Lodhi
Sachin Lodhi 2023 年 11 月 15 日
Hi Jonathan,
Based on my understanding, it seems that you are encountering an issue when utilizing the MATLAB Coder tool.
The error usually arises when there's a naming conflict in the code, such as when the output variable name is the same as the function name. For instance -
[stft, t, f]= stft(x,wlen,nfft);
In the above function, the output variable on the left side is 'stft', and the function name on the right side is also 'stft' which is causing the error. You should look for similar errors in your code.
Alternatively, the issue could also be due to a variable in your MATLAB program that shares its name with an inbuilt MATLAB function. Please find the relevant MATLAB Answer here - https://www.mathworks.com/matlabcentral/answers/254324-insufficient-number-of-outputs-from-right-hand-side-of-equal-sign-to-satisfy-assignment
I hope this helps.
Best Regards,
Sachin

カテゴリ

Help Center および File ExchangeMATLAB Coder についてさらに検索

製品


リリース

R2023a

Community Treasure Hunt

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

Start Hunting!

Translated by