MATLAB: How can improve the debug process using C-code on s-functions

c codeprogrammings-functionsimulink

I am developing C-code using s-functions in Matlab-Simulink 2014, to this aim I use visual studio 2013 to attach the process and to perform the debug process, but, each time that a pointer loses the reference, the Matlab-Simulink collapses, therefore the temporal data are eliminated and I have to reopen all software and to remade the test. (this makes me lose a lot of time)
is there any configuration in which this kind of errors does not occurs?

Best Answer

Hello,
I wonder the same question...
The only thing I find it is to click to "Attempt to continue" on the "Matlab System Error" window. Matlab does not shutdown and I can follow my debug tests.
Related Question