CENG 241 Digital Design 1 Lecture 5 Amirali Baniasadi

Slides:



Advertisements
Similar presentations
Chapter 3 Gate-Level Minimization
Advertisements

Chapter3: Gate-Level Minimization Part 2
Verilog Section 3.10 Section 4.5. Keywords Keywords are predefined lowercase identifiers that define the language constructs – Key example of keywords:
CS 121 Digital Logic Design
CENG 241 Digital Design 1 Lecture 2 Amirali Baniasadi
CENG 241 Digital Design 1 Lecture 4
CPEN Digital System Design
Figure 4.1. The function f (x1, x2, x3) =  m(0, 2, 4, 5, 6).
CENG 241 Digital Design 1 Lecture 1 Amirali Baniasadi
SYEN 3330 Digital SystemsJung H. Kim Chapter SYEN 3330 Digital Systems Chapters 4 – Part3: Verilog – Part 1.
Exclusive-OR and Exclusive-NOR Gates
Gate-Level Minimization

Gate-Level Minimization. Digital Circuits The Map Method The complexity of the digital logic gates the complexity of the algebraic expression.
DON’T CARE CONDITIONS Functions that have unspecified output for some input combinations are called incompletely specified functions. Unspecified minterms.
08/07/041 CSE-221 Digital Logic Design (DLD) Lecture-8:
Combinational Logic Chapter 4. Digital Circuits Introduction Logic circuits for digital systems may be combinational or sequential. A combinational.
ECE 353 Computer Systems Lab I Verilog Hardware Description Language.
Combinational Logic Discussion D2.5. Combinational Logic Combinational Logic inputsoutputs Outputs depend only on the current inputs.
Combinational Logic Chapter 4.
Hardware Description Language HDL. 2 Hardware Description Language HDL  Describes circuits and systems in text. −As a software program.  Can be processed.
CS 105 Digital Logic Design
CENG 241 Digital Design 1 Lecture 5
Digital Logic Lecture 08 By Amr Al-Awamry. Combinational Logic 1 A combinational circuit consists of an interconnection of logic gates. Combinational.
Combinational Logic Design CS341 Digital Logic and Computer Organization F2003.
Module 3.  Binary logic consists of :  logic variables  designated by alphabet letters, e.g. A, B, C… x, y, z, etc.  have ONLY 2 possible values:
Combinational Logic Chapter 4. Digital Circuits Combinational Circuits Logic circuits for digital system Combinational circuits the outputs are.
CORRECTION Last session, I have made a mistake about two digital coding methods. I explained Hamming code as Grey code mistakenly. Here is correct explanation.
1 Chapter 4 Combinational Logic Logic circuits for digital systems may be combinational or sequential. A combinational circuit consists of input variables,
Documentation Standards Circuit specification. –Description of what the system is supposed to do, including a description of all inputs and outputs and.
Combinational Logic. Digital Circuits Introduction Logic circuits for digital systems may be combinational or sequential. A combinational circuit.
Gate-Level Minimization Chapter 3. Digital Circuits The Map Method The complexity of the digital logic gates the complexity of the algebraic expression.
Digital System Ch4-1 Chapter 4 Combinational Logic Ping-Liang Lai ( 賴秉樑 ) Digital System 數位系統.
D IGITAL L OGIC D ESIGN I G ATE -L EVEL M INIMIZATION.
Module 9.  Digital logic circuits can be categorized based on the nature of their inputs either: Combinational logic circuit It consists of logic gates.
Digital Electronics Lecture 6 Combinational Logic Circuit Design.
CPEN Digital System Design
October 29, 2015 EASTERN MEDITERRANEAN UNIVERSITY1 Digital Logic Design I Gate-Level Minimization Mustafa Kemal Uyguroğlu.
Exclusive OR Gate. Logically, the exclusive OR (XOR) operation can be seen as either of the following operations:exclusive OR (XOR) 1. A AND NOT B OR.
Chapter 3 Gate-Level Minimization
3.Gate-Level Minimization
Chapter 3 Gate-level Minimization. 3-7 NAND and NOR Implementation Digital circuits are frequently constructed with NAND or NOR gates rather than with.
A.Abhari CPS2131 Chapter 3: Gate-Level Minimization Topics in this Chapter: The Map Method Two-Variable Map Three- Variable Map Four/Five variable Map.
TUTORIAL CHAPTER 3 GATE_LEVEL MINIMIZATION PART 2 TA. Arwa Al Saad. 9 November 2013.
CS 1110 Digital Logic Design
Anurag Dwivedi. Basic Block - Gates Gates -> Flip Flops.
CS 121 Digital Logic Design Gate-Level Minimization Chapter 3.
CS 105 DIGITAL LOGIC DESIGN Chapter 4 Combinational Logic 1.
Digital Electronics Chapter 3 Gate-Level Minimization.
HDL Model Combinational circuits. module halfadder(s, cout, a, b); input a, b; output s, cout; xor g1(s, a, b); and g2(cout, a, b); endmodule.
Combinational Circuits
Combinational Logic Design. 2 Combinational Circuits A combinational logic circuit has: ♦ A set of m Boolean inputs, ♦ A set of n Boolean outputs ♦ n.
COE 202 Introduction to Verilog Computer Engineering Department College of Computer Sciences and Engineering King Fahd University of Petroleum and Minerals.
ECE 2110: Introduction to Digital Systems Chapter 6 Combinational Logic Design Practices XOR and parity check Circuits.
Lecture 07 Digital logic By Amr Al-Awamry. 4 variables K-Map.
C OMBINATIONAL L OGIC D ESIGN 1 Eng.Maha AlGubali.
Combinational Logic Design. 2 Combinational Circuits A combinational logic circuit has: ♦ A set of m Boolean inputs, ♦ A set of n Boolean outputs ♦ n.
Fuw-Yi Yang1 數位系統 Digital Systems Department of Computer Science and Information Engineering, Chaoyang University of Technology 朝陽科技大學資工系 Speaker: Fuw-Yi.
Chapter 4 Combinational Logic. 4.1 Introduction   Logic circuits for digital systems may be combinational or sequential. A combinational circuit consists.
Introduction to Verilog COE 202 Digital Logic Design Dr. Muhamed Mudawar King Fahd University of Petroleum and Minerals.
Speaker: Fuw-Yi Yang 楊伏夷 伏夷非征番, 道德經 察政章(Chapter 58) 伏者潛藏也
Combinational Logic Design
PROPAGATION DELAY.
Introduction to Verilog
FIGURE 4.1 Block diagram of combinational circuit
Lecture 1.3 Hardware Description Languages (HDLs)
King Fahd University of Petroleum and Minerals
Digital Logic Design I Gate-Level Minimization
مدار منطقی به نام یگانه مهندس هستی مهدی قدیری
XOR Function Logic Symbol  Description  Truth Table 
Presentation transcript:

CENG 241 Digital Design 1 Lecture 5 Amirali Baniasadi

2 This Lecture zLab zReview of last lecture: Gate-Level Minimization zContinue Chapter 3:XOR functions, Hardware Description Language zHW 2: Due Thursday May 31st. zFIRST MIDTERM: THURSDAY JUNE 14, IN CLASS.

3 Midterm 1 zCENG 241 Digital Design 1 Midterm #1 (sample) zImportant Note: Show your work for all sections. zConsider the following Boolean function: z F(A, B, C, D, E) = Σ (8,10,13,15,16,18,21,23,25,27) and d(A, B, C, D, E) = Σ (0,2,5,7,29,31) zUse the 1’s in the map to find the simplest Boolean function and implement it using only NAND gates. Draw the logic.(10 points) zUse the 0’s in the map to find the simplest Boolean function and implement it using only NOR gates. Draw the logic. (10 points) zNOTE: Each gate may have up to 3 inputs.

4 zSum of Products and Product of Sums result in two level designs zNot all designs are two-level e.g., F=A.(C.D+B)+B.C’ zHow do we convert multilevel circuits to NAND circuits? zRules z 1-Convert all ANDs to NAND gates with AND-invert symbol z 2-Convert all Ors to NAND gates with invert-OR symbols z 3-Check the bubbles, insert bubble if not compensated Multilevel NAND circuits

5 BC’ B’

6 Multilevel NAND circuits

7 Exclusive-OR Function X XOR Y = X’.Y+X.Y’ two input XOR IS 1 if both inputs are not similar

8 Three-input XOR Function F = A XOR B XOR C Multiple input XOR is 1 only if the number of 1 variables is odd: ODD function

9 ODD Function Implementation

10 Four-input XOR Function F detects odd number of 1s, F’ detects even number of 1’s

11 Parity Generation and Checking zParity bit: extra bit to ensure correct transmission of data zParity bit is included in the message to make the number of 1s either odd (odd parity) or even (even parity). zWe can use XOR to see if the number of 1’s is odd. zWe can use XOR-invert to see if the number of 1’s is even. zWe include the XOR output in the message zLater at receiver we check the number of 1 bits to see if the transmission is correct.

12 Parity Generation and Checking circuits

13 zHardware Description Language explains hardware in textual form zRepresents digital circuits zHDL has two applications: 1-Simulation: represents structure and behavior of digital circuits 2-Synthesis:Derives a list of components and interconnections from HDL. Two examples of HDL: VHDL, Verilog We use verilog since its easier to learn. Hardware Description Language

14 Hardware Description Language-example //HDL Example 3-1 // //Description of the simple circuit of Fig module smpl_circuit(A,B,C,x,y); input A,B,C; output x,y; wire e; and g1(e,A,B); not g2(y, C); or g3(x,e,y); endmodule

15 //HDL Example 3-2 // //Description of circuit with delay module circuit_with_delay (A,B,C,x,y); input A,B,C; output x,y; wire e; and #(30) g1(e,A,B); or #(20) g3(x,e,y); not #(10) g2(y,C); endmodule Hardware Description Language-example How do we take into account gate delays?

16 Test bench zTo simulate circuits we need input signals. zThe HDL description that provides the input/stimulus is called a test bench

17 //HDL Example 3-3 // //Stimulus for simple circuit module stimcrct; reg A,B,C; wire x,y; circuit_with_delay cwd(A,B,C,x,y); initial begin A = 1'b0; B = 1'b0; C = 1'b0; #100 A = 1'b1; B = 1'b1; C = 1'b1; #100 $finish; end endmodule //Description of circuit with delay module circuit_with_delay (A,B,C,x,y); input A,B,C; output x,y; wire e; and #(30) g1(e,A,B); or #(20) g3(x,e,y); not #(10) g2(y,C); endmodule Test bench example

18 Test bench example simulation output

19 Combinational Logic Combinational Logic: Output only depends on current input Sequential Logic:Output depends on current and previous inputs

20 Design Procedure z1.The number of inputs and outputs? z2.Derive the truth table z3.Obtain the Boolean Function z4.Draw the logic diagram, verify correctness

21 Design Procedure example zBinary Adder-Subtractor zBasic block is a half adder. zHalf Adder Design: z1.needs 2 inputs 2 outputs z2. Truth Table: x y C S z3. S=x’y+xy’ C=xy

22 Half Adder circuit

23 Full Adder? zTruth Table: zx y z C S z z z z z z z z

24 Full Adder Map

25 Full Adder Circuit

26 Full Adder Circuit Half adder ?

27 4-bit Adder Circuit But this is slow...

28 Summary zImplementation, XOR, Parity Checking, HDL zReading up to page 121-end of chapter 3 zHomework 2: problems 3-11, 3-15, 3-20, 3-23 and 3-24 from textbook