MATLAB [MATLAB] GUI interface into standalone application help

Click For Summary
Compiling a MATLAB GUI designed with GUIDE Builder into a standalone application is problematic due to issues with MEX files, which are necessary for controlling hardware. The deploytool's build function fails with an error related to MEX files, and attempts to use the "mcc" command result in immediate closure of the command prompt. The discussion suggests that the MATLAB internal compiler may not support MEX files, and recommends trying the MCD for recompilation. Directly controlling the hardware without MEX files is not feasible, as the hardware operates on high-level C language commands. The consensus is that the compiler being used likely does not support MEX files, potentially necessitating the development of two separate programs: one for hardware control and another for post-processing tasks.
n0_3sc
Messages
238
Reaction score
1
I have a GUI interface designed in MATLAB GUIDE Builder. It works with several MEX files that control a piece of hardware. I need to compile this into a standalone application.
The deploytool's build function never compiles - it complains about the MEX files and returns:
"Error executing mcc, return status = 1."

Is there anyway I can compile this using commands? I tried just "mcc fileName" but that opens a command prompt window and immediately shuts down.
 
Physics news on Phys.org
What tool are you using to compile your GUI? Are you using Matlab's internal compiler? Its possible that the compiler doesn't support the use of MEX files. Try downloading and installing MCD and try recompiling it.

Also, we don't you just control the hardware directly without the MEX files? Wouldn't that just be easier?
 
I'm using the Lcc-win32 C 2.4.1 compiler with all the necessary graphic compiling packages. I don't know if it is Matlab's internal compiler - I'm just using whatever my institute has available for me.
I can compile and run simple .m files no problems. I assume it is the MEX files which the compiler may not support as you suggested.

I cannot just control my hardware without the MEX files because it controls a CCD which is built and functions on a high-level C language. All the commands to activate certain functions are in this language.
 
It sounds to me like your compiler doesn't support MEX files. You may have to write two separate programs to get the job done. One to handle the hardware end and the other to do all your post processing.
 
Yes you're right. I tried a few different compilers and the issue is just with the MEX files in all of them.

Thanks for the help :smile:
 

Similar threads

  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 2 ·
Replies
2
Views
16K
  • · Replies 3 ·
Replies
3
Views
13K
  • · Replies 5 ·
Replies
5
Views
3K
Replies
18
Views
8K
  • · Replies 3 ·
Replies
3
Views
13K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 13 ·
Replies
13
Views
4K