Improve blinky testbench, double blink frequency

Signed-off-by: Clifford Wolf <clifford@clifford.at>
This commit is contained in:
Clifford Wolf 2018-06-30 08:00:51 +02:00
parent 25f07549a1
commit 172ceef377
2 changed files with 7 additions and 4 deletions

View File

@ -13,7 +13,7 @@ module blinky (
); );
localparam BITS = 5; localparam BITS = 5;
localparam LOG2DELAY = 22; localparam LOG2DELAY = 21;
reg [BITS+LOG2DELAY-1:0] counter = 0; reg [BITS+LOG2DELAY-1:0] counter = 0;
reg [BITS-1:0] outcnt; reg [BITS-1:0] outcnt;

View File

@ -14,9 +14,12 @@ module blinky_tb;
); );
initial begin initial begin
$dumpfile("blinky_tb.vcd"); // $dumpfile("blinky_tb.vcd");
$dumpvars(0, blinky_tb); // $dumpvars(0, blinky_tb);
repeat (9000000) @(posedge clk); repeat (10) begin
repeat (900000) @(posedge clk);
$display(led1, led2, led3, led4, led5);
end
$finish; $finish;
end end
endmodule endmodule