ECE 271 Lab 2 Dachinhsua
ECE 271 Lab 2 Dachinhsua
EE271
DIGITAL CIRCUITS AND SYSTEMS
- LABORATORY REPORT-
Waveforms:
Waveforms:
Source code:
Waveforms:
Input Output
A B C D
0 0 0 0
0 1 1 0
1 0 1 0
1 1 1 1
Source code:
Waveforms:
2. One set of answers to all the questions from the team. The answers to the questions
must be typed. The diagrams must be done using a drawing tool such as Visio.
1. Draw a logic diagram using the logic gates that were used to build the digital circuit
in the Verilog source code. Use the same signal names indicated in the source code.
Use AND, OR, and NOT gates.
3. When you run the simulation. Does the output of the Verilog program agree or
disagree with your truth table?
- Waveform simulation:
The waveform result matches the expected outputs from the truth table for all test
cases, so the output of the Verilog program agrees with the truth table.
4. What advantages are there to using a program like Verilog? Name three or more.
Summary:
Part 3: Working with Real World Devices
Working with Logic Gates
What are these values (IIL, IOH, IIH, and IOL) telling us?
- IOH: Maximum output current when at logic high (-0.4 mA).
- IOL: Maximum output current when at logic low (8.0 mA).
- IIH: Maximum input current when at logic high (0.1 mA).
- IIL: Maximum input current when at logic low (-0.4 mA).
- VOH: Maximum high voltage output (2.7V - 3.5V).
- VOL: Maximum output low voltage (0.35V - 0.5V).
Compare these values from the data sheet with what you measured for I1, I2, I3, and I4?
Which configuration, that in figure 11 or that in figure 12, gave the brighter LED
display? Why?
The configuration in Figure 12 gives the LED brighter light because the current is taken
directly from the source and the low level is controlled by the IC.
Timing Measurements:
1. As a first step, using the data sheet for an SN 74LS04, find the vendor specified values for
these two propagation delays. Observe that a typical and a maximum value are given. What do
these mean?
- The vendor’s data sheet as PHL and PLH respectively. (The data sheet for an SN 74LS04)
- Observe that a typical and a maximum value are given. What do these mean?
In a digital device, the times for an input signal to propagate through the device and
cause the output signal to change from a high to a low or vice versa.
A typical and a maximum value are given these show the amount of time which must
occur after a signal is delivered for it to be received.
2. Next, configure the function generator to produce a 5 V, 100 KHz, square wave.
Using the oscilloscope, make certain that you have the offset and amplitude set correctly
5. Using the oscilloscope, now measure and record the rise and fall times of the output
of the SN 74LS04. These measurements are made at the 10% and 90% points in the signal
as we see in figure 5. Record the values you have measured. Do the values seem
reasonable?
Logic Reduction:
1. As a first step, draw a Karnaugh map (Qua???? I know, I know, we’ll get there) for
the circuit in figure 6.
*Truth Table:
SEL1 SEL2 A B Result
0 0 0 0 0
0 0 0 1 0
0 0 1 0 0
0 0 1 1 1
0 1 0 0 0
0 1 0 1 1
0 1 1 0 1
0 1 1 1 1
1 0 0 0 0
1 0 0 1 1
1 0 1 0 1
1 0 1 1 0
1 1 0 0 0
1 1 0 1 0
1 1 1 0 0
1 1 1 1 0
*K- map:
00 0 0 0
0 1 0 01
1 1 0 0
0 1 0 1
00
Group 1: SEL1 . A . B
Group 2: SEL1 . SEL2 . B
Group 3: SEL1 . SEL2 . A
Group 4: SEL1 . SEL2 . A . B
Group 5: SEL1 . SEL2 . A . B
Sum of products:
Result = SEL1 . A . B + SEL1 . SEL2 . B + SEL1 . SEL2 . A + SEL1 . SEL2 . A . B + SEL1 . SEL2 . A . B
= SEL1 . SEL2 . (A + B) + SEL1 . SEL2 . (A + B) + SEL1 . A . B
2. From the Karnaugh map you just drew, can you see any way to swap only two of the
selection lines such that the logic for this circuit can be minimized? Why can we do this?
From the Kmap, by swapping the positions of rows 2 and 3, the logic of this circuit will be
minimized.
00 0 0 0
1 1 0 0
0 1 0 1
0 1 0 1
00
Group 1: SEL1 . A . B
Group 2: SEL1 . SEL2 . A
Group 3: SEL1 . SEL2 . A
Sum of products:
Result = SEL1 . A . B + SEL1 . SEL2 . A + SEL1 . SEL2 . A
*Create a new Verilog source file for your revised design run a simulation.
Laboratory Part 3 – Executing a Design from a Set of Requirements
Design
Draw a block diagram for your system. Clearly identify all inputs and outputs.
Inputs
1. SYSON: the photographic system is turned on.
2. TAKE: capture the currently selected image.
3. SELFLASH: enable the advanced built-in light system.
4. NOFLASH: sensor that detects that the use of artificial lighting is
prohibited.
5. ~INFOCUS: sensor that detects if the image is in focus.
6. ~LOWLIGHT: sensor that detects a low ambient light condition.
- The inputs SYSON, TAKE, SELFLASH, and NOFLASH, are active high.
- The inputs, ~INFOCUS and ~LOWLIGHT are active low.
Outputs
- Four outputs, ~CAPTURE, ~OUTOFFOCUS, ~FLASH, and
~THERMONUCLEAR DEVICE
~ FLASH
~ OUTOFFOCUS
~ OUTOFFOCUS = 𝑆𝐸𝐿𝐹𝐿𝐴𝑆𝐻 + 𝑁𝑂𝐹𝐿𝐴𝑆𝐻
~ CAPTURE
~ CAPTURE = 1