//对50M进行250万次分频,分频成2HZ的时钟信号,输出控制26个发光二极管
module led_1(clk,clk1);
|
文件: |
led_1.rar |
大小: |
285KB |
下载: |
下载 | |
input clk;
//output [6:0] led;
output clk1;
reg [27:0] count;
reg [25:0] clk1;
always @(posedge clk)
begin
count=count+1;
if(count==28'd25000000) // chan sheng 2HZ clk dui 50MHZ 2500'0000 ci fen ping
begin
count=28'd0;
clk1=~clk1;
end
end
endmodule
阅读(765) | 评论(0) | 转发(0) |