Ian O'Dwyer wrote:
> Hi All,
>
> I am getting an error with a couple of blocks when trying to simulate a new
> design.  This is using version 10.1.  It seems like there is some problem
> with the initialization commands/mask.  For example in one block delay_bram
> there appear to be only 3 variables that are in the mask,   delay_len,
> bram_latency and use_dsp48.
>  
> However, the mask initialization looks like this
>  
> if (DelayLen <= bram_latency)
> error('delay value must be greater than BRAM Latency');
> end
> BitWidth = max(ceil(log2(DelayLen)), 2);
> if strcmp(use_dsp48,'on'),
> set_param([gcb,'/Counter'], 'use_behavioral_HDL', 'off', ...
> 'use_rpm', 'on', 'implementation', 'DSP48');
> else, %default counter settings
> set_param([gcb,'/Counter'], 'use_behavioral_HDL', 'off', ...
> 'use_rpm', 'off', 'implementation', 'Fabric');
> end
>
>
> I am not an expert on masks at all,  but it seems like it is trying to set
> values for variables (use_behavioral_hdl, implementation and use_rpm) that
> do not exist in delay_bram's mask and I think that's what the simulator is
> trying to tell me with its error message.  Does this look familiar to anyone
> at all?  Any suggestions?
>
> Many thanks
>
> Ian O'Dwyer
>   

Hi Ian,

In the specific case of delay_bram, BitWidth is the only new variable
defined in the Initialization Commands.  As with Dialog Variables, new
variables defined here are made available to blocks in the subsystem
you're masking.  BitWidth is used by the Single Port RAM and Counter blocks.

The other "variables" you mentioned (use_behavioral_HDL, use_rpm, and
implementation) are actually parameter names.  Those calls to set_param
are modifying parameters in the mask of the Counter block.  Read "help
set_param" for more info.

Billy

Reply via email to