Skip to content

Instantly share code, notes, and snippets.

@koyamalmsteen
Created May 8, 2017 00:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save koyamalmsteen/1898b71e848b111fb097f989e65ee361 to your computer and use it in GitHub Desktop.
Save koyamalmsteen/1898b71e848b111fb097f989e65ee361 to your computer and use it in GitHub Desktop.
module DFF2(switch, clk, led); // User can't re-define "DFF" because it is defined as Quartus II primitives.
input switch, clk;
output led;
reg q;
always @(posedge clk) begin
q = switch;
end
assign led = q;
endmodule
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment