module LED_counter( input clk, output reg led ); reg [23:0] count; always @(posedge clk) begin count <= count + 1; if(count == 16777216) begin count <= 0; led <= ~led; end end endmodule [2024-07-10 21:30:40 | AI写代码神器 | 151点数解答]