Advertisement
Guest User

Untitled

a guest
May 26th, 2017
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
VHDL 0.71 KB | None | 0 0
  1.     process(clock, reset)
  2.     begin
  3.         if rising_edge(clock) then
  4.             fifo_count <= fifo_count + 1;
  5.             fifo_wren <= '0';
  6.             if (fifo_count > 10 and fifo_count < 30) or (fifo_count > 35) then
  7.                 if fifo_almost_full = '0' then
  8. --              if fifo_count(0) = '1' then
  9.                     fifo_wren <= '1';
  10.                     fifo_din <= std_logic_vector(fifo_count);
  11. --              end if;
  12.                 end if;
  13.             end if;
  14.  
  15.             if fifo_valid = '1' then
  16.                 fifo_valid_reg <= '1';
  17.             end if;
  18.            
  19.             fifo_rdack <= '0';
  20.             if fifo_valid_reg = '1' then
  21.                 foo <= fifo_dout;
  22.                 fifo_rdack <= '1';
  23.             end if;
  24.         end if;
  25.        
  26.         if reset = '1' then
  27.             fifo_count <= (others => '0');
  28.             fifo_wren <= '0';
  29.             fifo_rdack <= '0';
  30.             fifo_valid_reg <= '0';
  31.         end if;
  32.     end process;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement