标题: 基于FPGA的3位锁存源码 [打印本页]

作者: bzc4444    时间: 2018-5-31 12:39
标题: 基于FPGA的3位锁存源码
基于FPGA的3位锁存

  1. Ilibrsry ieee;
  2. use ieee.std_logic_1164.all;
  3. entity sn74373 is
  4.    port(d: in std_logic_vetor(8 downto 1);
  5.         OEN:in std_logic;
  6.         G:in std_logic;
  7.         Q:out std_logic_vector(8 downto 1));
  8. end entity sn74373;
  9. architecture two of sn74373 is
  10.     signal sigvec_save:std_logic_vector(8 downto 1);
  11.      begin
  12.        process(D,OEN,G)
  13.        begin
  14.           if OEN='0' then
  15.              Q<=sigvec_save;
  16.           else
  17.              Q<="ZZZZZZZZ";
  18.           end if;
  19.          if G='1' then
  20.              sigvec_save<=D;
  21.          end if;
  22.         end process;
  23. eng architecture two;
复制代码


fpga.docx

10.56 KB, 下载次数: 2, 下载积分: 黑币 -5

3位所存






欢迎光临 (http://www.51hei.com/bbs/) Powered by Discuz! X3.1