多输出counter在xilinx中的综合,报错!为什么?
时间:10-02
整理:3721RD
点击:
module CNT3 (RST,EN,CLK,OUT,OUT_EN,OUT_RES);
inputEN,RST,CLK;
outputOUT_EN,OUT_RES;
output[7:0]OUT;
reg[7:0]OUT;
regOUT_EN,OUT_RES;
always@(posedge CLK or posedge EN) begin
if(RST) begin
OUT<=0;
OUT_EN<=0;
OUT_RES<=0;
end
else if (EN)
//fork
begin
if (OUT ==8'b001100100)begin//Na=100
OUT<=0;OUT_EN<=0;
end
else
OUT<=OUT+1;
end
if (OUT==1)
OUT_EN<=1;
if (OUT==0)
OUT_RES<=1;
else
OUT_RES<=0;
//join
end
endmodule
error:
ERROR:Xst:899 - N.v line 879: The logic for <OUT> does not match a known FF or Latch template.
ERROR:Xst:899 - N.v line 893: The logic for <OUT_EN> does not match a known FF or Latch template.
ERROR:Xst:899 - N.v line 896: The logic for <OUT_RES> does not match a known FF or Latch template.
Found 3 error(s). Aborting synthesis.
-->
inputEN,RST,CLK;
outputOUT_EN,OUT_RES;
output[7:0]OUT;
reg[7:0]OUT;
regOUT_EN,OUT_RES;
always@(posedge CLK or posedge EN) begin
if(RST) begin
OUT<=0;
OUT_EN<=0;
OUT_RES<=0;
end
else if (EN)
//fork
begin
if (OUT ==8'b001100100)begin//Na=100
OUT<=0;OUT_EN<=0;
end
else
OUT<=OUT+1;
end
if (OUT==1)
OUT_EN<=1;
if (OUT==0)
OUT_RES<=1;
else
OUT_RES<=0;
//join
end
endmodule
error:
ERROR:Xst:899 - N.v line 879: The logic for <OUT> does not match a known FF or Latch template.
ERROR:Xst:899 - N.v line 893: The logic for <OUT_EN> does not match a known FF or Latch template.
ERROR:Xst:899 - N.v line 896: The logic for <OUT_RES> does not match a known FF or Latch template.
Found 3 error(s). Aborting synthesis.
-->
多输出counter在xilinx中的综合,报错!为什么?
把en从敏感表里面去掉。
多输出counter在xilinx中的综合,报错!为什么?
把敏感表里的EN改成RST,估计你本来就是这个意思,结果写错啦
多输出counter在xilinx中的综合,报错!为什么?
sqsq
多输出counter在xilinx中的综合,报错!为什么?
xilinx不支持 fork ...jion 用什么方法取代呢?前提是能同步工作。