ECE2030 Introduction to Computer Engineering Lecture 11: Building Blocks for Combinational Logic (2) Decoders/Encoders, Comparators Prof. Hsien-Hsin Sean.

Slides:



Advertisements
Similar presentations
Prof. João Miguel Fernandes Dept. Informática
Advertisements

1 The 2-to-4 decoder is a block which decodes the 2-bit binary inputs and produces four output All but one outputs are zero One output corresponding to.
ECE 2110: Introduction to Digital Systems Chapter 6 Combinational Logic Design Practices Encoders.
Digital Design: Combinational Logic Blocks
Give qualifications of instructors: DAP
CDA 3100 Recitation Week 10.
Logic Circuits Design presented by Amr Al-Awamry
Glitches & Hazards.
ECE2030 Introduction to Computer Engineering Lecture 13: Building Blocks for Combinational Logic (4) Shifters, Multipliers Prof. Hsien-Hsin Sean Lee School.
ECE2030 Introduction to Computer Engineering Lecture 9: Combinational Logic, Mixed Logic Prof. Hsien-Hsin Sean Lee School of Electrical and Computer Engineering.
Decoder.
Poster Title 95 point, Arial font Primary heading Xx xxx x xx xxxxx xx xxxx xxx xx xx x x xxxxx xxxx xx xxxxx xx xxxxxx xxx xx. X xx xxxx xxxxx xx xxxx.
MATH 310, FALL 2003 (Combinatorial Problem Solving) Lecture 16, Monday, October 6.
DIGITAL SYSTEMS TCE OTHER COMBINATIONAL LOGIC CIRCUITS WEEK 7 AND WEEK 8 (LECTURE 1 OF 3) COMPARATORS CODE CONVERTERS.
ECE 331 – Digital System Design Logic Circuit Design (Lecture #7)
COMBINATIONAL CIRCUITS USING TTL 74XX ICS
Chapter 3 Combinational Logic Design
MULTIPLES OF 2 By Preston, Lincoln and Blake. 2 X 1 =2 XX 2X1=2 1+1=2.
Any logic circuits can be transformed to an implementation where only NAND gates (and inverters) are used. The general approach to finding a NAND-gate.
ECE2030 Introduction to Computer Engineering Lecture 15: Registers, Toggle Cells, Counters Prof. Hsien-Hsin Sean Lee School of Electrical and Computer.
Combinational Circuits
ECE2030 Introduction to Computer Engineering Lecture 10: Building Blocks for Combinational Logic (1) Timing Diagram, Mux/DeMux Prof. Hsien-Hsin Sean Lee.
Charles Kime & Thomas Kaminski © 2004 Pearson Education, Inc. Terms of Use (Hyperlinks are active in View Show mode) Terms of Use Logic and Computer Design.
Outline Decoder Encoder Mux. Decoder Accepts a value and decodes it Output corresponds to value of n inputs Consists of: Inputs (n) Outputs (2 n, numbered.
Random-Access Memory (RAM)
COE 202: Digital Logic Design Combinational Circuits Part 3 Dr. Ahmad Almulhem ahmadsm AT kfupm Phone: Office: Ahmad Almulhem, KFUPM.
Combinational Logic Design BIL- 223 Logic Circuit Design Ege University Department of Computer Engineering.
ECE2030 Introduction to Computer Engineering Lecture 16: Finite State Machines Prof. Hsien-Hsin Sean Lee School of Electrical and Computer Engineering.
ECE2030 Introduction to Computer Engineering Lecture 12: Building Blocks for Combinational Logic (3) Adders/Subtractors, Parity Checkers Prof. Hsien-Hsin.
Functions of Combinational Logic
Combinational Logic. Digital Circuits Introduction Logic circuits for digital systems may be combinational or sequential. A combinational circuit.
Chapter 2Basic Digital Logic1 Chapter 2. Basic Digital Logic2 Outlines  Basic Digital Logic Gates  Two types of digital logic circuits Combinational.
ECE2030 Introduction to Computer Engineering Lecture 4: CMOS Network Prof. Hsien-Hsin Sean Lee School of Electrical and Computer Engineering Georgia Tech.
Logic Design CS 270: Mathematical Foundations of Computer Science Jeremy Johnson.
ECE2030 Introduction to Computer Engineering Lecture 8: Quine-McCluskey Method Prof. Hsien-Hsin Sean Lee School of Electrical and Computer Engineering.
1 ECE2030 Introduction to Computer Engineering Lecture 8: Quine-McCluskey Method Prof. Hsien-Hsin Sean Lee School of ECE Georgia Institute of Technology.
CS 151  What does the full truth table look like? InputsOutputs D3D3 D2D2 D1D1 D0D0 A1A1 A0A0 V 0000XX
Decoders, Encoders, Multiplexers
CS151 Introduction to Digital Design
CO UNIT-I. 2 Multiplexers: A multiplexer selects information from an input line and directs the information to an output line A typical multiplexer has.
Fuw-Yi Yang1 數位系統 Digital Systems Department of Computer Science and Information Engineering, Chaoyang University of Technology 朝陽科技大學資工系 Speaker: Fuw-Yi.
IB Computer Science – Logic
ECE2030 Introduction to Computer Engineering Lecture 6: Canonical (Standard) Forms Prof. Hsien-Hsin Sean Lee School of Electrical and Computer Engineering.
1 Chapter 4 Combinational Logic Logic circuits for digital systems may be combinational or sequential. A combinational circuit consists of input variables,
Computing Machinery Chapter 3: Combinational Circuits.
1 CS 151: Digital Design Chapter 3: Combinational Logic Design 3-1Design Procedure CS 151: Digital Design.
 Seattle Pacific University EE Logic System DesignMux-Decoder-1 Multiplexers Two alternative forms for a 2:1 Mux Truth Table Functional form Logical.
Prof. Hsien-Hsin Sean Lee
ECE2030 Introduction to Computer Engineering Lecture 5: Boolean Algebra Prof. Hsien-Hsin Sean Lee School of Electrical and Computer Engineering Georgia.
Instructor: Alexander Stoytchev CprE 281: Digital Logic.
1 Combinational Logic EE 208 – Logic Design Chapter 4 Sohaib Majzoub.
Combinational Circuit Design. Digital Circuits Combinational CircuitsSequential Circuits Output is determined by current values of inputs only. Output.
Combinational Circuits. Outline Boolean Algebra Decoder Encoder MUX.
1 ECE2030 Introduction to Computer Engineering Lecture 4: CMOS Network Prof. Hsien-Hsin Sean Lee School of ECE Georgia Institute of Technology.
Multiplexer.
CEC 220 Digital Circuit Design Decoders, Encoders, & ROM Wed, February 19 CEC 220 Digital Circuit Design Slide 1 of 18.
Lecture No. 16 Vishal Jethva Digital Logic & Design svbitec.wordpress.com.
Logic Design (CE1111 ) Lecture 4 (Chapter 4) Combinational Logic Prepared by Dr. Lamiaa Elshenawy 1.
Fuw-Yi Yang1 數位系統 Digital Systems Department of Computer Science and Information Engineering, Chaoyang University of Technology 朝陽科技大學資工系 Speaker: Fuw-Yi.
Decoder. 2 ABC 3:8 dec O0O0 O1O1 O2O2 A B C Enb S2S2 S1S1 S0S0 O3O3 O4O4 O5O5 O6O6 O7O7 EABC O0O0 O1O1 O2O2 O3O3 O4O4 O5O5 O6O6 O7O7 0XXX
Decoders A decoder is a logic circuit that detects the presence of a specific combination of bits at its input. Two simple decoders that detect the presence.
Encoders The inverse function of a decoder. Priority Encoder resolve the ambiguity of illegal inputs only one of the input is encoded D 3 has the highest.
ECE2030 Introduction to Computer Engineering Lecture 20: Datapath and Microcode Control Prof. Hsien-Hsin Sean Lee School of Electrical and Computer Engineering.
Prof. Hsien-Hsin Sean Lee
Part 4 Combinational Logic.
Combinational Circuit Design
Reference: Chapter 3 Moris Mano 4th Edition
ECE 2110: Introduction to Digital Systems Chapter 6 Combinational Logic Design Practices Encoders.
Digital Logic & Design Dr. Waseem Ikram Lecture No. 16.
Instructions and Examples Version 1.5
Presentation transcript:

ECE2030 Introduction to Computer Engineering Lecture 11: Building Blocks for Combinational Logic (2) Decoders/Encoders, Comparators Prof. Hsien-Hsin Sean Lee School of Electrical and Computer Engineering Georgia Tech

2 1-to-2-Line DecoderAD1D D0 D1 A

3 N-to-M-Line Decoder (2 N  M) A1A0D3D2D1D D0D0 D1D1 D2D2 D3D3 2-to-4-linedecoder A0A0 A1A1

4 2-to-4-Line Decoder A1A0D3D2D1D How about if no one should be enabled ? A1 A0 D0 D1 D2 D3

5 2-to-4-Line Decoder w/ Enable EnA1A0D3D3 D2D2 D1D1 D0D0 0XX D0D0 D1D1 D2D2 D3D3 2-to-4-linedecoder A0A0 A1A1 En

6 2-to-4-Line Decoder w/ Enable EnA1A0D3D3 D2D2 D1D1 D0D0 0XX A1 A0 D0 D1 D2 D3 En

7 3-to-8-Line Decoder A2A1A0D7D7 D6D6 D5D5 D4D4 D3D3 D2D2 D1D1 D0D Truth Table

8 3-to-8-Line Decoder A2A1A0D7D7 D6D6 D5D5 D4D4 D3D3 D2D2 D1D1 D0D Truth Table

9 3-to-8-Line Decoder A2A1A0D7D6D5D4D3D2D1D D0D0 D1D1 D2D2 D3D3 2-to-4-linedecoder A0A0 A1A1 En D0D0 D1D1 D2D2 D3D3 D0D0 D1D1 D2D2 D3D3 2-to-4-linedecoder A0A0 A1A1 D4D4 D5D5 D6D6 D7D7 A0A0 A1A1 A2A2

10 Implementing Logic w/ Decoder D0D0 D1D1 D2D2 D3D3 3-to-8-linedecoder A0A0 A1A1 A2A2 D4D4 D5D5 D6D6 D7D7 X Y Z F1 F2

11 BCD-to-7- Segment Decoder BCD-to-7-Segment Decoder Another kind of decoder a b c d e f g a b c d e f g A B C D

12 BCD-to-7- Segment Decoder BCD-to-7-Segment Decoder Another kind of decoder a b c d e f g a b c d e f g A B C D a b c d e g f

13 BCD-to-7- Segment Decoder BCD-to-7-Segment Decoder Decode “2” and show a b c d e f g a b c d e f g A B C D a b c d e g f

14 BCD-to-7- Segment Decoder BCD-to-7-Segment Decoder Decode “4” and show a b c d e f g a b c d e f g A B C D a b c d e g f

15 BCD-to-7-Seg. Decoder Truth Table ABCDabcdefg >10All other inputs

16 Design Each Output Individually  “a” ABCDa >10All other inputs AB CD

17 Design Each Output Individually  “b” ABCDb >10All other inputs AB CD

18 M-to-N-Line Encoder (M  2 N ) D0D0 D1D1 D2D2 D3D3 2-to-4-lineDecoder A0A0 A1A1 En D0D0 D1D1 D2D2 D3D3 4-to-2-lineEncoder A0A0 A1A1 Ac

19 4-to-2 Encoder D3D2D1D0A1A Since Dx=1 only in one column at a time A0 = D1 + D3 A1 = D2 + D X0X1 01 0XXX 11 XXXX 10 1XXX D3 D2 D1 D0 For A X0X0 01 1XXX 11 XXXX 10 1XXX D3 D2 D1 D0 For A1

20 8-to-3 Encoder D7D6D5D4D3D2D1D0A2A1A Since Dx=1 only in one column at a time A0 = D1 + D3 + D5 + D7 A1 = D2 + D3 + D6 + D7 A2 = D4 + D5 + D6 + D7

21 Example 1 of an Encoder Only point to one single reading at a time.

22 Example 2 of an Encoder D0D0 D1D1 D2D2 D3D3 8-to-3-lineEncoder A0A0 A1A1 A2A2 D4D4 D5D5 D6D6 D7D7 Amy Brian Cathy Dave Ellen Frank Gina Hugh Ac Active or not ? ? ? 1

23 8-to-3 Priority Encoder D7D6D5D4D3D2D1D0A2A1A0Active X XX XXX XXXX XXXXX XXXXXX1101 1XXXXXXX1111

24 4-to-2 Priority Encoder D3D2D1D0A1A0Active X011 01XX101 1XXX D3 D2 D1 D0 For A1 Or using simplification property

25 4-to-2 Priority Encoder D3D2D1D0A1A0Active X011 01XX101 1XXX D3 D2 D1 D0 For A0 Or using simplification property

26 4-to-2 Priority Encoder D3D2D1D0A1A0Active X011 01XX101 1XXX D3 D2 D1 D0 For Active

27 4-to-2 Priority Encoder Schematic D3 D2 D1 D0 A1 A0 Active

28 8-to-3 Priority Encoder (A2) D7D6D5D4D3D2D1D0A2A1A0Active X XX XXX XXXX XXXXX XXXXXX1101 1XXXXXXX1111

29 8-to-3 Priority Encoder (A1) D7D6D5D4D3D2D1D0A2A1A0Active X XX XXX XXXX XXXXX XXXXXX1101 1XXXXXXX1111

30 8-to-3 Priority Encoder (A0) D7D6D5D4D3D2D1D0A2A1A0Active X XX XXX XXXX XXXXX XXXXXX1101 1XXXXXXX1111

31 8-to-3 Priority Encoder (All) D7D6D5D4D3D2D1D0A2A1A0Active X XX XXX XXXX XXXXX XXXXXX1101 1XXXXXXX1111

32 1-bit Magnitude Comparator ABA?B 00A=B 01A<B 10A>B 11A=B AB A > B A = B A < B Single bit comparison

33 2-bit Magnitude Comparator (unsigned) AB A > B A = B A < B Two-bit comparison 2 2 A1A0B1B0A1A0B1B0

34 2-bit Magnitude Comparator (unsigned) AB A > B A = B A < B Two-bit comparison 2 2 A1A0B1B0A1A0B1B0

35 3-bit Magnitude Comparator (unsigned) Three-bit comparison A2A1A0B2B1B0A2A1A0B2B1B0 AB A > B A = B A < B 3 3

36 4-bit Magnitude Comparator (unsigned) Four-bit comparison A3A2A1A0B3B2B1B0A3A2A1A0B3B2B1B0 AB A > B A = B A < B 4 4

37 4-bit Magnitude Comparator B3A3A2A1A0B2B1B0 X3 X2 X1 X0 A>BA<B A=B

38 Cascading Comparator AB A > B A = B A < B 4 4 AGTBin AGTBout AEQBout ALTBout Inputs from Prior stage Lower order bits (Lower order bits) AEQBin ALTBin Extra Comb. Logic Outputs to Next stage Higher order bits (Higher order bits) AGTBout = (A>B) + (A=B) · AGTBin AEQBout = (A=B) · AEQBin ALTBout = (A<B) + (A=B) · ALTBin

39 16-bit Cascading Comparator AB AGTBin AEQBin ALTBin 4 4 AGTBout AEQBout ALTBout A[3:0] B[3:0] AB AGTBin AEQBin ALTBin 4 4 AGTBout AEQBout ALTBout A[7:4] B[7:4] AB AGTBin AEQBin ALTBin 4 4 AGTBout AEQBout ALTBout A[11:8] B[11:8] AB AGTBin AEQBin ALTBin 4 4 AGTBout AEQBout ALTBout A[15:12] B[15:12] A>B A<B A=B B[15:0] A[15:0]