fixed errors

This commit is contained in:
ANDREW HARRIS POND 2021-07-01 16:40:03 -06:00
parent 006b54c4bc
commit 808821bb8c
1 changed files with 21 additions and 20 deletions

View File

@ -35,15 +35,16 @@ module reset_generator(
`ifdef VIVADO_SYNTHESIS `ifdef VIVADO_SYNTHESIS
initial begin initial begin
pulse <= INITIAL_VALUE; clkdiv_counter <= 0;
active_cycle_counter <= 0; active_cycle_counter <= 0;
pulse <= INITIAL_VALUE;
end end
`endif `endif
// Wait a number of clock cycles, hold the initial value // Wait a number of clock cycles, hold the initial value
always @(posedge clk) begin always @(posedge clk) begin
if (active_cycle_counter == ACTIVE_CYCLES) begin if (active_cycle_counter == ACTIVE_CYCLES) begin
pulse <= ~INITIAL_VALUE; pulse <= ~pulse;
end else begin end else begin
active_cycle_counter <= active_cycle_counter + 1; active_cycle_counter <= active_cycle_counter + 1;
end end