eda课上练习题.pptVIP

  • 5
  • 0
  • 约9.35千字
  • 约 27页
  • 2015-09-25 发布于重庆
  • 举报
eda课上练习题

习题课 4.4 generic decoder library ieee; use ieee.std_logic_1164.all; entity g44 is generic(n:integer:=3); port(ena: in std_logic; x: out std_logic_vector(2**n-1 downto 0); sel:in integer ); end g44; architecture g of g44 is begin process(ena,sel) variable t1:std_logic_vector(xhigh downto 0); begin t1:=(others=1); if(ena=1) then t1(sel):=0; end if; x=t1; end process; end g; 5.2 priority encoder (a) Using only operators Entity priority_encoder is port(x:in bit_vector(7 downto 1); y:out bit_vector(2 downto 0)); End priority

文档评论(0)

1亿VIP精品文档

相关文档