- minor mods to vld_pipe
git-svn-id: http://moon:8086/svn/vhdl/trunk@194 cc03376c-175c-47c8-b038-4cd826a8556b
This commit is contained in:
@@ -97,7 +97,7 @@ architecture Behavioral of fir_semi_parallel is
|
||||
signal accu_load : std_logic;
|
||||
|
||||
signal accu_ld_pipe : unsigned(nstages+input_latency+coef_latency+pipe_latency downto 0);
|
||||
signal vld_pipe : unsigned((1+ntaps_per_stage)*nstages downto 0);
|
||||
signal vld_pipe : unsigned(1 downto 0);
|
||||
|
||||
-------------------------------------------------------------------------------
|
||||
begin
|
||||
|
||||
@@ -31,8 +31,8 @@ use work.PCK_FIO.all;
|
||||
ENTITY tb_fir_semi_parallel IS
|
||||
Generic
|
||||
(
|
||||
ntaps_per_stage : integer := 64;
|
||||
nstages : integer := 2;
|
||||
ntaps_per_stage : integer := 32;
|
||||
nstages : integer := 4;
|
||||
nbits_in : integer := 32;
|
||||
nbits_in_frac : integer := 30;
|
||||
nbits_stages : integer := 32;
|
||||
@@ -134,7 +134,7 @@ BEGIN
|
||||
wait for PERIOD/2;
|
||||
END PROCESS;
|
||||
|
||||
din_vld <= rdy;
|
||||
-- din_vld <= rdy;
|
||||
|
||||
tb : PROCESS
|
||||
file fi : file_t open read_mode is "wav_in.dat";
|
||||
@@ -163,26 +163,29 @@ BEGIN
|
||||
wait until rising_edge(clk);
|
||||
|
||||
for i in 0 to 19 loop
|
||||
wait until rising_edge(clk);
|
||||
-- din_vld <= rdy;
|
||||
wait until rising_edge(clk) and rdy = '1';
|
||||
din_vld <= '1';
|
||||
d_in <= to_sfixed(real(i)*0.01, d_in);
|
||||
wait until rising_edge(clk);
|
||||
-- din_vld <= '0';
|
||||
wait for (ntaps_per_stage-1)*PERIOD;
|
||||
end loop;
|
||||
wait until rising_edge(clk);
|
||||
wait until rising_edge(clk) and rdy = '1';
|
||||
------------------------------------------
|
||||
-- din_vld <= '0';
|
||||
|
||||
din_vld <= '1';
|
||||
d_in <= to_sfixed(0.0, d_in);
|
||||
wait for 64*ntaps*PERIOD;
|
||||
wait until rising_edge(clk);
|
||||
-- din_vld <= '1';
|
||||
d_in <= to_sfixed(1.0, d_in);
|
||||
wait until rising_edge(clk);
|
||||
-- din_vld <= '0';
|
||||
wait for (ntaps_per_stage-1)*PERIOD;
|
||||
wait until rising_edge(clk) and rdy = '1';
|
||||
din_vld <= '0';
|
||||
|
||||
wait for 64*ntaps*PERIOD;
|
||||
wait until rising_edge(clk) and rdy = '1';
|
||||
din_vld <= '1';
|
||||
d_in <= to_sfixed(0.0, d_in);
|
||||
wait until rising_edge(clk) and rdy = '1';
|
||||
d_in <= to_sfixed(1.0, d_in);
|
||||
wait until rising_edge(clk) and rdy = '1';
|
||||
d_in <= to_sfixed(0.0, d_in);
|
||||
wait for 64*ntaps*PERIOD;
|
||||
wait until rising_edge(clk) and rdy = '1';
|
||||
din_vld <= '0';
|
||||
|
||||
wait for 40*PERIOD;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user