Respond to disabling of an enabled system containing this block
#define MDL_DISABLE void mdlDisable(SimStruct *S)
SimStruct representing an S-Function block.
The Simulink® engine invokes this optional method if this block resides in an enabled subsystem and the enabled subsystem changes from an enabled to a disabled state at the current time step. Your S-function can use this method to perform any actions required by the disabling of the containing subsystem.