Created
April 23, 2021 15:08
-
-
Save ddribin/94659d97c59b44317e0fad734ed70c94 to your computer and use it in GitHub Desktop.
Asynchronous Assertion, Synchronous De-assertion
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module reset_sync( | |
output reg rst_sync, | |
input clk, rst_n | |
); | |
reg R1; | |
always @(posedge clk or negedge rst_n) | |
if(!rst_n) begin | |
R1 <= 1'b0; | |
rst_sync <= 1'b0; | |
end else begin | |
R1 <= 1'b1; | |
rst_sync <= R1; | |
end | |
endmodule |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
From http://chipverification.blogspot.com/2008/05/asynchronous-and-synchronous-reset.html