0% found this document useful (0 votes)
10 views7 pages

Cpre281 Labttl2

Uploaded by

ratananandkar1
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views7 pages

Cpre281 Labttl2

Uploaded by

ratananandkar1
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

Cpr E 281 LAB Implementing a 4-bit Add/Subtract

ELECTRICAL AND COMPUTER


ENGINEERING Unit with Physical Gates
IOWA STATE UNIVERSITY

1.0 Objective

In the last TTL lab, you used CMOS integrated circuits with AND, OR, and NOT gates to
build a simple logic circuit. In this lab, you will be using a CMOS chip that contains 4 XOR
gates and another CMOS chip that is a 4-bit adder to create a 4-bit add/subtract unit.

The inputs to your circuit will be two four-bit binary numbers X=X3X2X1X0 and Y=Y3Y2Y1Y0.
The Add/Sub input causes the XOR gates to invert the Y inputs and sets the carry c0 high,
effectively adding X to negative Y (following the rule for 2s-complement negation: “invert
every bit and then add one”).

1
2.0 Pin Diagrams

2.1 4-bit Adder (74283)

Download the datasheet for the 4-bit adder (i.e., CD54HC283) from this link:
https://www.ti.com/lit/ds/symlink/cd54hc283.pdf

The pinout for the adder is shown on page 3 of that PDF file and also replicated below
(see the left image). This datasheet uses A[0:3] and B[0:3] to represent the two 4-bit
inputs. It also uses Cin to represent c0 and Cout to represent c4. The output sum pins are
labeled with S[0:3]. Pin 16 is the positive power supply (Vcc) and pin 8 is ground.

Notice that the labels for the pins are different from the labels that we want to use for
our circuit. The data sheet uses A and B, but we need x and y. While this is just a relabeling
issue, it could slow you down and lead to wiring errors if you are not careful. Therefore,
we will use the right image, which renames the pin labels to what we need and switches
from capital to small letters.

2
2.2 XOR gate (7486)

Download the datasheet for the XOR chip (i.e., CD74HC86) from this link:
https://www.ti.com/lit/ds/symlink/cd74hc86.pdf

The first page of the datasheet shows the pinout for this chip. However, that diagram
starts the counting at 1 instead of 0. This could be very confusing for beginners and could
lead to a lot of wiring errors, so we will not use it directly. Instead, we will use the diagram
on the right, which uses 0-based indexing for the inputs and outputs. It also switches to
lower case letters to be consistent with the rest of the circuit.

2.3 Overall Wiring Diagram

3
3.0 Assembly
1) Start with an empty breadboard. The power supply should be on the right and the
numbers on the breadboard should be in decreasing order (60, 55, 50, etc.). Check that
the + and – rails of the breadboard match the + and – of the power supply (black board).
Verify that the two yellow jumpers on the power supply are set to +5V (see the image
below). Do not plug in the power cable yet.

2) Insert the DIP switches, XOR IC, and the 4-bit adder. Ensure the correct IC is in each
slot, each IC can be identified by reading the markings on the top and ignoring the letters.
Make sure the semi-circular cutouts on the ICs all point to the left.

3) Connect the power and ground pins of each of the ICs and the DIP switches. Note
that we are using switches 2-5, nothing should be connected to switch 1.

4
4) Connect the gate inputs and outputs together following the overall circuit diagram.

5
5) Connect the switches to ground using resistors and add the resistors for the LEDs.
Because of the complexity of the circuit, we have trimmed the legs of some resistors in
these pictures. Yours will be longer. Ensure that the long end of each LED is connected
to a resistor and the short end to the – rail.

6) Verify that the connections in your circuit match the wiring diagram shown here:

7) Ensure that the legs of the resistors are not touching. Ask a TA to verify your circuit,
then unplug your DES-115 board and connect its power cable to your breadboard. If it
does not turn on, press the white power button on the power supply board. Flip the DIP
switches and verify that the LED output matches the expected result.

6
4.0 Verification
With the circuit complete, you can now plug in the breadboard and test your new adder.
Use switches 2-5 on X (left side) and Y (right side) to ensure the adder works correctly.
Once you are satisfied that the adder works, flip the add/sub switch to change the adder
into a subtractor and verify that the XOR gates and carry 0 work correctly.

Example: 3 + 2 = 5

Example: 3 – 2 = 1

5.0 What to submit?

Take at least two pictures of your circuit performing one addition and one subtraction
(these should be similar to the ones above, but you can pick different numbers). Put these
pictures into a Word document. At the top write your name and the name of your project
partner. Convert the Word file to PDF and then upload the PDF on Canvas under “Lab6”.
The pictures must clearly show the state of the switches and the LED output. Each student
in the team must upload a file.

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy