📄 count10.v.bak
字号:
module count10(out,cout,en,clk,clr,gz);
output[3:0] out;
output cout;
input en,clr,clk,gz;
reg[3:0] out;
always @(posedge clk or posedge clr)
begin
if(clr) out<=0;
else if(gz)
begin
if(en)
begin if(out==9)out<=0;
else out<=out+1;
end
end
end
assign cout=((out==9)&en)?1:0;
endmodule
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -