-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTester.v
107 lines (94 loc) · 1.72 KB
/
Tester.v
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
`timescale 1ns / 1ps
////////////////////////////////////////////////////////////////////////////////
// Company:
// Engineer:
//
// Create Date: 10:41:41 03/18/2017
// Design Name: Interface
// Module Name: /home/tvlenin/Projects/XILINX/Prueba2/Tester.v
// Project Name: Prueba2
// Target Device:
// Tool versions:
// Description:
//
// Verilog Test Fixture created by ISE for module: Interface
//
// Dependencies:
//
// Revision:
// Revision 0.01 - File Created
// Additional Comments:
//
////////////////////////////////////////////////////////////////////////////////
module Tester;
// Inputs
reg clk;
reg enable;
reg reset;
reg switch1;
reg switch2;
reg switch3;
reg Button1;
reg Button2;
reg Button3;
reg Button4;
reg Button5;
reg Button6;
reg Button7;
// Outputs
wire [1:0] test_out;
wire [7:0] sevenseg;
wire [1:0] Level;
wire [3:0] reloj;
// Instantiate the Unit Under Test (UUT)
Interface uut (
.exit(exit),
.clk(clk),
.enable(enable),
.reset(reset),
.switch1(switch1),
.switch2(switch2),
.switch3(switch3),
.Button1(Button1),
.Button2(Button2),
.Button3(Button3),
.Button4(Button4),
.Button5(Button5),
.Button6(Button6),
.Button7(Button7),
.test_out(test_out),
.sevenseg(sevenseg),
.Level(Level),
.reloj(reloj)
);
//always
always #1clk = ~clk; // 100 MHz
initial begin
// Initialize Inputs
clk = 0;
enable = 0;
reset = 0;
switch1 = 0;
switch2 = 0;
switch3 = 0;
Button1 = 0;
Button2 = 0;
Button3 = 0;
Button4 = 0;
Button5 = 0;
Button6 = 0;
Button7 = 0;
//test_out = 0;
#2
reset = 1;
#3
reset = 0;
#10;
switch1 = 0;
Button5 = 1;
switch2 = 1;
switch3 = 1;
#3
Button5 = 0;
end
endmodule