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!