How can I open an engine connection against a specific license?
이전 댓글 표시
engOpen lets me open a connection with Matlab engine. If I have 2 Matlab licenses, how can I tell the engine which to open?
답변 (1개)
Kaustubha Govind
2012년 11월 13일
On Windows, the MATLAB Engine will start whichever MATLAB installation was last registered as a COM server. Quoting the documentation:
On Windows systems, engOpen opens a COM channel to MATLAB. The MATLAB software you registered during installation starts. If you did not register during installation, on the command line you can enter the command:
!matlab /regserver
On *nix platforms, I believe it should start whichever version of MATLAB it locates first on the PATH and LD_LIBRARY_PATH environment variables (see How do I compile and run a MATLAB Engine program on UNIX/Linux/Mac?)
댓글 수: 3
Walter Roberson
2012년 11월 13일
In *nix systems, when you start MATLAB you can specify the license file by establishing an LM_LICENSE_FILE environment variable that indicates the file. I wonder if the same thing can be done in this case, wonder whether the environment variables get noticed when ActiveX is started?
Kaustubha Govind
2012년 11월 15일
Randy: I don't know a whole lot about MATLAB license management, but if you can simply use the MATLAB startup option (-c licensefile) and you're on *nix, I wonder if you can use the startcmd parameter of the engOpen function to pass in the -c option.
카테고리
도움말 센터 및 File Exchange에서 Startup and Shutdown에 대해 자세히 알아보기
제품
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!