ECEN 248 Lab 6: De-Bouncing, Counters & LCD Display Control

Slides:



Advertisements
Similar presentations
COMP541 State Machines – II: Verilog Descriptions
Advertisements

Lecture 23: Registers and Counters (2)
Synchronous Sequential Logic
Table 7.1 Verilog Operators.
Lab 09 :D Flip Flop, Shift Registers and Switch Bounce: Slide 2 Slide 3 The D Flip Flop. 4-Bit Shift Register. Slide 4 Shift Register De-bounce System:
Give qualifications of instructors: DAP
Computer Science 210 Computer Organization Clocks and Memory Elements.
Latches CS370 –Spring 2003 Section 4-2 Mano & Kime.
Digital Design - Sequential Logic Design Chapter 3 - Sequential Logic Design.
NAND-gate Latch. Summary NAND-gate Latch The time sequence at right shows the conditions under which the set and reset inputs cause a state change, and.
CS 151 Digital Systems Design Lecture 19 Sequential Circuits: Latches.
Flip-Flops, Registers, Counters, and a Simple Processor
Switch Debouncing. Switches connected to sources of constant logic 0 and 1 are often used in digital systems to supply “user inputs”. In high speed digital.
Latches and Flip-Flops Discussion D8.1 Section 13-9.
Digital Logic Design Lecture 22. Announcements Homework 7 due today Homework 8 on course webpage, due 11/20. Recitation quiz on Monday on material from.
Half Adder Sum = X’Y+XY’ = X  Y Carry = XY YXYXYX  YYYX  XX XOR XNOR.
Sequential circuit Digital electronics is classified into combinational logic and sequential logic. In combinational circuit outpus depends only on present.
Debouncing Switches Mechanical switches are one of the most common interfaces to a uC. Switch inputs are asynchronous to the uC and are not electrically.
Latches Module M10.1 Section 7.1. Sequential Logic Combinational Logic –Output depends only on current input Sequential Logic –Output depends not only.
ENGIN112 L20: Sequential Circuits: Flip flops October 20, 2003 ENGIN 112 Intro to Electrical and Computer Engineering Lecture 20 Sequential Circuits: Flip.
Latches Section 4-2 Mano & Kime. Sequential Logic Combinational Logic –Output depends only on current input Sequential Logic –Output depends not only.
Generate a clock pulse clk inp outp
ELEN 468 Advanced Logic Design
C.S. Choy1 SEQUENTIAL LOGIC A circuit’s output depends on its previous state (condition) in addition to its current inputs The state of the circuit is.
Lessons from last lab: 1.Many had the “# skipping” problem 2.Most assumed there was something wrong with their code 3.How does one check their code? 4.SIMULATE!!
1 COMP541 State Machines – 2 Registers and Counters Montek Singh Feb 8, 2007.
Sequential Circuit  It is a type of logic circuit whose output depends not only on the present value of its input signals but on the past history of its.
1 CSE370, Lecture 14 Lecture 14 u Logistics n Midterm 1: Average 90/100. Well done! n Midterm solutions online n HW5 due date delayed until this Friday.
ENGSCI 232 Computer Systems Lecture 5: Synchronous Circuits.
Engineering Lecture 3 Digital Electronics by Jaroslaw Karcz.
Lecture 1 Combinational Logic Design & Flip Flop 2007/09/07 Prof. C.M. Kyung.
Lecture 5 Key Locker using FPGA 2007/10/05 Prof. C.M. Kyung.
ECEN 248 Lab 4: Multiplexer Based Arithmetic Logic Unit
BYU ECEn 320 Lab 4 UART Transmitter. BYU ECEn 320 UART Transmimtter Specification VGA Serial A1 Expansion Connector PS2 A2 Expansion Connector B1 Expansion.
1 CSE370, Lecture 17 Lecture 17 u Logistics n Lab 7 this week n HW6 is due Friday n Office Hours íMine: Friday 10:00-11:00 as usual íSara: Thursday 2:30-3:20.
ECA1212 Introduction to Electrical & Electronics Engineering Chapter 9: Digital Electronics – Sequential Logic by Muhazam Mustapha, November 2011.
Computer Organization & Programming Chapter 5 Synchronous Components.
ECEN 248: INTRODUCTION TO DIGITAL SYSTEMS DESIGN Dept. of Electrical and Computer Engineering.
1 COMP541 Sequential Circuits Montek Singh Feb 1, 2012.
Introduction to Sequential Logic
Jeff Yi CS 147. Circuits  Combinatorial – Circuit that only relies on inputs.  Sequential - Circuit determined by input as well as the previous state.
The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL State Machines Anselmo Lastra.
CEC 220 Digital Circuit Design Latches and Flip-Flops Monday, March 03 CEC 220 Digital Circuit Design Slide 1 of 19.
ECEN 248 Lab 2: Logic Minimization and Karnaugh Maps
Synchronous Sequential Logic A digital system has combinational logic as well as sequential logic. The latter includes storage elements. feedback path.
CO5023 Latches, Flip-Flops and Decoders. Sequential Circuit What does this do? The OUTPUT of a sequential circuit is determined by the current output.
Department of Electronic & Electrical Engineering Program design. USE CASES. Flow charts. Decisions. Program state.
1 COMP541 Finite State Machines - 1 Montek Singh Sep 22, 2014.
Sequential Logic Flip-Flop Circuits By Dylan Smeder.
ECEN 248: INTRODUCTION TO DIGITAL SYSTEMS DESIGN Dr. Shi Dept. of Electrical and Computer Engineering.
ECEN 248 Lab 7: Carry Look Ahead and Carry Save Adders Dept. of Electrical and Computer Engineering.
Latches, Flip Flops, and Memory ECE/CS 252, Fall 2010 Prof. Mikko Lipasti Department of Electrical and Computer Engineering University of Wisconsin – Madison.
ECEN 248: INTRODUCTION TO DIGITAL SYSTEMS DESIGN Dr. Shi Dept. of Electrical and Computer Engineering.
Dept. of Electrical Engineering
TOPIC : Introduction to Sequential Circuits UNIT 1: Modeling and Simulation Module 4 : Modeling Sequential Circuits.
1 COMP541 Sequential Logic – 2: Finite State Machines Montek Singh Feb 29, 2016.
Exp#7 Finite State Machine Design in Verilog COE203 Digital Logic Laboratory Dr. Ahmad Almulhem KFUPM Spring 2009.
40106B Schmitt Trigger (A way of switch De-Bouncing)
Computer Science 210 Computer Organization
FLIP FLOPS Binary unit capable of storing one bit – 0 or 1
ECEN 248 Lab 9: Design of a Traffic Light Controller
FIGURE 5.1 Block diagram of sequential circuit
Computer Science 210 Computer Organization
Latches and Flip-flops
Lesson Objectives Aims
Computer Science 210 Computer Organization
ECEN 248: INTRODUCTION TO DIGITAL SYSTEMS DESIGN
Computer Architecture and Organization: L02: Logic design Review
EE4OI4 Engineering Design
Sequential Logic.
Presentation transcript:

ECEN 248 Lab 6: De-Bouncing, Counters & LCD Display Control names Dept. of Electrical and Computer Engineering

Lab 6 in Brief Design an eight bit counter Bouncing counter De-bouncing counter Learn about configuring the LCD display

Sequential Logic We are only handling the combinational logic circuits in the previous labs Starting from Lab 5, we will deal with the sequential logic circuits In sequential logic circuits, the output will depend on not only the current input, but also the previous inputs. Always driven by clock pulses

Counter Using sequential logic to count clock events

Push Buttons A push button is a mechanical switch and rely on mechanical contact to generate an electrical pulses

Switch Bouncing When you push the button, it will not instantly give a 0 (or a 1 when inverted); instead, the voltage will fluctuate in a middle region at first. Voltages in the middle region are still interpreted (quantized) as 1’s and 0’s, so the output will “bounce” between 0 and 1 until the value settles. That means even you only push the button once, there will be multiple rising edges generated. Push Release

De-Bouncing Need to get rid of the bounces and get the “clean” signal Two methods RS latch based debouncing Needs two buttons Sampling based de-bouncing One button

Method 1: SR Latch Use the SR latch to clean the bouncing signal

Method 2: Sampling based debouncing always @ (posedge clock) if (reset) begin new <= noisy; clean <= noisy; count <= 0; end else if (noisy != new) begin new <= noisy; count <= 0; end else if (count == 500000) clean <= new; else count <= count+1; 9

LCD Display Two Verilog modules lcd_disp Given in the zip file for lab 5 You can reuse this module Lcd_int You need to design a specific lcd_int module for each lab Determine data display location in LCD One characters  8bit (check decoder chart Fig. 6.9) Outputs 32 eight-bit sequences for 32 characters in LCD

Lab 6 To-Do list Design 1 Configure LCD display Design 2 Design a non-debounced counter Design 3 Design a count-up counter and a count-down counter using non-debounced signal Design 4 Design a SR-latch based debounced up-counter Design 5 Design a sampling-based debounced up-counter

Deadlines Today 2 Weeks later Work on Lab 6 Lab 6 Post-Lab due Lab 7 Pre-Lab due at the beginning of class