%% $RCSfile: sdspramp.tlc,v $ %% $Revision: 1.1 $ $Date: 2000/04/17 16:04:14 $ %% %% Copyright (c) 1995-2000 The MathWorks, Inc. %% %% Abstract: Target file for the S-Function sdspramp.c %% %implements "sdspramp" "C" %% Function: Start ========================================================== %% %function Start(block, system) Output %% %% No code is needed if the input is a constant sample rate and %% parameters are inlined because the output will be constant. %% The pre-calculated output will be already stored in the i/o vector. %% %if !LibIsEqual(TID, "constant") /* DSP Blockset Autocorrelation (%) - % */ %% %assign OUTPORT = 0 %assign outWidth = LibDataOutputPortWidth(OUTPORT) %assign y = LibBlockOutputSignal(OUTPORT,"i","",0) %assign Slope = SFcnParamSettings.Slope %assign Offset = SFcnParamSettings.Offset %% %assign Offset_str = (Offset == 0) ? "" : " + %" %assign Slope_str = ((Slope == 1) || (Slope == -1)) ? "" : " * %" %assign i_str = (Slope == -1) ? "-i" : "i" %% { int_T i; for(i=0; i < %; i++) { % = %%%; } } %endif %% %endfunction %% Start %% [EOF] sdspramp.tlc