-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathVGA_example_tbw.v
90 lines (80 loc) · 1.61 KB
/
VGA_example_tbw.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
`timescale 1ns / 100ps
////////////////////////////////////////////////////////////////////////////////
// Company:
// Engineer:
//
// Create Date: 10:19:29 02/25/2016
// Design Name: VGA_example
// Module Name: C:/Users/Mark Johnson/Documents/GitHub/VGA_example/VGA_example_tbw.v
// Project Name: VGA_example
// Target Device:
// Tool versions:
// Description:
//
// Verilog Test Fixture created by ISE for module: VGA_example
//
// Dependencies:
//
// Revision:
// Revision 0.01 - File Created
// Additional Comments:
//
////////////////////////////////////////////////////////////////////////////////
`include "./includes/colours.v"
module VGA_example_tbw;
// Inputs
reg clk;
reg resetn;
// Outputs
wire [26:1] MemAdr;
wire MemOE;
wire MemWR;
wire RamAdv;
wire RamCS;
wire RamClk;
wire RamCRE;
wire RamLB;
wire RamUB;
wire RamWait;
wire FlashRp;
wire FlashCS;
wire [7:0] pixel;
wire Hsync;
wire Vsync;
// Bidirs
wire [15:0] MemDB;
// Instantiate the Unit Under Test (UUT)
VGA_example uut (
.clk(clk),
.resetn(resetn),
.MemAdr(MemAdr),
.MemDB(MemDB),
.MemOE(MemOE),
.MemWR(MemWR),
.RamAdv(RamAdv),
.RamCS(RamCS),
.RamClk(RamClk),
.RamCRE(RamCRE),
.RamLB(RamLB),
.RamUB(RamUB),
.RamWait(RamWait),
.FlashRp(FlashRp),
.FlashCS(FlashCS),
.vgaRed(pixel[7:5]),
.vgaGreen(pixel[4:2]),
.vgaBlue(pixel[1:0]),
.Hsync(Hsync),
.Vsync(Vsync)
);
initial begin
// Initialize Inputs
clk <= 0;
resetn <= 0;
// Wait 100 ns for global reset to finish
#100;
resetn <= 1;
// Add stimulus here
forever
clk <= #10 ~clk;
end
endmodule