User Tools


Discrete Gates

In this lab you will apply your understanding of Boolean algebra and digital gates to implement two logic functions using discrete logic gates. You will interface your logic gates to the NEXYS 4 board and test your logic function with switches and LEDs on the board.

Learning Outcomes

  • Apply logic minimization using Boolean algebra on a simple logic function.
  • Build a circuit using 7400 series digital logic gates and interface it with the NEXYS 4 board.

Preliminary

You will create two digital circuits that implement two logic functions. These two logic functions are defined below.

A laptop is being produced that requires a circuit which will activate an alarm if the laptop's battery is low and turn on the internal fan if the laptop's temperature is too high. The circuit also depends on whether the laptop's power cord is plugged in or not. The inputs and outputs of this circuit are as follows:

Inputs
CCord Plugged In
BLow Battery
THigh Temperature
Outputs
AAlarm
FFan

The circuit operation of the alarm and the fan is defined in the following truth table:

InputsOutputs
CBTFA
00000
00110
01001
01101
10000
10110
11000
11110
  1. Write out the Boolean equations for the outputs A (Alarm) and F (Fan) in SOP (sum of products) form. 1)
  2. Use Boolean algebra to minimize the Boolean equations from step 1. In particular, come up with a logic equation that reduces the number of logic operations (AND/OR/INVERT) and the size of the logic operations. Make sure to show your work. 2)

Exercises

Exercise #1 - Creating Digital Circuits with 7400 Series Discrete Gates

In this first exercise, you will design the Alarm Fan circuit using 7400 series gates. To begin this exercise, carefully read the 7400 Series Logic Devices tutorial.

Create a schematic drawing of your circuit for the fan alarm using 7400 ICs. You can create your schematic circuit diagram in one of two ways:

  1. You can draw your circuit diagram by hand.
  2. You can create a diagram electronically. You may want to use the following power point slide with the 7400 devices and use power point to wire up the circuit according to your design.

Your diagram must include each of the following:

  • Draw each 7400 series device that you need in order to implement both equations (just as big rectangles). Label the part number inside the this and label each pin of the chip.
  • Draw connections for VCC and GND for each of the devices in the circuit.
  • Draw wires for the inputs to your logic equations and clearly label them.
  • Draw wires for the two primary outputs (F and A) and label them.
  • Draw wires between the various gates of the 7400 series devices to implement the correct logic equation.

The example below demonstrates a circuit diagram to give you an idea on what your circuit diagram might look like. The example below demonstrates a circuit diagram for a 7400 series schematic circuit that implements the function: Z = AB' + ABC'. Note that you do not need to draw the internal gates.

Note: This is just an example diagram and you should not build your circuit according to this diagram.

Exercise 1 Pass-off: Show a TA your circuit diagram and explain how you know it is correct.

Exercise #2 - Constructing Your Circuit on the Breadboard

The next exercise in this laboratory is to build your logic circuit onto a breadboard. This involves obtaining the 7400 chips from the TA, placing them on your breadboard, and then wiring up the chips according to the drawing you created in the previous exercise.

  1. Build your design based on your drawing in the previous exercise on the breadboard using the provided wires and IC chips.
  2. Make sure the Nexys 4 is turned off.
  3. Connect the breadboard to the Nexys 4 as described in the Attaching the NEXYS 4 section of the breadboard tutorial.
  4. Using the table below, connect the switch signals (SW0-SW2) from the NEXYS 4 board to the inputs of your circuit and the outputs of your circuit to the LEDS of the NEXYS 4.
Name I/O Pin Nexys 4 Assignment
Inputs
C J1-4 SW2
B J1-3 SW1
T J1-2 SW0
Outputs
A J2-1 LED 0
F J2-2 LED 1

How many wires did you need to build your circuit? Include all the wires you used in your count, including wires for powering the circuit, wires for the inputs and outputs, and wires between the 7400 series chips.

Exercise 2 Pass-off: Show a TA your circuit and have them check that it will not damage the board. Do not turn on the NEXYS 4 board until you have reviewed your circuit with a TA. It is relatively easy to damage the logic chips on the FPGA board if you hook up your logic circuit incorrectly.

Exercise #3 - Powering and testing your circuit with the NEXYS 4

  1. Make sure the jumpers on the NEXYS4 board are setup properly by following the Setting Jumpers on the NEXYS 4 Board tutorial.
  2. Download the alarm_fan.bit configuration bit file.
  3. Turn the Nexys 4 board on (make sure there is no smoke or any other evidence of damage from the chips or wires before proceeding).
  4. Configure the FPGA board with the downloaded bit file using Vivado.

At this point, the FPGA board should provide the button inputs to your circuit and the LEDs will display the logic produced by your circuit. Test all input combinations to make sure your two functions (F and A) are producing the correct results.

If their operation does not match the truth table given at the beginning of the lab, your circuit has a mistake! Turn off the NEXYS 4 and make changes as necessary. Have a TA check your circuit each time before you turn the NEXYS 4 back on.

Final Pass Off

The following are required for pass off:

  • Completed pass offs for Exercise 1 and 2.
  • Your functioning circuit built on the breadboard.

After you complete pass off, return your chips and wires to their respective bins in the lab.

Don't forget to also submit your lab report on Learning Suite.

How many hours did you work on the lab?

Provide any suggestions for improving this lab in the future.

Personal Exploration

Here are some ideas for personal exploration in this laboratory:

  • Using the 7400 series diagram, create a schematic drawing for a different logic circuit of your own choosing.
  • Implement a different logic function using the logic gates available in the lab.
  • Investigate different 7400 series devices and discuss the different gates that are available.
  • Find and summarize an interesting project online that uses 7400 series chips (there are a variety of interesting YouTube videos of digital logic projects using 7400 series chips).

Describe your personal exploration activities.


TA Notes and Feedback

1)
Chapter 6.2
2)
Chapter 6.4