Created
December 6, 2019 14:11
-
-
Save Ravenslofty/fcd6761a630b3688956a9a63a0b13ed8 to your computer and use it in GitHub Desktop.
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 MISTRAL_FF(input D, CLK, ACn, ASn, EN, output reg Q); | |
parameter INIT = 1'b0; | |
initial Q = INIT; | |
always @(posedge CLK or negedge ACn or negedge ASn) begin | |
if (!ACn) begin | |
Q <= 0; | |
end | |
else if (!ASn) begin | |
Q <= 1; | |
end | |
else begin | |
if (EN) Q <= D; | |
end | |
end | |
endmodule |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment