Created
December 9, 2012 21:50
-
-
Save gibiansky/4247182 to your computer and use it in GitHub Desktop.
Verilog Fibonacci Module
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 fib(input clock, reset, input [5:0] n, output ready, output [31:0] value) | |
reg [31:0] previous, current; | |
reg [5:0] counter; | |
always @(posedge reset) | |
begin | |
previous <= 32'd0; | |
current <= 32'd1; | |
counter <= 32'd1; | |
end | |
endmodule |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment