sfix_udelay - Number of Parameters Mismatch Between Code and Dialog Box

I'm getting this error for S-function 'sfix_udelay:
"For S-function 'sfix_udelay', the number of defined parameters, 7, does not match the number of parameters on the dialog, 6. These two values must be identical."
I read this to mean that the number parameters in the compiled s-function is different than the number of parameters in the block dialog box. I don't understand how this is, since it is a provided function, and there are no additional parameters in the dialog box. The dialog box is identical to the help figure. The uncompiled code for the function is not accessable to see why it is suddenly requiring 7 parameters.

Answers (1)

Are you using the Tapped Delay or Integer Delay blocks from the Simulink->Discrete library (these are what use the sfix_udelay S-function)? If yes, the block S-function dialog does indeed define 7 parameters (Right-click on block->Look Under Mask to see the corresponding S-function dialog). I see the following list:
For Tapped Delay:
samptime,vinit,NumDelays,NumDelays,DelayOrder,includeCurrent,3
For Integer Delay:
samptime,vinit,NumDelays,1,1,0,InputProcessing
As you can see, there are 7 parameters.
Did you somehow modify the block? I would recommend replacing the block in your model with a fresh version from the library to see if that fixes the issue.

Asked:

on 6 Apr 2011

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!