I have this code for generating a 25 Mhz clock having a 50 Mhz clock as main using the basys3 board. I use the LSB as the clock because it will goes 1/2 of the main clock of 50Mhz
always @(posedge mclk or posedge clr) begin if(clr == 1) q <= 0; else q <= q+1; end
assign clk25 = q[0];
endmodule
*////////////////////////* END OF CODE
So whenever I want to call it I just make a instance of this class.
In Vivado, when I open my synthesized project and click [Tools ---> Edit devices properties] This is where I select my clock frequency as 50 MHZ { Please see image attached }
So my questions are :
Is this the proper way to set up a clock using Vivado and the Basys3 Board?
In the main page of the Basys3 it says that one can get a clock as high as 450 Mhz but in the options of the [Tools ---> Edit devices properties] I can only find clocks as high as 66 Mhz
And just some basic ones
Why Vivado takes sooo long to synthesized, implement and generate the bitstream of an easy and small code? Just implementing in hardware an AND gate takes me 5 minnutes to download the program to the board. Is there a quicker way ?
Question
vicvicvar
Hello Forum ,
Its my first Post so I hope it helps everyone
I have this code for generating a 25 Mhz clock having a 50 Mhz clock as main using the basys3 board. I use the LSB as the clock because it will goes 1/2 of the main clock of 50Mhz
*//////////////////////* START OF CODE
//Clock
module clkdiv(
input wire mclk ,
input wire clr ,
output wire clk25
);
reg [24:0] q;
always @(posedge mclk or posedge clr)
begin
if(clr == 1)
q <= 0;
else
q <= q+1;
end
assign clk25 = q[0];
endmodule
*////////////////////////* END OF CODE
So whenever I want to call it I just make a instance of this class.
In Vivado, when I open my synthesized project and click [Tools ---> Edit devices properties] This is where I select my clock frequency as 50 MHZ { Please see image attached }
So my questions are :
And just some basic ones
Thanks Forum .
Link to comment
Share on other sites
16 answers to this question
Recommended Posts
Archived
This topic is now archived and is closed to further replies.