Logic Circuits Basic Building Blocks Dr John Cowell

Slides:



Advertisements
Similar presentations
A Simple ALU Binary Logic.
Advertisements

Chapter 4 Gates and Circuits.
Chapter 4 Gates and Circuits.
ENGIN112 L7: More Logic Functions September 17, 2003 ENGIN 112 Intro to Electrical and Computer Engineering Lecture 7 More Logic Functions: NAND, NOR,
Discrete Mathematical Structures: Theory and Applications
Chapter 3 Logic Gates and Boolean Algebra – Part 1
Gates and Circuits Nell Dale & John Lewis (adaptation by Erin Chambers and Michael Goldwasser)
Digital Logic Design Gate-Level Minimization
Charles Kime & Thomas Kaminski © 2004 Pearson Education, Inc. Terms of Use (Hyperlinks are active in View Show mode) Terms of Use Chapter 2 – Combinational.
Other Gate Types COE 202 Digital Logic Design Dr. Aiman El-Maleh
Logic Gates Flip-Flops Registers Adders
Exclusive-OR and Exclusive-NOR Gates
CS105 Introduction to Computer Concepts GATES and CIRCUITS
Chapter3: Gate-Level Minimization Part 2
Chapter 4 Gates and Circuits.
Cosc 2150: Computer Organization Chapter 3: Boolean Algebra and Digital Logic.
Chapter 4 Gates and Circuits.
9/19/06 Hofstra University – Overview of Computer Science, CSC005 1 Chapter 4 Gates and Circuits.
SUPLEMENTARY CHAPTER 1: An Introduction to Digital Logic The Architecture of Computer Hardware and Systems Software: An Information Technology Approach.
Lecture 3. Boolean Algebra, Logic Gates
Part 2: DESIGN CIRCUIT. LOGIC CIRCUIT DESIGN x y z F F = x + y’z x y z F Truth Table Boolean Function.
CS 105 Digital Logic Design
Lecture 3. Boolean Algebra, Logic Gates Prof. Sin-Min Lee Department of Computer Science 2x.
Chapter 4 Gates and Circuits. 4–2 Chapter Goals Identify the basic gates and describe the behavior of each Describe how gates are implemented using transistors.
Chapter 4 Gates and Circuits.
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:
1 CHAPTER 4: PART I ARITHMETIC FOR COMPUTERS. 2 The MIPS ALU We’ll be working with the MIPS instruction set architecture –similar to other architectures.
Lecture 17: Digital Design Today’s topic –Intro to Boolean functions Reminders –HW 4 due Wednesday 10/8/2014 (extended) –HW 5 due Wednesday 10/15/2014.
Digital Electronics. Introduction to Number Systems & Codes Digital & Analog systems, Numerical representation, Digital number systems, Binary to Decimal.
SUPLEMENTARY CHAPTER 1: An Introduction to Digital Logic The Architecture of Computer Hardware and Systems Software: An Information Technology Approach.
CPS120: Introduction to Computer Science
Digital Components and Combinational Circuits Sachin Kharady.
1 The Chinese University of Hong Kong Faculty of Education Diploma in Education (Part-Time) Winter 1997 Educational Communications and Technology Assignment.
1 DIGITAL ELECTRONICS. 2 OVERVIEW –electronic circuits capable of carrying out logical (boolean) and arithmetic operations on information stored as binary.
1 Boolean Algebra & Logic Gates. 2 Objectives Understand the relationship between Boolean logic and digital computer circuits. Learn how to design simple.
Logic Gates Logic gates are electronic digital circuit perform logic functions. Commonly expected logic functions are already having the corresponding.
Logic Gates Shashidhara H S Dept. of ISE MSRIT. Basic Logic Design and Boolean Algebra GATES = basic digital building blocks which correspond to and perform.
Lecture 22: 11/19/2002CS170 Fall CS170 Computer Organization and Architecture I Ayman Abdel-Hamid Department of Computer Science Old Dominion University.
LOGIC GATES AND CIRCUITS Digital systems are said to be constructed by using logic gates. These gates are the AND, OR, NOT, NAND, NOR, EXOR and EXNOR gates.
Gates and Logic Dr John Cowell phones off (please)
1 EG 32 Digital Electronics Thought for the day You learn from your mistakes..... So make as many as you can and you will eventually know everything.
1 EENG 2710 Chapter 2 Algebraic Methods For The Analysis and Synthesis of Logic circuits.
COMPUTER ARCHITECTURE TRUTH TABLES AND LOGIC GATES.
Combinational Circuits
1 Ethics of Computing MONT 113G, Spring 2012 Session 4 Binary Addition.
Digital electronics 4–1 Gates and Circuits SANJAYBHAI RAJGURU COLLEGE OF ENGG.
4–1. BSCS 5 th Semester Introduction Logic diagram: a graphical representation of a circuit –Each type of gate is represented by a specific graphical.
LOGIC CIRCUITLOGIC CIRCUIT. Goal To understand how digital a computer can work, at the lowest level. To understand what is possible and the limitations.
L OGIC G ATES Computer Organization – week 3. W HAT ’ S ALU? 1. ALU stands for: Arithmetic Logic Unit 2. ALU is a digital circuit that performs Arithmetic.
Dr. ClincyLecture Slide 1 CS6020- Chapter 3 (3A and ) Dr. Clincy Professor of CS First Exam - Tuesday, September 6th Coverage: All subjects up to.
DATA REPRESENTATION IN COMPUTER MEMORY.  Describe the coding system:  Sign and magnitude  1’s Complement and 2’s Complement  Binary Coded Decimal.
Week 1: Introduction and Logic gates IT3002 – Computer Architecture
Boolean Algebra & Logic Gates
Dr.Ahmed Bayoumi Dr.Shady Elmashad
Boolean Algebra & De Morgan's Theorems
Digital Components and Combinational Circuits
Dr. Clincy Professor of CS
Chapter 4 Gates and Circuits.
CS105 Introduction to Computer Concepts GATES and CIRCUITS
Boolean Algebra.
Week 7: Gates and Circuits: PART II
CS Chapter 3 (3A and ) Part 3 of 8
Digital Logic.
Logic Gates.
Logic Gates.
CS Chapter 3 (3A and ) – Part 2 of 5
Digital Logic.
XOR, XNOR, and Binary Adders
XOR Function Logic Symbol  Description  Truth Table 
Digital Logic Design Basics Combinational Circuits Sequential Circuits.
Presentation transcript:

Logic Circuits Basic Building Blocks Dr John Cowell phones off (please) CSCI1412 Lecture 10 Logic Circuits Basic Building Blocks Dr John Cowell

Overview Logic gates & Truth tables Gate Operations Logic functions Digital Logic Combinational Circuits Logic gates & Truth tables Gate Operations Logic functions Adder circuits © De Montfort University, 2005 CSCI1412-LG-1 2

Digital Logic

Digital Logic Circuits The function of a Digital Logic Circuit determines the values of the outputs for specified value of inputs The function is normally implemented using electronic circuitry Inputs and outputs are each in either of two states: TRUE HIGH ON 1 5V Or FALSE LOW OFF 0 0V Digital Logic Circuit Outputs Inputs

Digital Logic … The Digital Logic Circuit may be as simple as a single logic gate or as complex as a computer’s processor Binary logic deals with binary variables (0 or 1) and with operations that assume a logical meaning It is used to describe, in algebraic or tabular form, the manipulation and processing of binary information © De Montfort University, 2007 CSCI1412-LG-1 5

Boolean Variables (algebra) Boolean algebra differs in a major way from ordinary algebra in that boolean constants and variables are allowed to have only two possible values, 0 or 1 Boolean 0 and 1 are represented by the state of a voltage variable, or what is called the logic level In boolean algebra, there are three basic logic operations: OR AND and NOT These are implemented by logic gates constructed from diodes, transistors, and resistors connected in such a way that the circuit output is the result of a basic logic operation (OR, AND, NOT) performed upon the inputs © De Montfort University, 2007 CSCI1412-LG-1 6

Combinational Logic Circuits There are Combinational logic circuits and Sequential logic circuits, but most realistic logic circuits are a mixture of both Combinational logic circuits Output values depend only on the current values of the inputs there is no feedback from previous outputs (more on this later) They are called combinational as they combine the operations of more than one logic gate © De Montfort University, 2007 CSCI1412-LG-1 7

Logic Gates and Truth Tables

Logic Gates The manipulation of binary information is done by logic circuits galled gates Integrated circuits (ICs) contain a number of logic gates, ranging from three or four in simple chips to many thousands in more complex parts Each gate is represented with a distinct graphic symbol and its operation is described by means of an algebraic expression The input-output relationship of the binary variables for each gate is represented in tabular form by a truth table © De Montfort University, 2007 CSCI1412-LG-1 9

Truth Table A truth table is a means for describing how a logic circuit's output depends on the logic levels present at the circuit's inputs In the following two-input logic circuit, the table lists all possible combinations of logic levels present at inputs A and B along with the corresponding output level X When either input A OR B is 1, the output X is 1. Therefore the "?" in the box is an OR gate (OR gate is explained later) © De Montfort University, 2007 CSCI1412-LG-1 10

Gate Operations

AND Operation truth table The expression X = A * B reads as "X equals A AND B“ The multiplication sign stands for the AND operation same for ordinary multiplication of 1s and 0s The AND operation produces a result of 1 occurs only for the single case when all of the input variables are 1 The output is 0 for any case where one or more inputs are 0 © De Montfort University, 2007 CSCI1412-LG-1 12

OR Operation The expression X = A + B reads as "X equals A OR B“ truth table The expression X = A + B reads as "X equals A OR B“ The + sign stands for the OR operation, not for ordinary addition The OR operation produces a result of 1 when any of the input variable is 1 The OR operation produces a result of 0 only when all the input variables are 0 © De Montfort University, 2007 CSCI1412-LG-1 13

NOT Operation truth table The NOT operation is unlike the OR and AND operations in that it can be performed on a single input variable © De Montfort University, 2007 CSCI1412-LG-1 14

NOT….. For example, if the variable A is subjected to the NOT operation, the result x can be expressed as x = A' where the prime (') represents the NOT operation This expression is read as: x equals NOT A x equals the inverse of A x equals the complement of A Each of these is in common usage and all indicate that the logic value of x = A' is opposite to the logic value of A © De Montfort University, 2007 CSCI1412-LG-1 15

XOR Operation Exclusive OR Returns: True only if either input is True Means: this or that, but not both Often used for: cryptography generating parity bits for error checking and fault tolerance ie network messages

De Morgans Theorem

DeMorgan's Theorem (x+y)' = x' * y' (x*y)' = x' + y' DeMorgan's theorems are extremely useful in simplifying expressions in which a product or sum of variables is inverted The two theorems are: (x+y)' = x' * y' (x*y)' = x' + y' © De Montfort University, 2007 CSCI1412-LG-1 18

Universality of NAND Gate It is possible to implement any logic expression using only NAND gates ie no other type of gate is required This is because NAND gates, in the proper combination, can be used to perform each of the Boolean operations OR, AND, and INVERT © De Montfort University, 2007 CSCI1412-LG-1 19

NAND Gate Examples © De Montfort University, 2007 CSCI1412-LG-1 20

NOT Gate fron NAND Gate A A*A (A*A)' 1

AND Gate from NAND Gates B C=(A*B)' X=(C*C)' 1

OR Gate From NAND Gates A B A' B' X=(A' * B')' 1

Logic Functions

Logic Functions A = 1010 0101 B = 0000 1111 A*B = 0000 0101 Whilst the microcomputer can perform the normal arithmetical operations on binary numbers, it can also perform logical operations: AND For clearing bits OR For setting bits A = 1010 0101 B = 0000 1111 A*B = 0000 0101 A = 1010 0101 B = 0000 1111 A+B = 1010 1111 © De Montfort University, 2007 CSCI1412-LG-1 25

NOT & XOR functions A = 1010 0101 NOT A = 0101 1010 A = 1010 0101 For inverting bits XOR For checking bits A = 1010 0101 NOT A = 0101 1010 A = 1010 0101 B = 0000 1111 A xor B = 1010 1010 © De Montfort University, 2007 CSCI1412-LG-1 26

Sequential Logic Circuits Sequential logic circuits differ from combinatorial logic circuits in two main respects The output of the system depends not only on the present external input(s) but also on the previous inputs The same external input(s) can give a different output response An important feature of sequential logical circuits, not present in combinational logic circuits, is the presence of feedback where the output from one or more logic gates is fed back into the input(s) of logic gates further back in the circuit © De Montfort University, 2007 CSCI1412-LG-1 27

Adder Circuits

Addition, using logic gates Consider: The circuit is performing binary addition of B to A (recalling that in binary 1+1 = 0 carry 1) Such a circuit is called a half-adder 1   CARRY     SUM     B     A   © De Montfort University, 2007 CSCI1412-LG-1 29

Full-Adder A full adder is made by combining two half-adders and an additional OR-gate A full adder adds two binary numbers AND the carry bit. By extending the full adder long bibary n umbers can be added. © De Montfort University, 2007 CSCI1412-LG-1 30

Truth Table for a Full Adder Input Carry Output Carry Sum 1

Find out more! What are ? READ: Sequential logic circuits Programmable logic READ: http://computer.howstuffworks.com/boolean.htm © De Montfort University, 2007 CSCI1412-LG-1 32

Lecture Summary Logic gates & Truth tables Gate Operations Digital Logic Combinational Circuits Logic gates & Truth tables Gate Operations Logic functions Adder circuits © De Montfort University, 2007 CSCI1412-LG-1 33