Skip to content

Commit 8f92895

Browse files
committed
Initial Commit
0 parents commit 8f92895

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+1531
-0
lines changed

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
The MIT License (MIT)
2+
3+
Copyright (c) 2016
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.
340 KB
Binary file not shown.
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Project 1 - Introduction to Xilinx
2+
3+
## Objective
4+
5+
The main goal of this lab is to create a verilog module, and through a test bench, analyze its waveform model once a schematic, and source code is created using the software, Xilinx ISE. Through this process, the team will be able to obtain a deeper understanding of how logic gates, or boolean logic, interacts with verilog code by analyzing certain scenarios that these two demonstrate.
6+
7+
## Waveforms
8+
9+
Simulation results from the Verilog representation of this half-adder
10+
11+
![Project 1 Waveform](/Project 1 – Introduction to Xilinx/Simulation Waveforms/project1_halfAdder.png)
12+
13+
## Source Files
14+
- **Half-Adder Module** - half_adder.v
15+
- **Half-Adder Test Bench** - half_adder_test.v
16+
14.8 KB
Loading
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
`timescale 1ns / 1ps
2+
3+
/*
4+
Group Members: Luis Calderon and Warren Seto
5+
6+
Lab Name: Introduction to Xilinx (Lab 1)
7+
Project Name: eng312_proj1
8+
Design Name: half_adder
9+
Design Description: Verilog Code for a half-adder
10+
*/
11+
12+
// Input & Output components to use in the half-adder
13+
module half_adder
14+
(
15+
input iA, input iB,
16+
output oSUM, output oCARRY
17+
);
18+
19+
// This uses an exclusive OR gate to find the SUM of two inputs
20+
assign oSUM = iA ^ iB;
21+
22+
// This uses an AND gate to find the CARRY of two inputs
23+
assign oCARRY = iA & iB;
24+
25+
endmodule
Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
`timescale 1ns / 1ps
2+
3+
/*
4+
Group Members: Luis Calderon and Warren Seto
5+
6+
Lab Name: Introduction to Xilinx (Lab 1)
7+
Project Name: eng312_proj1
8+
Design Name: half_adder_test.v
9+
Design Description: Verilog Test Fixture created by ISE for module: half_adder
10+
*/
11+
12+
module half_adder_test;
13+
14+
// Input Registers:
15+
reg iA;
16+
reg iB;
17+
18+
// Output Registers:
19+
wire oSUM;
20+
wire oCARRY;
21+
22+
// Instantiate the Unit Under Test (UUT)
23+
half_adder uut
24+
(
25+
.iA(iA),
26+
.iB(iB),
27+
.oSUM(oSUM),
28+
.oCARRY(oCARRY)
29+
);
30+
31+
// The code below tests the half-adder by manually changing the values of each input register
32+
initial begin
33+
34+
// Set the both input registers as 0 as a default
35+
iA = 0;
36+
iB = 0;
37+
38+
// For five seconds, set one register to 1 while leaving the other as its default 0
39+
#5 iA = 0; iB = 1;
40+
41+
// For five seconds, set the other register to 1 while flipping the other to its default 0
42+
#5 iA = 1; iB = 0;
43+
44+
// For five seconds, set both registers to 1
45+
#5 iA = 1; iB = 1;
46+
47+
end
48+
49+
// The test should run for a total of 25 nanoseconds
50+
initial #25 $finish;
51+
52+
endmodule
253 KB
Binary file not shown.
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Project 2 - Combinational Logic
2+
3+
## Objective
4+
5+
The purpose of this design assignment was to create modules of combinational logic in the Verilog Hardware Description Language (HDL) format. While completing this task, students continued immersing themselves in the Xilinx platform and the Verilog HDL. Through this assignment the team: prepared truth tables, wrote Verilog code per module, and made test fixtures to test each module. The assignment tasked the group to create: a full adder, a 4-bit adder, a three bit comparator, a 4-16 decoder, a priority encoder, and a 4-1 multiplexer.
6+
7+
## Source Directories
8+
9+
- **Four-Sixteen Decoder** - /dec_4_to_16
10+
- **Four-Bit Look Ahead Adder** - /four_bit_look_ahead_adder
11+
- **Four-Bit Ripple Adder**: - /four_bit_ripple_adder
12+
- **Full Adder** - /full_adder
13+
- **Four-One Multiplexer** - /mux_four_to_one
14+
- **Priority Encoder** - /priority_encoder
15+
- **Three-Bit Comparator** - /three_bit_comparator
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# Four-Sixteen Decoder
2+
3+
## Objective
4+
5+
This 4-to-16 decoder takes one four bit input and outputs the sixteen bit representation of the input. This module uses the concept of one-hot decoding where each output would have one output that would correspond to the input.
6+
7+
An application for this decoder would be to convert a four bit binary to its hexadecimal representation.
8+
9+
To verify this module, the input’s binary bits were converted into their decimal representation and compared to the output’s decimal representation to see if they matched.
10+
11+
## Waveforms
12+
13+
Simulation results from the Verilog representation of this Four-Sixteen Decoder
14+
15+
![Project 2 Waveform for Four-Sixteen Decoder](/Project 2 – Combinational Logic/dec_4_to_16/Simulation Waveforms/project2_416decode.png)
16+
17+
## Source Files
18+
- **Four-Sixteen Decoder Module** - dec_4_to_16.v
19+
- **Four-Sixteen Decoder Test Bench** - dec_4_to_16_test.v
11.4 KB
Loading

0 commit comments

Comments
 (0)