Forcing deploytool to include toolbox.

1 visualizzazione (ultimi 30 giorni)
Hello everybody,
I have written a GUI, which uses a Simulink model to perform some calculations. Everything is working when I call my .m file from Matlab, but I'm running into some troubles when trying to build a executable. I think the deploytool is not including the right packages. I've used the employtool, with the main .m file, and associated files. I'm running 7.10.0(R2010a), my version of MCR is 7.13 The output of build is:
Compiler version: 4.13 (R2010a)
Processing C:\Program Files\MATLAB\R2010a\toolbox\map\mcc.enc
Processing C:\Documents and Settings\Administrator\Mijn documenten\My Dropbox\TU\Stage\Program\StandAlone\Toolex.fig
Processing C:\Program Files\MATLAB\R2010a\toolbox\shared\maputils\mcc.enc
Processing C:\Program Files\MATLAB\R2010a\toolbox\shared\mapgeodesy\mcc.enc
Processing C:\Program Files\MATLAB\R2010a\toolbox\matlab\guide\guideopts.fig
Processing C:\Program Files\MATLAB\R2010a\toolbox\matlab\winfun\actxcontrolselect.fig
Processing C:\Program Files\MATLAB\R2010a\toolbox\matlab\winfun\actxcontrolcreateproperty.fig
Processing C:\Program Files\MATLAB\R2010a\toolbox\shared\controllib\general\mcc.enc
mcc.enc file not found for licensed toolbox file C:\Program Files\MATLAB\R2010a\toolbox\sldo\sldo\utSimChangesParameters.m
All files in directory C:\Program Files\MATLAB\R2010a\toolbox\sldo\sldo will be excluded.
Processing C:\Program Files\MATLAB\R2010a\toolbox\globaloptim\mcc.enc
Processing C:\Program Files\MATLAB\R2010a\toolbox\distcomp\mcc.enc
Processing C:\Program Files\MATLAB\R2010a\toolbox\optim\mcc.enc
Processing C:\Program Files\MATLAB\R2010a\toolbox\shared\optimlib\mcc.enc
mcc.enc file not found for licensed toolbox file C:\Program Files\MATLAB\R2010a\toolbox\rtw\targets\mpc555dk\rt\blockset\mfiles\getuniquesignalname.p
All files in directory C:\Program Files\MATLAB\R2010a\toolbox\rtw\targets\mpc555dk\rt\blockset\mfiles will be excluded.
Processing include files...
2 item(s) added.
Processing directories installed with MCR...
The file mccExcludedFiles.log contains a list of functions excluded from the CTF archive.
8 item(s) added.
Generating MATLAB path for the compiled application...
Created 59 path items.
Begin validation of MEX files: Wed Aug 01 12:27:56 2012
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\@distcomp\dctCmdWindowSize.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\distcomp\dct_psfcns.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\distcomp\distcompByteBuffer2MxArray.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\distcomp\distcompMakeByteBufferHandle.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\distcomp\distcompMxArray2ByteBuffer.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\distcomp\distcompdeserialize.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\distcomp\distcompserialize.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\distcomp\getUncPathFromMappedDrive.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\distcomp\pct_unsetenvmex.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\parallel\@codistributed\private\scalaCholmex.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\parallel\@codistributed\private\scalaEigmex.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\parallel\@codistributed\private\scalaLUmex.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\parallel\@codistributed\private\scalaLUsolvemex.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\parallel\@codistributed\private\scalaSvdmex.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\parallel\lapack\dgeqrf.mexw32'.
Found M-file 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\parallel\lapack\dgeqrf.m'.
MEX file
'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\parallel\lapack\dgeqrf.mexw32'
is valid. It contains 'mexFunction.'
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\parallel\lapack\dgetrf.mexw32'.
Found M-file 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\parallel\lapack\dgetrf.m'.
MEX file
'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\parallel\lapack\dgetrf.mexw32'
is valid. It contains 'mexFunction.'
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\parallel\lapack\dormqr.mexw32'.
Found M-file 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\parallel\lapack\dormqr.m'.
MEX file
'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\parallel\lapack\dormqr.mexw32'
is valid. It contains 'mexFunction.'
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\private\dctPathAndClearNotification.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\distcomp\private\dctRegisterMpiFunctions.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\map\map\private\checkinput_mex.mexw32'.
No conflicting M-file found.
Validating 'C:\Program Files\MATLAB\R2010a\toolbox\optim\optim\private\activesetqp.mexw32'.
No conflicting M-file found.
End validation of MEX files: Wed Aug 01 12:27:56 2012
Parsing file "C:\Documents and Settings\Administrator\Mijn documenten\My Dropbox\TU\Stage\Program\StandAlone\Toolex.m"
(Referenced from: "Compiler Command Line").
Parsing file "C:\Program Files\MATLAB\R2010a\toolbox\compiler\deploy\deployprint.m"
(Referenced from: "Compiler Command Line").
Parsing file "C:\Program Files\MATLAB\R2010a\toolbox\compiler\deploy\printdlg.m"
(Referenced from: "Compiler Command Line").
Deleting 21 temporary MEX authorization files.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_5094_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_31530_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_30211_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_16702_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_18661_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_27003_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_21709_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_6503_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_24533_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_10313_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_12900_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_1439_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_9079_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_32454_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_7169_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_3526_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_5961_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_27836_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_11036_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_13764_4436.auth'.
Removing: 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\mathworks_tmp_4436_32419_4436.auth'.
Generating file "Toolex_main.c".
Generating file "Toolex_delay_load.c".
Generating file "C:\Documents and Settings\Administrator\Mijn documenten\My Dropbox\TU\Stage\Program\StandAlone\readme.txt".
Generating file "Toolex_mcc_component_data.c".
Executing command: ""C:\Program Files\MATLAB\R2010a\bin\mbuild" -O -v -output "Toolex" "Toolex_main.c" "Toolex_delay_load.c" "Toolex_mcc_component_data.c" -link exe -env MCR_DELAYLOAD=/delayload:mclmcrrt713.dll -env MCR_DELAYLIB=delayimp.lib"
Sorry for the long text, but i'm really unsure which parts are relevant to my problem. The deploytool does not encounter serious errors, a .exe is created, alongside with the other usual files. But, when i start the .exe, it stalls at the DOS phase (no GUI is generated) Although I notice that an issue occurs with the toolbox for utSimChangesParameters, which might cause the issue.
mcc.enc file not found for licensed toolbox file C:\Program Files\MATLAB\R2010a\toolbox\sldo\sldo\utSimChangesParameters.m
The same issue also occurs with the
mcc.enc file not found for licensed toolbox file C:\Program Files\MATLAB\R2010a\toolbox\rtw\targets\mpc555dk\rt\blockset\mfiles\getuniquesignalname.p
The reason I think this is the issue is because the errorfile shows:
{??? Undefined function or method 'simset' for input arguments of type 'char'.
Error in ==> Toolex>Toolex_OpeningFcn at 187
Error in ==> gui_mainfcn at 221
Error in ==> Toolex at 64
}
MATLAB:UndefinedFunction
If my reasoning is correct, how can I make sure that the utSimChangesParameters.m is included in my executable?
Thanks in advance, and I hope you guys can help me out =)
Roy

Risposta accettata

Friedrich
Friedrich il 1 Ago 2012
Hi,
Simulink and all other Toolboxes which are based on Simulink can't be compiled with ML Compiler:
Consider using Embedded Coder to generate a DLL out of your SL model. Use that DLL back in ML with loadlibrary. In that way you get rid of SL and your code can be compiled just fine.
  5 Commenti
Roy Veldhuizen
Roy Veldhuizen il 1 Ago 2012
Modificato: Roy Veldhuizen il 1 Ago 2012
By the way, I just tried to generate the code of my SimuLink model (using Tools->Real Time Workshop->Build Model), but the only result was a file 'my_simulink_model_name.exe'. Is this what you meant? I guess this is what you meant http://www.mathworks.nl/videos/introduction-to-embedded-coder-68810.html?type=large, but I'm not able to get the PCG option mentioned in the model-explorer. I do have an code standing under 'code', but I'm not sure how to proceed..
Roy
Friedrich
Friedrich il 1 Ago 2012
Modificato: Friedrich il 1 Ago 2012
Hi,
not really. I guess you need to do something like shown here:
The imporant information is in the note:
"To deploy a host executable without an accessible installation folder, consider using the Host-Based Shared Library Library target (ert_shrlib)"
So you need to set the target to ert_shrlib in order to get a DLL. Use that DLL with loadlibrary in MATLAB.

Accedi per commentare.

Più risposte (0)

Categorie

Scopri di più su Introduction to Installation and Licensing in Help Center e File Exchange

Prodotti

Community Treasure Hunt

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

Start Hunting!

Translated by