MATLAB: How to to upgrade “.mdl”, “.mexsol”, “.dll”, and “.c” S functions from MATLAB R13 to a later version such as R2015b

MATLABsimulink

How do I upgrade older files, such as “.mdl”, “.mexsol”, “.dll”, and “.c” S functions from MATLAB R13 to newer releases (MATLAB R2008a and up)?

Best Answer

To upgrade the “.mdl” models you may use the Upgrade Advisor, as described at the link below:
 
To upgrade the “.mexsol” or "mex" files, you just need to remex those files using the “mex” command in the newer version of MATLAB, as described at the link below:
 
To upgrade the S functions, it is highly you likely that you also just need to use the “mex” command in the newer version of MATLAB (same procedure for “.mexsol”/"mex" files). If that does not work, then you may need to follow the workflow at the link below:
 
For the “.dll” files, you likely may continue using those files as is, because they are already written in C. If you do need to recompile the “.dll” files, you may use the links below:
If the “.dll” was created from a MATLAB file:
If “.dll” was created from a Simulink model: