W
Weng Tianxiang
Guest
Hi,
I would like a help:
How to pass a global data type to an entity?
This is the statements I wrote and it has errors.
LIBRARY ieee;
USE ieee.std_logic_1164.all;
use ieee.numeric_std.all; -- for "unsigned"
LIBRARY unisim;
USE UNISIM.VCOMPONENTS.ALL;
package NewType is
type ByteType is array(7 downto 0) of std_logic_vector(7 downto 0);
end NewType;
entity AModule is port (
DataIn : ByteType;
...
);
end AModule;
architecture A of AModule is
....
end A;
What is wrong?
Thank you.
Weng
I would like a help:
How to pass a global data type to an entity?
This is the statements I wrote and it has errors.
LIBRARY ieee;
USE ieee.std_logic_1164.all;
use ieee.numeric_std.all; -- for "unsigned"
LIBRARY unisim;
USE UNISIM.VCOMPONENTS.ALL;
package NewType is
type ByteType is array(7 downto 0) of std_logic_vector(7 downto 0);
end NewType;
entity AModule is port (
DataIn : ByteType;
...
);
end AModule;
architecture A of AModule is
....
end A;
What is wrong?
Thank you.
Weng