Я пытаюсь реализовать простой код Verilog, как показано ниже:Почему в verilog возникает следующая ошибка повторного выделения?
module test1(
input ACLK,
input RST,
output test_output1,
output test_output2
);
//wire ACLK;
//wire RST;
reg test_output1;
reg test_output2;
assign test_output1 = ACLK;
always @(posedge ACLK or negedge RST)
begin
if(!RST)
begin
//test_output1 <=0;
test_output2 <=0;
end
else
begin
//test_output1 <=0;
test_output2 <=1;
end
end
endmodule
Я получаю следующее сообщение об ошибке, когда я пытаюсь синтезировать его в Xilinx ISE:
=========================================================================
* HDL Compilation *
=========================================================================
Compiling verilog file "test1.v" in library work
ERROR:HDLCompilers:27 - "test1.v" line 30 Illegal redeclaration of 'test_output1'
ERROR:HDLCompilers:27 - "test1.v" line 31 Illegal redeclaration of 'test_output2`
Я не в состоянии решить эта ошибка. Любая помощь будет высоко оценен.
test_output1 был объявлен как регистр, так и провод. – vim