LABORATORY # 6 * L A B M A N U A L. Datapath Components - Adders

Similar documents
ELEC 204 Digital System Design LABORATORY MANUAL

University of Hawaii EE 361L. Getting Started with Spartan 3E Digilent Basys2 Board. Lab 4.1

EE 1315 DIGITAL LOGIC LAB EE Dept, UMD

Circuit design with configurable devices (FPGA)

CCE 3202 Advanced Digital System Design

Introduction to Schematic Entry using Xilinx ISE and Digital Logic Simulation using ModelSim MXE

Experiment 8 Introduction to VHDL

Lab 6 : Introduction to Verilog

EXPERIMENT #8: BINARY ARITHMETIC OPERATIONS

Lecture 3: Binary Subtraction, Switching Algebra, Gates, and Algebraic Expressions

Tutorial on FPGA Design Flow based on Xilinx ISE Webpack and ModelSim. ver. 1.5

Verilog Design Entry, Synthesis, and Behavioral Simulation

CARLETON UNIVERSITY. Laboratory 2.0

Lab Manual for COE 203: Digital Design Lab

Digital Logic Design Lab

Physics 364, Fall 2012, reading due your answers to before the end of Wednesday s lab.

ECE 152A LABORATORY 2

To design a 4-bit ALU To experimentally check the operation of the ALU

EE209 Lab Change We Can Believe In

CS/COE 0447 Example Problems for Exam 2 Spring 2011

Lab 6 Debugging. Objective. Introduction. Prelab

Don t expect to be able to write and debug your code during the lab session.

ESE 150 Lab 07: Digital Logic

Setup/Hold. Set Up time (t su ):

QUESTION BANK FOR TEST

COMPUTER ENGINEERING PROGRAM

Student Number: UTORid: Question 0. [1 mark] Read and follow all instructions on this page, and fill in all fields.

DIGITAL LOGIC WITH VHDL (Fall 2013) Unit 1

ECE 4305 Computer Architecture Lab #1

ECE2029: Introduction to Digital Circuit Design. Lab 2 Implementing Combinational Functional Blocks

Lab 1: Introduction to Verilog HDL and the Xilinx ISE

ECE 491 Laboratory 1 Introducing FPGA Design with Verilog September 6, 2004

Exp#8: Designing a Programmable Sequence Detector

Introduction to Nexys 2 board - Detour Signal Lab

Tutorial on FPGA Design Flow based on Xilinx ISE WebPack and ModelSim. ver. 2.0

Topics. Midterm Finish Chapter 7

Programming Xilinx SPARTAN 3 Board (Simulation through Implementation)

COMPUTER ENGINEERING PROGRAM

1. Prove that if you have tri-state buffers and inverters, you can build any combinational logic circuit. [4]

Tutorial on FPGA Design Flow based on Xilinx ISE Webpack and ModelSim. ver. 1.3

Introduction to Programmable Logic Devices (Class 7.2 2/28/2013)

Physics 364, Fall 2014, reading due your answers to by 11pm on Sunday

5 Arithmetic Logic Unit

Verilog Lab. Two s Complement Add/Sub Unit. TA: Xin-Yu Shi

Verilog Lab. 2 s Complement Add/Sub Unit

Revision: January 28, Henley Court Pullman, WA (509) Voice and Fax

ENEE245 Digital Circuits and Systems Lab Manual

Microcomputers. Outline. Number Systems and Digital Logic Review

LAB #3: ADDERS and COMPARATORS using 3 types of Verilog Modeling

Revision: February 27, E Main Suite D Pullman, WA (509) Voice and Fax

Lab 3 Sequential Logic for Synthesis. FPGA Design Flow.

Basic Concepts. Task One: The Basic Latch. Laboratory Nine Latches, RAM & Android Architecture

Xilinx Tutorial Basic Walk-through

A B A+B

problem maximum score 1 10pts 2 8pts 3 10pts 4 12pts 5 7pts 6 7pts 7 7pts 8 17pts 9 22pts total 100pts

CSE140L: Components and Design Techniques for Digital Systems Lab. Verilog HDL. Instructor: Mohsen Imani UC San Diego. Source: Eric Crabill, Xilinx

structure syntax different levels of abstraction

Here is a list of lecture objectives. They are provided for you to reflect on what you are supposed to learn, rather than an introduction to this

Lecture 3: Modeling in VHDL. EE 3610 Digital Systems

ENEE245 Digital Circuits and Systems Lab Manual

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

Binary Adders: Half Adders and Full Adders

TUTORIAL On USING XILINX ISE FOUNDATION DESIGN TOOLS: Mixing VHDL and Schematics

Tutorial on FPGA Design Flow based on Xilinx ISE Webpack andisim. ver. 1.0

FPGA for Complex System Implementation. National Chiao Tung University Chun-Jen Tsai 04/14/2011

Addition and multiplication

CSE303 Logic Design II Laboratory 01

EE292: Fundamentals of ECE

CS61C : Machine Structures

ECE 545 Lecture 12. FPGA Resources. George Mason University

Computer Architecture Set Four. Arithmetic

University of California at Berkeley College of Engineering Department of Electrical Engineering and Computer Sciences. Spring 2010 May 10, 2010

Graduate Institute of Electronics Engineering, NTU. FPGA Lab. Speaker : 鍾明翰 (CMH) Advisor: Prof. An-Yeu Wu Date: 2010/12/14 ACCESS IC LAB

Lab 3 Finite State Machines Movie Ticket Dispensing Machine

TEACHING COMPUTER ARCHITECTURE THROUGH DESIGN PRACTICE. Guoping Wang 1. INTRODUCTION

Xilinx ChipScope ICON/VIO/ILA Tutorial

Lecture 5: Aldec Active-HDL Simulator

Chapter 3 Arithmetic for Computers

Experiment 9: Binary Arithmetic Circuits. In-Lab Procedure and Report (30 points)

ECE 645: Lecture 1. Basic Adders and Counters. Implementation of Adders in FPGAs

Xilinx ASMBL Architecture

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

1 Discussion. 2 Pre-Lab

Experiment # 5 Debugging via Simulation using epd

CE1921: COMPUTER ARCHITECTURE SINGLE CYCLE PROCESSOR DESIGN WEEK 2

CSE 141L Computer Architecture Lab Fall Lecture 3

CHAPTER 9 MULTIPLEXERS, DECODERS, AND PROGRAMMABLE LOGIC DEVICES

SYNERGY INSTITUTE OF ENGINEERING & TECHNOLOGY,DHENKANAL LECTURE NOTES ON DIGITAL ELECTRONICS CIRCUIT(SUBJECT CODE:PCEC4202)

PINE TRAINING ACADEMY

Experiment 7 Arithmetic Circuits Design and Implementation

Midterm Exam ECE 448 Spring 2019 Wednesday, March 6 15 points

Laboratory Memory Components

A3 A2 A1 A0 Sum4 Sum3 Sum2 Sum1 Sum

Programmable Logic Design Techniques I

Lecture #1: Introduction

One and a half hours. Section A is COMPULSORY UNIVERSITY OF MANCHESTER SCHOOL OF COMPUTER SCIENCE

Tutorial on FPGA Design Flow based on Aldec Active HDL. Ver 1.5

EE 367 Logic Design Lab #1 Introduction to Xilinx ISE and the ML40X Eval Board Date: 1/21/09 Due: 1/28/09

Experiment 3. Digital Circuit Prototyping Using FPGAs

Tutorial - Using Xilinx System Generator 14.6 for Co-Simulation on Digilent NEXYS3 (Spartan-6) Board

Transcription:

Department of Electrical Engineering University of California Riverside Laboratory #6 EE 120 A LABORATORY # 6 * L A B M A N U A L Datapath Components - Adders * EE and CE students must attempt also to implement the assignment described in Lab 6 Optional Manual. It is, however, NOT THE REQUIREMENT for this laboratory and WILL NOT be graded if submitted. It provides information on usage of LED displays of Basys boards.

2 Objectives 1. Design of adders, synthesis and implementation; 2. Design of special purpose registers Equipment PC or compatible Digilent s Basys Spartan-3E FPGA Evaluation Board Software Xilinx ISE Design Software Suite 10.1 ModelSim XE III modeling software Digilent s Adept ExPort Software Parts N/A

3 Background - Adders Design In this FPGA application development assignment, we will implement a calculator that does just one thing adds two 4-bit numbers. 4-bit carry-ripple adder An N-bit adder adds two N-bit numbers plus a carry-in bit, resulting in an N-bit sum and a carry-out bit. A block diagram of a 4- bit adder appears in Figure L6-1. Although we could design a 4-bit adder s circuit using the combinational logic design process, the resulting circuit would be rather large. Instead, we can use a more clever design approach, which mimics how numbers are added by hand. Addition by hand is done one column at a co s3 s2 s1 s0 time. The rightmost column would add b0+a0+ci, to generate the sum bit s0 and a carry bit for the next column, which we ll call ci. We can thus first design a component, called a full-adder, which adds three input bits a, b, and c, and generates sum and carry output bits s and co. Using the combinational logic design process, we find that s = a xor b xor c, and co = bc + ac + ab. Design a full-adder circuit implementing those equations. Now connect four such full-adders to create a 4-bit adder, as shown in Figure L6-1. The figure does not show all the connections of the inputs and outputs to the full-adders, but you should be able to determine those connections easily. Figure L6-1. Block diagram of a 4-bit adder. Figure L6-2. General structure of a 4-bit adder built from 4 full-adders. b0 a0 ci Simulate the system and observe the outputs. Try adding some small numbers, like co s0 0000+0000+0 (which should result in 0 0000) and 0001+0001+0 (which should equal 0 0010). Also try adding some larger numbers, like 1111+1111+0 (which should equal 1 1110), and 1111+1111+1 (which should equal 1 1111). Is it possible for two 4-bit numbers and a carry-in to result in a number too big to represent using 4 sum bits and a carry-out bit? Note that the above adder assumes the inputs are unsigned numbers (i.e., the inputs are not in two s complement form). b3 b2 b1 b0 a3 a2 a1 a0 Circuit to be designed ci

4 Specification DIP switches a3..a0 b3..b0 4-bit adder ci 0 co s7..s0 clk e ld 5-bit register CALC LEDs Figure L6-3. Adder Structure and Basys Board implementation hint Implement a 4-bit adder system on the Basys development board. Use two 4- position DIP switches for the two 4-bit inputs, a single switch for the carry-in input, and five LEDs for the give outputs. Then try different combinations of the inputs and observe the outputs. Use one of the buttons to load the results to the LEDs. See Figure L6-3 for details. Implementation Utilities and Hints The following CLK configuration must be used in the constraints file: # clock pin for Basys Board NET "CLK" LOC = "p54"; # Bank = 2, Signal name = CLK1 Demonstration Demostrate that the application performs according to specs.

5 Procedures 1. Xilinx ISE Design and Synthesis environment; 2. Creation of Configuration files; 3. Usage of Adept ExPort download software; Presentation and Report Must be presented according to the general EE120A lab guidelines posted in ilearn. Prelab 1. Review Lecture 14; 2. Try to answer all the questions, prepare logic truth tables, do all necessary computations