W
willem
Guest
I have declared in a package:
type Silly_In is array (natural range <> of std_logic_vector;
I want to use generics in a entity to define the ranges:
entity test_Gates is
generic
( InBits : integer := 3
);
port
( clk : in std_logic;
Din : in Silly_In(2**Inbits-1 downto 0)(Inbits-1 downto 0); --??????
Q : out std_logic_vector(2**Inbits-1 downto 0)
);
end test_Gates;
The Din line gives errors. How do I code it correctly so that Din is a
array (255 downto 0) of std_logic_vector(2 downto 0) ? or I will want to
try for different InBits sizes.
--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/
type Silly_In is array (natural range <> of std_logic_vector;
I want to use generics in a entity to define the ranges:
entity test_Gates is
generic
( InBits : integer := 3
);
port
( clk : in std_logic;
Din : in Silly_In(2**Inbits-1 downto 0)(Inbits-1 downto 0); --??????
Q : out std_logic_vector(2**Inbits-1 downto 0)
);
end test_Gates;
The Din line gives errors. How do I code it correctly so that Din is a
array (255 downto 0) of std_logic_vector(2 downto 0) ? or I will want to
try for different InBits sizes.
--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/