Matlab compiled code RF toolbox read function works if called from compiled script but not a compiled function
3 ビュー (過去 30 日間)
古いコメントを表示
Matlab version: R2014b OS: Windows 7 64bit Addon toolbox: RF toolbox
I have some code I need to compile into standalone for use in a manufacturing environment. The code uses the read function out of the RF toolbox to read touchstone 1.0 files and process them. The code compiles and runs fine if the top level code that is compiled is a script. However, I need to pass variables from the command line, so I think I need the top level code to be a function. However, the code fails when run when the top level code is a function, giving the following error:
Error using rfdata.reference/set Invalid parameter/value pair arguments.
Error in rfdata.data/read (line 73)
The offending function looks like this:
function [S, f] = RF_ReadTouchstone( filename )
filedata=read(rfdata.data,char(filename)); [S,f]=extract(filedata,'S_parameters',50);
end
I have verified that the variables are propagating through the code properly. It seems like something strange the compiler is doing.
0 件のコメント
回答 (2 件)
Giorgia Zucchelli
2015 年 2 月 25 日
Dear Josiah,
I built a very simple main function invoking the function RF_ReadTouchstone, and I managed to compile and execute it correctly.
function main(input)
[S,f] = RF_ReadTouchstone(input);
disp(S);
end
As I cannot reproduce your issue, I would recommend to directly contact MathWorks technical support.
With best regards,
Giorgia
0 件のコメント
Jongbae Park
2015 年 10 月 30 日
have you resolved your issue? I am also getting the same issue.
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で MATLAB Compiler についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!