quartus编译错误

2019-07-16 00:26发布

代码如下
  1. --2shuruyufeimen
  2. library ieee;
  3. use ieee.std_logic_1164.all;
  4. entity nand2 is
  5.         port(a,b: in std_logic;
  6.                  y:out std_logic);
  7. end entity nand2;
  8. architecture nand22 of nand2 is
  9. begin
  10. y<=a NAND b;
  11. end architecture nand22;

  12. --3shuruyufeimen
  13. library ieee;
  14. use ieee.std_logic_1164.all;
  15. entity nand3 is
  16.         port(a,b,c: in std_logic;
  17.                  y:out std_logic);
  18. end entity nand3;
  19. architecture nand33 of nand3 is
  20. begin
  21. y<=NOT(a AND b AND c);
  22. end architecture nand33;

  23. --3shurubiaojueqi
  24. library ieee;
  25. use ieee.std_logic_1164.all;
  26. entity nand4 is
  27.         port(ain,bin,cin: in std_logic;
  28.                  yout:out std_logic);
  29. end entity nand4;
  30. architecture nand44 of nand4 is
  31. component nand2
  32.         port(a,b: in std_logic;
  33.                  y:out std_logic);
  34. end component nand2;
  35. component nand3
  36.         port(a,b,c: in std_logic;
  37.                  y:out std_logic);
  38. end component nand3;
  39. signal e,f,g:std_logic;
  40. begin
  41. u1:nand2 port map(a>=ain,b>=bin,y>=e);
  42. u2:nand2 port map(a>=ain,b>=cin,y>=f);
  43. u3:nand2 port map(a>=bin,b>=cin,y>=g);
  44. u4:nand3 port map(a>=e,b>=f,c>=g,y>=yout);
  45. end architecture nand44;
复制代码



错误显示  object a,b,c  is used but not declared
友情提示: 此问题已得到解决,问题已经关闭,关闭后问题禁止继续编辑,回答。