CSC258: Computer Organization. Combinational Logic

Similar documents
We are here. Assembly Language. Processors Arithmetic Logic Units. Finite State Machines. Circuits Gates. Transistors

Experiment # 12. Traffic Light Controller

Logic Design ( Part 3) Sequential Logic- Finite State Machines (Chapter 3)

Lecture 11: Synchronous Sequential Logic

Laboratory Exercise 7

Universidad Carlos III de Madrid Digital Electronics Exercises

Analysis of Clocked Sequential Circuits

ELCT201: DIGITAL LOGIC DESIGN

1. a) For the circuit shown in figure 1.1, draw a truth table showing the output Q for all combinations of inputs A, B and C. [4] Figure 1.

California State University, Bakersfield Computer & Electrical Engineering & Computer Science ECE 3220: Digital Design with VHDL Laboratory 7

Chapter 5 Synchronous Sequential Logic

2 Sequential Circuits

FPGA Implementation of Sequential Logic

Course Administration

Read-only memory (ROM) Digital logic: ALUs Sequential logic circuits. Don't cares. Bus

Problems with D-Latch

Objectives. Combinational logics Sequential logics Finite state machine Arithmetic circuits Datapath

Administrative issues. Sequential logic

Chapter 3. Boolean Algebra and Digital Logic

L5 Sequential Circuit Design

Step 1 - shaft decoder to generate clockwise/anticlockwise signals

Advanced Devices. Registers Counters Multiplexers Decoders Adders. CSC258 Lecture Slides Steve Engels, 2006 Slide 1 of 20

EECS150 - Digital Design Lecture 19 - Finite State Machines Revisited

Logic Design II (17.342) Spring Lecture Outline

First Name Last Name November 10, 2009 CS-343 Exam 2

CS61C : Machine Structures

University of California at Berkeley College of Engineering Department of Electrical Engineering and Computer Science

Spring 2017 EE 3613: Computer Organization Chapter 5: The Processor: Datapath & Control - 1

Ryerson University Department of Electrical and Computer Engineering EES508 Digital Systems

Faculty of Electrical & Electronics Engineering BEE3233 Electronics System Design. Laboratory 3: Finite State Machine (FSM)

Previous Lecture Sequential Circuits. Slide Summary of contents covered in this lecture. (Refer Slide Time: 01:55)

ECSE-323 Digital System Design. Datapath/Controller Lecture #1

Ryerson University Department of Electrical and Computer Engineering COE/BME 328 Digital Systems

Laboratory Exercise 7

Advanced Digital Logic Design EECS 303

Topic D-type Flip-flops. Draw a timing diagram to illustrate the significance of edge

UC Berkeley CS61C : Machine Structures

CHAPTER 4: Logic Circuits

Chapter 5 Sequential Systems. Introduction

Digital Fundamentals: A Systems Approach

TMEL53, DIGITALTEKNIK. INTRODUCTION TO SYNCHRONOUS CIRCUITS, FLIP-FLOPS and COUNTERS

Figure 30.1a Timing diagram of the divide by 60 minutes/seconds counter

1.b. Realize a 5-input NOR function using 2-input NOR gates only.

ENGG 1203 Tutorial. D Flip Flop. D Flip Flop. Q changes when CLK is in Rising edge PGT NGT

CS61C : Machine Structures

Digital Logic Design ENEE x. Lecture 24

CS 110 Computer Architecture. Finite State Machines, Functional Units. Instructor: Sören Schwertfeger.

CPSC 121: Models of Computation Lab #5: Flip-Flops and Frequency Division

MASSACHUSETTS INSTITUTE OF TECHNOLOGY Department of Electrical Engineering and Computer Sciences

University of California at Berkeley College of Engineering Department of Electrical Engineering and Computer Science. EECS 150 Spring 2000

Sequential Circuits. Output depends only and immediately on the inputs Have no memory (dependence on past values of the inputs)

CS3350B Computer Architecture Winter 2015

Switching Circuits & Logic Design, Fall Final Examination (1/13/2012, 3:30pm~5:20pm)

Last time, we saw how latches can be used as memory in a circuit

Lab Assignment 5 I. THE 4-BIT CPU AND CONTROL

Unit 12 Design Solutions Solutions to Unit 12 Design and Simulation Problems

In this lecture we will work through a design example from problem statement to digital circuits.

Exercise 2: D-Type Flip-Flop

EECS150 - Digital Design Lecture 15 Finite State Machines. Announcements

CHAPTER 4: Logic Circuits

Digital Logic & Computer Design CS Professor Dan Moldovan Spring Chapter 3 :: Sequential Logic Design

ECE 301 Digital Electronics

Chapter 5 Sequential Circuits

Practice Homework Problems for Module 3

CS61C : Machine Structures

ASYNCHRONOUS COUNTER CIRCUITS

ECE 331 Digital System Design

CPSC 121: Models of Computation Lab #5: Flip-Flops and Frequency Division

ECE 301 Digital Electronics

More Digital Circuits

ELCT 501: Digital System Design

Final Exam review: chapter 4 and 5. Supplement 3 and 4

Lab #10: Building Output Ports with the 6811

Part II. Chapter2: Synchronous Sequential Logic

Microprocessor Design

Chapter Contents. Appendix A: Digital Logic. Some Definitions

Digital Design Datapath Components: Parallel Load Register

ELE2120 Digital Circuits and Systems. Tutorial Note 8

To design a sequential logic circuit using D-Flip-flop. To implement the designed circuit.

problem maximum score 1 28pts 2 10pts 3 10pts 4 15pts 5 14pts 6 12pts 7 11pts total 100pts

Latches, Flip-Flops, and Registers. Dr. Ouiem Bchir

CSE115: Digital Design Lecture 23: Latches & Flip-Flops

Design of a Binary Number Lock (using schematic entry method) 1. Synopsis: 2. Description of the Circuit:

EE 109 Homework 6 State Machine Design Name: Score:

CS8803: Advanced Digital Design for Embedded Hardware

ECE 341. Lecture # 2

CHAPTER 6 COUNTERS & REGISTERS

CSCB58 - Lab 4. Prelab /3 Part I (in-lab) /1 Part II (in-lab) /1 Part III (in-lab) /2 TOTAL /8

CPS311 Lecture: Sequential Circuits

Lecture 8: Sequential Logic

Informatique Fondamentale IMA S8

Computer Systems Architecture

Section 6.8 Synthesis of Sequential Logic Page 1 of 8

Logic and Computer Design Fundamentals. Chapter 7. Registers and Counters

Timing Pulses. Important element of laboratory electronics. Pulses can control logical sequences with precise timing.

Digital Circuit Engineering

Chapter 5: Synchronous Sequential Logic

cs281: Introduction to Computer Systems Lab07 - Sequential Circuits II: Ant Brain

Principles of Computer Architecture. Appendix A: Digital Logic

YEDITEPE UNIVERSITY DEPARTMENT OF COMPUTER ENGINEERING. EXPERIMENT VIII: FLIP-FLOPS, COUNTERS 2014 Fall

Transcription:

CSC258: Computer Organization Combinational Logic 1

Anonymous: Quizzes and Fairness... A lot of students in earlier sections share the quiz question with students who have the tutorial later in the evening... I ve had questions and concerns raised in office hours, too, about the overall fairness of marking. Some TAs are more lenient than others, some quizzes are easier than others, 2

Anonymous: Quizzes and Fairness Because of the variables involved (time, TA, quiz difficulty), fairness across sections is difficult. You can help: please don t explicitly undermine the process. The quizzes come from the recommended exercises. Don t provide additional guidance. I will be monitoring performance across sections and making adjustments as necessary. 3

Anonymous: Lab Length Labs are a bit too long Labs will get longer for the next couple of weeks, and then they ll decline in length at the end of the term. For the next couple of weeks, you may wish to do some work before your lab. I will try to get labs posted by Saturday each week.

Finite State Machines 5

What is State? State is the current value of the system For example, a counter has state 6

Representing State One choice: State tables They are truth tables! One input is the current state Another is the new state State(t) X State (t+1) Q(t) 0 0 0 0 0 1 1 0 1 0 0 0 1 1 1 1 7

Representing State State tables can get very complex Systems may have many, many possible states Here s the state table for a 3-bit counter State(t) State(t+1) 000 001 001 010 010 011 011 100 100 101 101 110 110 111 111 000 8

Finite State Machines Instead of using tables, we can use graphs Humans are much better at processing data visually, in graph form We know a -huge- amount about graphs Our graphs are called Finite State Machines Finite: Limited number of states Machine: Theoretical model of a computer Heavily used in theoretical computer science 9

FSM Components A set of states and an initial state A set of legal inputs and a mapping of transitions between states Given input x in state A, transition to B A set of actions (outputs) associated with each transition (Mealy machine) or state (Moore machine) 10

Designing FSMs Circuits with state will be designed in two blocks State block: stores the current machine state Combinational block: given inputs and the current state, computes the new state and outputs Processors are FSMs: an ALU (combinational) + registers (state) 11

12

Implementing a FSM 1. Draw the state diagram (or table), numbering each state 2. Select the number of flip-flops required to store the state How many bits are required to describe the state? 3. Build a truth table for each output, including the new state Building multiple truth tables can help decrease complexity -- it s like building modules in software Don t care conditions will help a huge amount 4. Implement the combinational logic from the truth tables (Alternately, design from high-level components.) 13

The GoldenEye Pen From: http://www.mi6-hq.com/sections/q-branch/pengrenade.php3?t=mi6&s=ge 14

Your Mission... whether or not you choose to accept it: Design the control circuitry for the pen grenade. Your circuit should take, as input, a clock signal and a click signal. The click signal is True iff the button on the pen has been depressed during the clock cycle. The clock is fast enough that a human can only click the pen once in a cycle. Your circuit should output a signal armed that is true iff the grenade is in countdown mode (to explode after 4 seconds). Don t worry about the BOOM! state. That s a different state machine. Begin by drawing the state diagram that describes the desired behaviour. 15

A Variation... whether or not you choose to accept it: Design the control circuitry for the pen grenade. Your circuit should take, as input, a clock signal and a click signal. The click signal is True iff the button on the pen has been depressed during the clock cycle. The clock is fast enough that a human can only click the pen once in a cycle. There are 100 clock signals per second. Your circuit should output a signal boom that is true iff the grenade should explode. What part of your circuit is affected by this modification? 16

Tips Make assumptions to reduce the truth table Assume only one input will arrive in a cycle. Ignore an output on the incoming arc (or set up your machine as a Moore machine). Fix your assumptions in the hardware! Example: Add logic to change the state to the trap state if more than one input arrives at a time. Implement extra functionality, like reset, using appropriate hardware. 17