1 / 10

MC613 Laboratório de Circuitos Lógicos

MC613 Laboratório de Circuitos Lógicos. 2010 Profs.: Guido Araújo ( guido @ ic ….) Mário Lúcio Cortes ( cortes @ ic….. ). MC613 Debouncer. Conteúdo. O Problema SPDT – Single Pole, Single Throw SPST – Single Pole, Double Throw SPDT – Solução SPST – Solução Circuito RC

Download Presentation

MC613 Laboratório de Circuitos Lógicos

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. MC613Laboratório de Circuitos Lógicos 2010 Profs.: Guido Araújo (guido @ ic ….) Mário Lúcio Cortes (cortes @ ic…..) MC613 – 1s2010

  2. MC613Debouncer MC613 – 1s2010

  3. Conteúdo • O Problema • SPDT – Single Pole, Single Throw • SPST – Single Pole, Double Throw • SPDT – Solução • SPST – Solução • Circuito RC • Digital - Contador (freqüência de operação) • Digital - Shift-Register (baixa freqüência) MC613 – 1s2010

  4. SPST SPDT O Problema MC613 – 1s2010

  5. SPDT - Solução MC613 – 1s2010

  6. SPST – SoluçãoCircuito RC MC613 – 1s2010

  7. D D Q Q SPST – SoluçãoDigital - freqüência de operação Borda Sw Sujo Sw Limpo R QH clk Count MC613 – 1s2010

  8. SPST – Solução VHDL - baixa freqüência LIBRARY IEEE; USE IEEE.STD_LOGIC_1164.all; USE IEEE.STD_LOGIC_ARITH.all; USE IEEE.STD_LOGIC_UNSIGNED.all; -- Debounce Pushbutton: Filters out mechanical switch -- bounce for around 40Ms. ENTITY debounce IS PORT(pb, clock_100Hz : IN STD_LOGIC; pb_debounced : OUT STD_LOGIC); END debounce; MC613 – 1s2010

  9. SPST – Solução VHDL(cont.) ARCHITECTURE a OF debounce IS SIGNAL SHIFT_PB : STD_LOGIC_VECTOR(3 DOWNTO 0); BEGIN -- Debounce clock should be approximately 10ms or 100Hz PROCESS BEGIN WAIT UNTIL (clock_100Hz'EVENT) AND (clock_100Hz = '1'); -- Use a shift register to filter switch contact bounce SHIFT_PB(2 DOWNTO 0) <= SHIFT_PB(3 DOWNTO 1); SHIFT_PB(3) <= NOT PB; IF SHIFT_PB(3 DOWNTO 0) = "0000" THEN PB_DEBOUNCED <= '0'; ELSE PB_DEBOUNCED <= '1'; END IF; END PROCESS; END a; MC613 – 1s2010

  10. Debouncer na placa DE1 • Push buttons • sinais já limpos com Schmitt Trigger concepção  • Toggle switches • sinal sujo  necessário passar por debouncer se for usado como clock MC613 – 1s2010

More Related