aboutsummaryrefslogtreecommitdiffstats
path: root/machxo2/examples/blinky.v
blob: c7cde26d73aeaae7fdaf79ed88c77aefc285f603 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
module top(input clk, rst, output [7:0] leds);

reg [7:0] ctr;
always @(posedge clk)
	if (rst)
		ctr <= 8'h00;
	else
		ctr <= ctr + 1'b1;

assign leds = ctr;

endmodule