-3

In Verilog HDL describe a hardware that is able to generate a clock frequency f 0 of approximately 3Hz. Display this clock by connecting it to LED LD7 to verify your approach. I tried a lot but not able to get right output.

Device:-Basys2 Spartan3e

Massnk Dev
  • 19
  • 1
  • 6

1 Answers1

1

I will give the steps(not the code) to create a clock divider which is what you need here.

  1. Say you clock has frequency f. Create a counter which counts from 1 to f/2.
  2. Say your new divided clock name is clk_new. Initialize this clk_new to zero.
  3. Whenever the counter value is in its maximum (which is f/2), toggle clk_new. you can do this by clk_new = ~clk_new; and also reset the counter to zero and let it begin the counting again.

Write the code and if it doesnt work, post here. We can help.

vipin
  • 1,610
  • 3
  • 16
  • 27