⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 tb_progprom_tmpl.vhd

📁 Lattice 超精简8位软核CPU--Mico8
💻 VHD
字号:
-- VHDL testbench template generated by SCUBA ispLever_v70_SP2_Build (24)library IEEE;use IEEE.std_logic_1164.all;use IEEE.std_logic_unsigned.all;entity tb isend entity tb;architecture test of tb is     component ProgPRom        port (Address : in std_logic_vector(8 downto 0);         OutClock: in std_logic; OutClockEn: in std_logic;         Reset: in std_logic; Q : out std_logic_vector(17 downto 0)    );    end component;    signal Address : std_logic_vector(8 downto 0) := (others => '0');    signal OutClock: std_logic := '0';    signal OutClockEn: std_logic := '0';    signal Reset: std_logic := '0';    signal Q : std_logic_vector(17 downto 0);begin    u1 : ProgPRom        port map (Address => Address, OutClock => OutClock, OutClockEn => OutClockEn,             Reset => Reset, Q => Q        );    process    begin      Address <= (others => '0') ;      wait for 100 ns;      wait until Reset = '0';      for i in 0 to 515 loop        wait until OutClock'event and OutClock = '1';        Address <= Address + '1' after 1 ns;      end loop;      wait;    end process;    OutClock <= not OutClock after 5.00 ns;    process    begin      OutClockEn <= '0' ;      wait for 100 ns;      wait until Reset = '0';      OutClockEn <= '1' ;      wait;    end process;    process    begin      Reset <= '1' ;      wait for 100 ns;      Reset <= '0' ;      wait;    end process;end architecture test;

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -