Writing S-Functions Previous page   Next Page
ssEnableSystemWithTid

Enable a function-call subsystem connected to this S-function.

Syntax

Arguments

S
   SimStruct representing an S-Function block.

element
   Index of the output port element corresponding to the function-call subsystem.

Description

Use in mdlOutputs to enable a function-call subsystem connected to the S-function. The invoking syntax is

The effect of invoking this function depends on the setting of the States when enabling parameter of the function-call subsystem's Trigger block. If the parameter is set to reset, this function invokes the function-call subsystem's initialize method and then its enable method. The subsystem's initialize and enable methods in turn invoke the initialize and enable methods of any blocks in the subsystem that have these methods. Initialize methods reset the states of blocks that have states, e.g., Integrator blocks, to their initial values. Thus, if the Trigger block's States when enabling option is set to reset, invoking this function effectively resets the states of the function-call subsystem. If the Trigger block's States when enabling option is set to held, this function simply invokes the subsystem's enable method, without invoking its initialize method and hence without resetting its states.

Languages

C

See Also

ssCallSystemWithTid, ssDisableSystemWithTid, ssSetExplicitFCSSCtrl


Previous page  ssDisableSystemWithTid ssGetAbsTol Next page

© 1994-2005 The MathWorks, Inc.