ms_tab.v
10.5 KB
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
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
////////////////////////////////////////////////////////////////////////
//
// Project Reality
//
// module: ms_tab.v
// description: dumps out ms i/o .tab file
//
// designer: Tony DeLaurier
// date: 12/19/94
//
////////////////////////////////////////////////////////////////////////
module ms_tab();
integer tab_file_ptr;
// open tab file and dump header
initial
begin
tab_file_ptr = $fopen("ms.tab");
// dump out header
$fwriteh(tab_file_ptr, "#\n");
$fwriteh(tab_file_ptr, "# ms tab file\n");
$fwriteh(tab_file_ptr, "#\n");
$fwriteh(tab_file_ptr, "clk_2x @DC 1(4) 0(4)\n");
$fwriteh(tab_file_ptr, "clk_1x @DC 1(8) 0(8)\n");
$fwriteh(tab_file_ptr, "clock @I @E 0 @C clk_2x\n");
$fwriteh(tab_file_ptr, "gclock @I @E 0 @C clk_2x\n");
$fwriteh(tab_file_ptr, "bist_done @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "bist_fail[7:0] @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "reset_l @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "stb_sync_full @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "freeze_gclk @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "unfreeze_gclk @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "grant @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "start @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "finish @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "dma_write_enable @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "dma_read_enable @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "cbus_read_enable @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "cbus_write_enable @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "cbus_select[1:0] @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "cbus_command[2:0] @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "read_grant @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "cycle_type[1:0] @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "image_read_en @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "z_update_en @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "z_compare_en @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "color_base[25:0] @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "color_size[1:0] @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "color_format[2:0] @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "z_base[25:0] @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "tex_base[25:0] @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "tex_size[1:0] @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "tex_format[2:0] @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "load_tlut_en @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "fillcolor[31:0] @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "alphacompen @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "dithalphaen @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "blendalpha[7:0] @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "noise[2:0] @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "startspant0 @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "nextspanxi[19:0] @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "nextspanxf[11:0] @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "nextspancount[11:0] @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "nextspanxdec @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "load_en @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "spanbufmt @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "rdpwdepthin[17:0] @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "rdpwredin[7:0] @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "rdpwgreenin[7:0] @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "rdpwbluein[7:0] @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "rdpwalphain[2:0] @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "rdpcolorwen @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "ccalpha[7:0] @I @E 2 @C clk_1x\n");
$fwriteh(tab_file_ptr, "dithrgben @I @E 8 @C clk_1x\n");
$fwriteh(tab_file_ptr, "load_dv @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "rdramreq @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "rdramrw @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "read_request @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "stopgclock @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "start_gclk @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "rel_sync_full @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "pipe_busy @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "spanbufrd @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "rdprred[7:0] @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "rdprgreen[7:0] @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "rdprblue[7:0] @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "rdpralpha[2:0] @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "rdprdepthd[17:0] @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "bist_go @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "bist_check @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "copy_load[63:0] @B copy_load_oe 1 @E 5 @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "copy_load_oe @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "copy_load_dummy @I @E 0 @C clk_1x\n");
$fwriteh(tab_file_ptr, "cbus_data[31:0] @B cbus_data_oe 1 @E 5 @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "cbus_data_oe @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "cbus_dummy @I @E 0 @C clk_1x\n");
$fwriteh(tab_file_ptr, "dbus_data[63:0] @B dbus_data_oe 1 @E 5 @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "dbus_data_oe @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "dbus_dummy @I @E 0 @C clk_1x\n");
$fwriteh(tab_file_ptr, "ebus_data[7:0] @B ebus_data_oe 1 @E 5 @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "ebus_data_oe @O @S 15 @C clk_1x\n");
$fwriteh(tab_file_ptr, "ebus_dummy @I @E 0 @C clk_1x\n");
$fwriteh(tab_file_ptr, "\n");
end // initial
// generate sample clk
reg smp_clk;
initial
begin
smp_clk = 1;
#7.9 smp_clk = 0;
forever
begin
#8 smp_clk = ~smp_clk;
end // forever
end // initial
integer vector_count;
initial vector_count = 0;
always @(smp_clk)
begin
if (vector_count >= 0)
begin
$fwriteh(tab_file_ptr,
reality.rcp_0.rdp_0.ms.clock,,
reality.rcp_0.rdp_0.ms.gclock,,
reality.rcp_0.rdp_0.ms.bist_done,,
"0x", reality.rcp_0.rdp_0.ms.bist_fail,,
reality.rcp_0.rdp_0.ms.reset_l,,
reality.rcp_0.rdp_0.ms.stb_sync_full,,
reality.rcp_0.rdp_0.ms.freeze_gclk,,
reality.rcp_0.rdp_0.ms.unfreeze_gclk,,
reality.rcp_0.rdp_0.ms.grant,,
reality.rcp_0.rdp_0.ms.start,,
reality.rcp_0.rdp_0.ms.finish,,
reality.rcp_0.rdp_0.ms.dma_write_enable,,
reality.rcp_0.rdp_0.ms.dma_read_enable,,
reality.rcp_0.rdp_0.ms.cbus_read_enable,,
reality.rcp_0.rdp_0.ms.cbus_write_enable,,
"0x", reality.rcp_0.rdp_0.ms.cbus_select,,
"0x", reality.rcp_0.rdp_0.ms.cbus_command,,
reality.rcp_0.rdp_0.ms.read_grant,,
"0x", reality.rcp_0.rdp_0.ms.cycle_type,,
reality.rcp_0.rdp_0.ms.image_read_en,,
reality.rcp_0.rdp_0.ms.z_update_en,,
reality.rcp_0.rdp_0.ms.z_compare_en,,
"0x", reality.rcp_0.rdp_0.ms.color_base,,
"0x", reality.rcp_0.rdp_0.ms.color_size,,
"0x", reality.rcp_0.rdp_0.ms.color_format,,
"0x", reality.rcp_0.rdp_0.ms.z_base,,
"0x", reality.rcp_0.rdp_0.ms.tex_base,,
"0x", reality.rcp_0.rdp_0.ms.tex_size,,
"0x", reality.rcp_0.rdp_0.ms.tex_format,,
reality.rcp_0.rdp_0.ms.load_tlut_en,,
"0x", reality.rcp_0.rdp_0.ms.fillcolor,,
reality.rcp_0.rdp_0.ms.alphacompen,,
reality.rcp_0.rdp_0.ms.dithalphaen,,
"0x", reality.rcp_0.rdp_0.ms.blendalpha,,
"0x", reality.rcp_0.rdp_0.ms.noise,,
reality.rcp_0.rdp_0.ms.startspant0,,
"0x", reality.rcp_0.rdp_0.ms.nextspanxi,,
"0x", reality.rcp_0.rdp_0.ms.nextspanxf,,
"0x", reality.rcp_0.rdp_0.ms.nextspancount,,
reality.rcp_0.rdp_0.ms.nextspanxdec,,
reality.rcp_0.rdp_0.ms.load_en,,
reality.rcp_0.rdp_0.ms.spanbufmt,,
"0x", reality.rcp_0.rdp_0.ms.rdpwdepthin,,
"0x", reality.rcp_0.rdp_0.ms.rdpwredin,,
"0x", reality.rcp_0.rdp_0.ms.rdpwgreenin,,
"0x", reality.rcp_0.rdp_0.ms.rdpwbluein,,
"0x", reality.rcp_0.rdp_0.ms.rdpwalphain,,
reality.rcp_0.rdp_0.ms.rdpcolorwen,,
"0x", reality.rcp_0.rdp_0.ms.ccalpha,,
reality.rcp_0.rdp_0.ms.dithrgben,," ",
reality.rcp_0.rdp_0.ms.load_dv,,
reality.rcp_0.rdp_0.ms.rdramreq,,
reality.rcp_0.rdp_0.ms.rdramrw,,
reality.rcp_0.rdp_0.ms.read_request,,
reality.rcp_0.rdp_0.ms.stopgclock,,
reality.rcp_0.rdp_0.ms.start_gclk,,
reality.rcp_0.rdp_0.ms.rel_sync_full,,
reality.rcp_0.rdp_0.ms.pipe_busy,,
reality.rcp_0.rdp_0.ms.spanbufrd,,
"0x", reality.rcp_0.rdp_0.ms.rdprred,,
"0x", reality.rcp_0.rdp_0.ms.rdprgreen,,
"0x", reality.rcp_0.rdp_0.ms.rdprblue,,
"0x", reality.rcp_0.rdp_0.ms.rdpralpha,,
"0x", reality.rcp_0.rdp_0.ms.rdprdepthd,,
reality.rcp_0.rdp_0.ms.bist_go,,
reality.rcp_0.rdp_0.ms.bist_check,," ",
"0x", reality.rcp_0.rdp_0.ms.copy_load,,
reality.rcp_0.rdp_0.ms.load_dv,,
reality.rcp_0.rdp_0.ms.load_dv,,
"0x", reality.rcp_0.rdp_0.ms.cbus_data,,
reality.rcp_0.rdp_0.ms.cbus_write_enable,,
reality.rcp_0.rdp_0.ms.cbus_write_enable,,
"0x", reality.rcp_0.rdp_0.ms.dbus_data,,
reality.rcp_0.rdp_0.ms.dma_write_enable,,
reality.rcp_0.rdp_0.ms.dma_write_enable,,
"0x", reality.rcp_0.rdp_0.ms.ebus_data,,
reality.rcp_0.rdp_0.ms.dma_write_enable,,
reality.rcp_0.rdp_0.ms.dma_write_enable,,
"\n");
end // if
vector_count = vector_count + 1;
end // always
endmodule // ms_tab