Info
この質問は閉じられています。 編集または回答するには再度開いてください。
Instrfindall gives an error in a Matlab executable (and not in Matlab)
1 回表示 (過去 30 日間)
古いコメントを表示
Dear all,
I built a Matlab executable to read-out an Arduino. To this end I use instrfindall to make a list of all COM ports and then Matlab finds the correct Arduino by communicating with them (one COM-port at the time). This works well when the program is directly built from Matlab (by pressing F5).
But after compiling it to an executable it produces an error on the instrfindall querry:
Instruments = instrfindall();
The Windows command prompt says that there is an error on the line of the querry, but no reason specified.
I tried running the executable as an administrator but that doesn't make a difference. Anybode an idea how to solve this?
0 件のコメント
回答 (2 件)
Kevin Hajek
2015 年 7 月 31 日
I contacted support for something similar and found something that may be useful for you to try. I was getting the following error message:
Undefined variable "com" or class "com.mathworks.toolbox.instrument.Instrument.jinstrfindall"
==================================
Hello Kevin,
I am writing in reference to your Technical Support Case #01454153 regarding 'Trouble with 'instrfind' when deploying a compiled applican'.
Thank you for contacting Technical Support at MathWorks, I understand that you are not able to execute a standalone version of your application that works as expected in MATLAB.
This is a known issue with MATLAB Compiler in R2015a and is reported externally at the following web page:
There is a bug in MATLAB Compiler because of which 'instrument.jar' is missing from the Java classpath in the MCR. Please follow the steps mentioned in the bug report to resolve the issue.
...<other non-essential text>...
0 件のコメント
この質問は閉じられています。
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!