stand alone exe and passing arguments
1 回表示 (過去 30 日間)
古いコメントを表示
Hi. Here's an example of what I compiled, how i invoke it, and the error. It's on DOS.
function success = allFat (sourcecode,dir,fat_dir,results_type,location,method_type,bin_size,lifetime,n_processors_input)
results_type = str2double(results_type);
bin_size = str2double(bin_size);
lifetime = str2double(lifetime);
n_processors_input = str2double(n_processors_input);
do stuff with these args...
end
Invoked like:
>fatigue_GE127_45cores_bin_size2_forEXE.exe J:\Calc\path J:\Calc\anotherPath J:\Calc\path\morePath 3 b GL 2 20 45
The error:
Undefined function or variable 'fatigue_GE127_45cores_bin_size2_forEXE'.
MATLAB:UndefinedFunction
Error:Undefined function 'fatigue_GE127_45cores_bin_size2_forEXE' for input arguments of type 'char'.
0 件のコメント
回答 (2 件)
Walter Roberson
2018 年 6 月 19 日
You might need to name it allFat.exe in order to invoke allFat as your entry point.
0 件のコメント
David Pesetsky
2018 年 6 月 19 日
4 件のコメント
Walter Roberson
2018 年 6 月 19 日
data point:
I just tested on Mac, compiling with R2018a. The name of the executable did not affect which function was called first.
参考
カテゴリ
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!