ssSetSampleTime
Set the period of a sample time
Syntax
time_T ssSetSampleTime(SimStruct *S, int_T st_index, time_T period)
Arguments
SSimStruct that represents an S-Function block.
st_indexIndex of the sample time whose period is to be set.
periodPeriod of the sample time specified by
st_index.
Returns
The time_T sample time value specified by
period.
Description
Use this macro in mdlInitializeSizes or
mdlInitializeSampleTimes after calling ssSetNumSampleTimes to specify
the period of the sample time where st_index starts at 0.
See Setting Sample Times and Offsets for more
information. Use ssSetOffsetTime if the sample
time has an associated offset.
Languages
C, C++
Examples
See the following S-functions for examples that use this function:
mixedmex.cused insfcndemo_mixedmexsfun_dtype_io.cused insfcndemo_dtype_iostvdtf.cused insfcndemo_stvdtf
Version History
Introduced before R2006a