seyaleli
Newbie level 4
Hi guys.
I have a parametrized counter for which I want to input a constant load value
of 0 (the input port's name is count_load). I tried using the replication operator
in order to produce a parametrized ($clog2(MAX_TOKEN+1)) number of 0's for
the input,
but my modelsim 6.6 seems to refuse with an error message:
near "'b": syntax error, unexpected "BASE", expecting ',' or '}
the counter's instantiation looks like this:
gp_counter #(.COUNTER_WIDTH($clog2(MAX_TOKEN+1)))
PACKET_COUNTER (.clk(clk),.a_resetn(a_resetn), .syn_resetn(syn_resetn || resetn_packet_counter),
.count_load({($clog2(MAX_TOKEN+1))'b0}),
.count_out(packet_bits),
.next(packet_count_en),.load(1'b0),.mode(2'b01));
does anyone has a clue why the above fails to compile? and how can I
apply constant inputs to a parametrized module?
Thanks in advance,
Eyal.
I have a parametrized counter for which I want to input a constant load value
of 0 (the input port's name is count_load). I tried using the replication operator
in order to produce a parametrized ($clog2(MAX_TOKEN+1)) number of 0's for
the input,
but my modelsim 6.6 seems to refuse with an error message:
near "'b": syntax error, unexpected "BASE", expecting ',' or '}
the counter's instantiation looks like this:
gp_counter #(.COUNTER_WIDTH($clog2(MAX_TOKEN+1)))
PACKET_COUNTER (.clk(clk),.a_resetn(a_resetn), .syn_resetn(syn_resetn || resetn_packet_counter),
.count_load({($clog2(MAX_TOKEN+1))'b0}),
.count_out(packet_bits),
.next(packet_count_en),.load(1'b0),.mode(2'b01));
does anyone has a clue why the above fails to compile? and how can I
apply constant inputs to a parametrized module?
Thanks in advance,
Eyal.