下面是我修改了之后的程序,已经在61中编译通过!不知道是否与你的要求一致!
module queue (clk,clr,a,b,c,d,e,f);
input clk,clr,a,b,c;
output d,e,f;
reg d;
reg e;
reg f;
always @(posedge clk or negedge clr)
if(!clr)
begin
d=0;
e=0;
f=0;
end
else if(a==1)
begin
d=1;
e=0;
f=0;
end
else
begin
if(b==1)
begin
d=0;
e=1;
f=0;
end
else
begin
if(c==1)
begin
d=0;
e=0;
f=1;
end
else
begin
d=0;
e=0;
f=0;
end
end
end
endmodule
能够描述一下你这段程序所预期的效果,或者是要实现的功能是什么!
输入端的A,B,C就不需要申明为REG了。 REG的申明只是针对输出信号和内部信号。
还有什么想问的,看不出来