Проблема VHDL-кода в Quartus II - что мне делать? - PullRequest
0 голосов
/ 06 мая 2019

Я пытаюсь скомпилировать мой VHDL-код в Quartus II, но он не компилируется, потому что, очевидно, существует одна (1) ошибка. Проблема в том, что программа не показывает мне, где ошибка или в чем ошибка. Я был в этом в течение нескольких дней. Может кто-нибудь помочь?

Кстати, я знаю, что код для пакета VHDL, основной код в порядке, просто Quartus II выдает мне неизвестную ошибку, и я не знаю, что делать. Я все перепробовал - добавлял что-то, удалял что-то, но все равно выдает мне сообщение «[имя файла] НЕ удалось (1 ошибка)».

library ieee;
use ieee.std_logic_1164.all;
package package1 is
    component NOT1
        generic(DELAY: time:=5ns);
        port(in1,in2: in std_logic; out1: out std_logic);
    end component;

    component AND2
        generic(DELAY: time:=5ns);
        port(in1,in2: in std_logic;out1: out std_logic);
    end component;

    component OR2
        generic(DELAY: time:=5ns);
        port(in1,in2: in std_logic;out1: out std_logic);
    end component;

    component XOR2
        generic(DELAY: time:=5ns);
        port(in1,in2: in std_logic;out1: out std_logic);
    end component;

    component ADD3
        generic(DELAY:time:=5ns);
        port(in1,in2,cin: in std_logic;sum,cout:out std_logic);
    end component;

    component INVERT3
        generic(delay:time:=5ns);
        port(in1,in2,in3:in std_logic; out1:out std_logic);
    end component;

    component OPERATION5
        generic(delay:time:=5ns);
        port(in1,in2,in3,in4,in5:in std_logic;out1:out std_logic);
    end component;
end package package1;

library ieee;
use ieee.std_logic_1164.all;
package body package1 is

    entity AND2 is
        generic(delay:time);
        port(in1,in2:in std_logic;out1:out std_logic);
    end AND2;
    architecture model_conc of AND2 is
        begin
            out1 <= in1 and in2 after delay;
    end model_conc;

    entity NOT1 is
        generic(delay:time);
        port(in1:in std_logic;out1:out std_logic);
    end NOT1;
    architecture model_conc1 of NOT1 is
        begin
            out1 <= not in1 after delay;
    end model_conc1;

    entity OR2 is
        generic(delay:time);
        port(in1,in2:in std_logic;out1:out std_logic);
    end OR2;
    architecture model_conc2 of OR2 is
        begin
            out1 <= in1 or in2 after delay;
    end model_conc2;

    entity XOR2 is
        generic(delay:time);
        port(in1,in2:in std_logic;out1:out std_logic);
    end XOR2;
    architecture model_conc3 of XOR2 is
        begin
            out1 <= in1 xor in2 after delay;
    end model_conc3;

    entity ADD3 is
        generic(delay: time);
        port(in1,in2,cin: in std_logic;sum,cout:out std_logic);
    end ADD3;
    architecture model_conc4 of ADD3 is
        begin   
            sum <= (in1 AND NOT in2 AND NOT cin) OR (NOT in1 AND in2 AND NOT cin) OR (NOT in1 AND NOT in2 AND cin) OR (in1 AND in2 AND cin);
            cout <= (in2 AND cin) OR (in1 AND cin) OR (in1 AND in2);
    end model_conc4;

    entity INVERT3 is
        generic(delay:time);
        port(in1,in2,in3:in std_logic; out1:out std_logic);
    end INVERT3;
    architecture model_conc5 of INVERT3 is
        begin
            if (in3=1) then
                out1 <= in1;
            else 
                out1 <= in2;
            end if; 
            after delay;
    end model_conc5;

    entity OPERATION5 is
        generic(delay:time);
        port(in1,in2,in3,in4,in5:in std_logic;out1:out std_logic);
    end OPERATION5;
    architecture model_conc6 of OPERATION5 is
        begin
            if in5=0 then
                out1 <= in1;
            elsif in5=1 then
                out1 <= in2;
            elsif in5=2 then
                out1 <= in3;
            else 
                out1<=in4;
            end if; 
            after delay;
    end model_conc6;




end package body package1; 
...