VHDL generate multi-instances with differet generic values

Status
Not open for further replies.

sarang5s5

Newbie level 5
Joined
Nov 10, 2017
Messages
8
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
78
In VHDL, is it possible to generate multiple instances of a generic instance with different generic values ?
for example, a simple generic counter (say generic WIDTH = 2) instantiated multiple times (in loop or conditionally) in a top level entity, with its different generic values.
Is it possible ? If yes, please help on the same.
 

yes it's possible. For example in a generate loop:


Code VHDL - [expand]
1
2
3
4
inst_gen : for i in 1 to 10 generate
  counter_inst : entity work.generic_counter
  generic map ( DWIDTH => i );
end generate inst_gen;

 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…