Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

help spartan 3 starter kit: reset signal

Status
Not open for further replies.

umairsiddiqui

Full Member level 2
Joined
Apr 13, 2004
Messages
143
Helped
7
Reputation
14
Reaction score
1
Trophy points
1,298
Location
Sweden
Activity points
1,434
verilog button debounce

the push buttons on starter kit are not debounced, how to generate
reset signal for processor duration 4-5 clk (20MHz)...
 

debouncer verilog

I guess that that the circuit in this post is what you need:



just add an extra flip flop to make them four clocks..
 
spartan 3 push buttons debounce

Hi

I also faced some problem when i was first worked on Xilinx Starter kit. In this kit, they din't provide the hardware for switch debouncing. You need to generate the switch debouncer core for the switches, before using them. Or you can search in internet, you can easily get the ready to use debouncer programs. Of course, it is very easy to write your own VHDL/Verilog program.


Regards,
Vishwa
 

verilog button debounceing

I have one of those little Spartan 3 boards. I debounce each button or switch by feeding it through two D-flops. Both flops are clocked at 50 MHz, but the second one is enabled only once every 20ms or so (I decode a counter that I'm using elsewhere). Debounce works great. Here is a Verilog example:

Code:
// Simple debouncer for 4 buttons.
// Choose "count" size so its period is longer than worst-case bounce.
module top (clk, button_in, button_out);
  input             clk;              // my clock is 50 MHz
  input       [3:0] button_in;        // four bouncy buttons
  reg        [19:0] count = 0;        // period approximately 20 ms
  reg         [3:0] button_tmp = 0;   // synchronize the inputs
  output reg  [3:0] button_out = 0;   // four debounced buttons

  always @ (posedge clk) begin
    count <= count + 1;
    button_tmp <= button_in;
    if (count == 0)
      button_out <= button_tmp;
  end
endmodule
I sometimes use fancier code for auto-repeat action, like a PC's keyboard.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top