What you want to use is an expression for ... generate.
Here is an example similar to what you want to achieve:
architecture GEN of REG_BANK is component REG port(D,CLK,RESET : in std_ulogic; Q : out std_ulogic); end component; begin GEN_REG: for I in 0 to 3 generate REGX : REG port map (DIN(I), CLK, RESET, DOUT(I)); end generate GEN_REG; end GEN;
In your case, you will need to make all the signals that connect to your block vectors and vector vectors.
For example, if a signal is currently defined as:
signal v_normal_in_0_sig : std_logic_vector(7 downto 0);
You will need to change it to:
type vector16 is array (natural range <>) of std_logic_vector(15 downto 0); signal v_normal_in_sig : vector16(7 downto 0);
In this case, you can use your signal as v_normal_in_sig(i) to connect to the i th created initialization of your object / component.
Please note that if you use VHDL-2008, you can do the following ...
type vector_array is array (natural range <>) of std_logic_vector; signal v_normal_in_sig : vector_array(7 downto 0)(15 downto 0);
source share