N
nfirtaps
Guest
Hello, I am creating a FIFO IP core in ISE. Everything goes well with
the generation however when I write a small VHDL file that port maps
the outputs and inputs to the FIFO I can see the outputs are not being
driven. In the simulator the outputs are 'U'. Here's a little
background before I paste in my code. The abbreviations ef and ff
stand for empty flag (which should be '1' after the FIFO is reset), and
full flag (which should be '0' after the fifo is reset). Here is some
code does this look right for the port mapping and instantiation?
Also, do I have to make signals for the port mapping, or can I directly
use the signals in the entity description instead of have to make
std_logic and assign them in the behavioral?
Thanks in advance...
entity fpga_fifo_filler is
Port ( clk : in STD_LOGIC; -- clk that will map to the fifo
instance
enable : in STD_LOGIC; --enable on the fifo
reset : in std_LOGIC; -- reset on the fifo
fpga_fifoef : out STD_LOGIC; --the fifo empty flag
fpga_fifoff : out STD_LOGIC); --the fifo full flag
end fpga_fifo_filler;
architecture Behavioral of fpga_fifo_filler is
signal clk_wire : std_logic; --I put these here for the port map,
signal enable_wire : std_logic; --It will also synthesize if I just map
the enable on the entity
signal reset_wire : std_logic; --Is it even necessary to have these
signals?
signal fpga_fifoef_wire : std_logic;
signal fpga_fifoff_wire : std_logic;
component wrapped_async_fifo
port (
din: IN std_logic_VECTOR(15 downto 0);
rd_clk: IN std_logic;
rd_en: IN std_logic;
rst: IN std_logic;
wr_clk: IN std_logic;
wr_en: IN std_logic;
dout: OUT std_logic_VECTOR(15 downto 0);
empty: OUT std_logic;
full: OUT std_logic);
end component;
begin
Inst_wrapped_async_fifo : wrapped_async_fifo
port map(
din => "0000000000000000",
rd_clk => '0',
rd_en => '0',
rst => reset_wire,
wr_clk => clk_wire, --map the clk_wire and feed the clock to the
fifo
wr_en => enable_wire, -- map the enable ...
dout => open,
empty => fpga_fifoef_wire, --these signals are not driven in
simulation why????
full => fpga_fifoff_wire --not driven in simulation why????
);
--Inputs
clk_wire <= clk; -mapping, again do I need these?
reset_wire <= reset;
enable_wire <= enable;
--Outputs
fpga_fifoef <= fpga_fifoef_wire;
fpga_fifoff <= fpga_fifoff_wire;
end Behavioral;
the generation however when I write a small VHDL file that port maps
the outputs and inputs to the FIFO I can see the outputs are not being
driven. In the simulator the outputs are 'U'. Here's a little
background before I paste in my code. The abbreviations ef and ff
stand for empty flag (which should be '1' after the FIFO is reset), and
full flag (which should be '0' after the fifo is reset). Here is some
code does this look right for the port mapping and instantiation?
Also, do I have to make signals for the port mapping, or can I directly
use the signals in the entity description instead of have to make
std_logic and assign them in the behavioral?
Thanks in advance...
entity fpga_fifo_filler is
Port ( clk : in STD_LOGIC; -- clk that will map to the fifo
instance
enable : in STD_LOGIC; --enable on the fifo
reset : in std_LOGIC; -- reset on the fifo
fpga_fifoef : out STD_LOGIC; --the fifo empty flag
fpga_fifoff : out STD_LOGIC); --the fifo full flag
end fpga_fifo_filler;
architecture Behavioral of fpga_fifo_filler is
signal clk_wire : std_logic; --I put these here for the port map,
signal enable_wire : std_logic; --It will also synthesize if I just map
the enable on the entity
signal reset_wire : std_logic; --Is it even necessary to have these
signals?
signal fpga_fifoef_wire : std_logic;
signal fpga_fifoff_wire : std_logic;
component wrapped_async_fifo
port (
din: IN std_logic_VECTOR(15 downto 0);
rd_clk: IN std_logic;
rd_en: IN std_logic;
rst: IN std_logic;
wr_clk: IN std_logic;
wr_en: IN std_logic;
dout: OUT std_logic_VECTOR(15 downto 0);
empty: OUT std_logic;
full: OUT std_logic);
end component;
begin
Inst_wrapped_async_fifo : wrapped_async_fifo
port map(
din => "0000000000000000",
rd_clk => '0',
rd_en => '0',
rst => reset_wire,
wr_clk => clk_wire, --map the clk_wire and feed the clock to the
fifo
wr_en => enable_wire, -- map the enable ...
dout => open,
empty => fpga_fifoef_wire, --these signals are not driven in
simulation why????
full => fpga_fifoff_wire --not driven in simulation why????
);
--Inputs
clk_wire <= clk; -mapping, again do I need these?
reset_wire <= reset;
enable_wire <= enable;
--Outputs
fpga_fifoef <= fpga_fifoef_wire;
fpga_fifoff <= fpga_fifoff_wire;
end Behavioral;