Is it possible to create a standalone GUI using the MATLAB Compiler 4.3 (R14SP3) that interacts with xPC Target 2.8 (R14SP3) using the M-API?

1 view (last 30 days)
I would like to build a custom GUI in MATLAB for xPC Target. I want to use the M-API functions in the GUI’s callbacks. I am wondering if this is possible, and if I can use the MATLAB Compiler to create a standalone application from this GUI.

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 21 Jun 2012
It is possible to create a standalone GUI using the MATLAB Compiler 4.3 (R14SP3) that interacts with xPC Target 2.8 (R14SP3) using the M-API.
This method is illustrated by the attached demo files "xPC_GUIdemo.m" and "xPC_GUIdemo.fig". The specific tasks that the demo GUI enables the user to achieve are:
a. Set xPC Target environment properties
b. Connect to Target machine
c. Download application
d. Start and Stop application
e. Tune a Parameter
f. Trace Signal(s) via host scope object
The GUI example uses the demo model "xpcosc.mdl" shipped with xPC Target and demonstrates tuning of the feedback gain and observing its effect on the system response.
For more information on creating a GUI in MATLAB and creating a standalone application from the GUI using the MATLAB Compiler, refer to the attached help files in "xPC_GUIdemo_help.zip"
This GUI will run in R14SP2 as well as in R14SP3. However, the compiled version of the GUI works only in R14SP3. To compile the GUI using the MATLAB Compiler, you can execute the following at the MATLAB command prompt:
mcc -m xPC_GUIdemo.m

More Answers (0)

Tags

Products


Release

R14SP1

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!