Azzera filtri
Azzera filtri

MATLAB function (Simulink) - "Error calling generated SFunction Invalid MEX-file: Access is denied."

1 visualizzazione (ultimi 30 giorni)
I have a Simulink model which has only the default MATLAB Function block (the input to the block to sent out as the output fromthe block). When I run this model without saving the model, it works. If I save the model and try to run it, I get the following error -
"Error calling generated SFunction, MATLAB_func_simple_test_25102016_sfun. Invalid MEX-file 'S:\Research\MATLAB_func_simple_test_25102016_sfun.mexw64': Access is denied."
I had a look at Mathworks forums and questions on similar issues and tried the following: 1. Ensured that the Simulink model and the MEX file were built using the same version of MATLAB on the same computer. 2. Tried deleting the MEX file and the slprj folder and tried re-running the Simulink model.
I am running MATLAB R2014b 64-bit.
  2 Commenti
Anup
Anup il 25 Ott 2016
I normally store all my files on the University's central file store (which is backed-up every few hours). Saving the Simulink model on this file-store, does not allow the MATLAB function to work. I now tried saving the model onto the C drive of my computer, and it worked. Any ideas on how one could make this work on common file-stores?
Zunaib
Zunaib il 25 Ott 2016
The problem is due to the reason that you might have installed previous or latest version of mex setupt which is giving error when you save your file. Kindly remove you matlab, remove entries from regedit and then re-install MATLAB.

Accedi per commentare.

Risposte (0)

Categorie

Scopri di più su Startup and Shutdown in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by