OpenCores
URL https://opencores.org/ocsvn/ethernet_tri_mode/ethernet_tri_mode/trunk

Subversion Repositories ethernet_tri_mode

[/] [ethernet_tri_mode/] [trunk/] [bench/] [verilog/] [tb_top.v] - Blame information for rev 5

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 5 maverickis
//////////////////////////////////////////////////////////////////////
2
////                                                              ////
3
////  tb_top.v                                                   ////
4
////                                                              ////
5
////  This file is part of the Ethernet IP core project           ////
6
////  http://www.opencores.org/projects.cgi/web/ethernet_tri_mode/////
7
////                                                              ////
8
////  Author(s):                                                  ////
9
////      - Jon Gao (gaojon@yahoo.com)                            ////
10
////                                                              ////
11
////                                                              ////
12
//////////////////////////////////////////////////////////////////////
13
////                                                              ////
14
//// Copyright (C) 2001 Authors                                   ////
15
////                                                              ////
16
//// This source file may be used and distributed without         ////
17
//// restriction provided that this copyright statement is not    ////
18
//// removed from the file and that any derivative work contains  ////
19
//// the original copyright notice and the associated disclaimer. ////
20
////                                                              ////
21
//// This source file is free software; you can redistribute it   ////
22
//// and/or modify it under the terms of the GNU Lesser General   ////
23
//// Public License as published by the Free Software Foundation; ////
24
//// either version 2.1 of the License, or (at your option) any   ////
25
//// later version.                                               ////
26
////                                                              ////
27
//// This source is distributed in the hope that it will be       ////
28
//// useful, but WITHOUT ANY WARRANTY; without even the implied   ////
29
//// warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR      ////
30
//// PURPOSE.  See the GNU Lesser General Public License for more ////
31
//// details.                                                     ////
32
////                                                              ////
33
//// You should have received a copy of the GNU Lesser General    ////
34
//// Public License along with this source; if not, download it   ////
35
//// from http://www.opencores.org/lgpl.shtml                     ////
36
////                                                              ////
37
//////////////////////////////////////////////////////////////////////
38
//                                                                    
39
// CVS Revision History                                               
40
//                                                                    
41
// $Log: not supported by cvs2svn $ 
42
 
43
module tb_top (
44
);
45
//******************************************************************************
46
//internal signals                                                              
47
//******************************************************************************
48
                                //system signals
49
input                   Reset                                   ,
50
input                   Clk_125M                                ,
51
input                   Clk_user                                ,
52
input                   Clk_reg                                 ,
53
                                //user interface 
54
output                  Rx_mac_ra                               ,
55
input                   Rx_mac_rd                               ,
56
output  [31:0]   Rx_mac_data                             ,
57
output  [1:0]    Rx_mac_BE                               ,
58
output                  Rx_mac_pa                               ,
59
output                  Rx_mac_sop                              ,
60
output                  Rx_mac_eop                              ,
61
                                //user interface 
62
output                  Tx_mac_wa                       ,
63
input                   Tx_mac_wr                       ,
64
input   [31:0]   Tx_mac_data                     ,
65
input   [1:0]    Tx_mac_BE                               ,//big endian
66
input                   Tx_mac_sop                      ,
67
input                   Tx_mac_eop                              ,
68
                                //Phy interface          
69
                                //Phy interface                 
70
output                  Gtx_clk                                 ,//used only in GMII mode
71
input                   Rx_clk                                  ,
72
input                   Tx_clk                                  ,//used only in MII mode
73
output                  Tx_er                                   ,
74
output                  Tx_en                                   ,
75
output  [7:0]    Txd                                             ,
76
input                   Rx_er                                   ,
77
input                   Rx_dv                                   ,
78
input   [7:0]    Rxd                                             ,
79
input                   Crs                                             ,
80
input                   Col                                             ,
81
                                //Tx host interface 
82
input   [4:0]    Tx_Hwmark                               ,
83
input   [4:0]    Tx_Lwmark                               ,
84
input                   pause_frame_send_en             ,
85
input   [15:0]   pause_quanta_set                ,
86
input                   MAC_tx_add_en                   ,
87
input                   FullDuplex                      ,
88
input   [3:0]    MaxRetry                        ,
89
input   [5:0]    IFGset                                  ,
90
input   [7:0]    MAC_tx_add_prom_data    ,
91
input   [2:0]    MAC_tx_add_prom_add             ,
92
input                   MAC_tx_add_prom_wr              ,
93
input                   tx_pause_en                             ,
94
input                   xoff_cpu                        ,
95
input                   xon_cpu                 ,
96
                                //Rx host interface     
97
input                   MAC_rx_add_chk_en               ,
98
input   [7:0]    MAC_rx_add_prom_data    ,
99
input   [2:0]    MAC_rx_add_prom_add             ,
100
input                   MAC_rx_add_prom_wr              ,
101
input                   broadcast_filter_en         ,
102
input   [15:0]   broadcast_MAX           ,
103
input                   RX_APPEND_CRC                   ,
104
input                   CRC_chk_en                              ,
105
input   [5:0]    RX_IFG_SET                              ,
106
input   [15:0]   RX_MAX_LENGTH                   ,//     1518
107
input   [6:0]    RX_MIN_LENGTH                   ,//     64
108
                                //RMON host interface
109
input   [5:0]    CPU_rd_addr                             ,
110
input                   CPU_rd_apply                    ,
111
output                  CPU_rd_grant                    ,
112
output  [31:0]   CPU_rd_dout                             ,
113
                                //Phy int host interface     
114
input                   Line_loop_en                    ,
115
input   [2:0]    Speed                                   ,
116
                                //MII to CPU 
117
input   [7:0]    Divider                         ,// Divider for the host clock
118
input   [15:0]   CtrlData                        ,// Control Data (to be written to the PHY reg.)
119
input   [4:0]    Rgad                            ,// Register Address (within the PHY)
120
input   [4:0]    Fiad                            ,// PHY Address
121
input           NoPre                           ,// No Preamble (no 32-bit preamble)
122
input           WCtrlData                       ,// Write Control Data operation
123
input           RStat                           ,// Read Status operation
124
input           ScanStat                        ,// Scan Status operation
125
output          Busy                            ,// Busy Signal
126
output          LinkFail                        ,// Link Integrity Signal
127
output          Nvalid                          ,// Invalid Status (qualifier for the valid scan result)
128
output  [15:0]   Prsd                            ,// Read Status Data (data read from the PHY)
129
output          WCtrlDataStart                  ,// This signals resets the WCTRLDATA bit in the MIIM Command register
130
output          RStatStart                      ,// This signal resets the RSTAT BIT in the MIIM Command register
131
output          UpdateMIIRX_DATAReg             ,// Updates MII RX_DATA register with read data
132
                                //MII interface signals
133
inout           Mdio                    ,// MII Management Data In
134
output          Mdc                             ,// MII Management Data Clock   
135
 
136
//******************************************************************************
137
//internal signals                                                              
138
//******************************************************************************
139
 
140
MAC_top U_MAC_top(
141
.//system signals                       (//system signals           ),
142
.Reset                                          (Reset                                      ),
143
.Clk_125M                                       (Clk_125M                                   ),
144
.Clk_user                                       (Clk_user                                   ),
145
.Clk_reg                                            (Clk_reg                                    ),
146
.//user interface               (//user interface           ),
147
.Rx_mac_ra                                      (Rx_mac_ra                                  ),
148
.Rx_mac_rd                                      (Rx_mac_rd                                  ),
149
.Rx_mac_data                                (Rx_mac_data                                ),
150
.Rx_mac_BE                                      (Rx_mac_BE                                  ),
151
.Rx_mac_pa                                      (Rx_mac_pa                                  ),
152
.Rx_mac_sop                                     (Rx_mac_sop                                 ),
153
.Rx_mac_eop                                     (Rx_mac_eop                                 ),
154
.//user interface               (//user interface           ),
155
.Tx_mac_wa                              (Tx_mac_wa                          ),
156
.Tx_mac_wr                              (Tx_mac_wr                          ),
157
.Tx_mac_data                        (Tx_mac_data                        ),
158
.Tx_mac_BE                                      (Tx_mac_BE                                  ),
159
.Tx_mac_sop                             (Tx_mac_sop                         ),
160
.Tx_mac_eop                                     (Tx_mac_eop                                 ),
161
.//Phy interface                (//Phy interface            ),
162
.//Phy interface                            (//Phy interface                    ),
163
.Gtx_clk                                            (Gtx_clk                                    ),
164
.Rx_clk                                         (Rx_clk                                     ),
165
.Tx_clk                                         (Tx_clk                                     ),
166
.Tx_er                                          (Tx_er                                      ),
167
.Tx_en                                          (Tx_en                                      ),
168
.Txd                                                (Txd                                                ),
169
.Rx_er                                          (Rx_er                                      ),
170
.Rx_dv                                          (Rx_dv                                      ),
171
.Rxd                                                (Rxd                                                ),
172
.Crs                                                (Crs                                                ),
173
.Col                                                (Col                                                ),
174
.//Tx host interface            (//Tx host interface        ),
175
.Tx_Hwmark                                      (Tx_Hwmark                                  ),
176
.Tx_Lwmark                                      (Tx_Lwmark                                  ),
177
.pause_frame_send_en                (pause_frame_send_en                ),
178
.pause_quanta_set                       (pause_quanta_set                   ),
179
.MAC_tx_add_en                          (MAC_tx_add_en                      ),
180
.FullDuplex                         (FullDuplex                         ),
181
.MaxRetry                               (MaxRetry                           ),
182
.IFGset                                         (IFGset                                     ),
183
.MAC_tx_add_prom_data           (MAC_tx_add_prom_data       ),
184
.MAC_tx_add_prom_add                (MAC_tx_add_prom_add                ),
185
.MAC_tx_add_prom_wr                     (MAC_tx_add_prom_wr                 ),
186
.tx_pause_en                                (tx_pause_en                                ),
187
.xoff_cpu                               (xoff_cpu                           ),
188
.xon_cpu                            (xon_cpu                    ),
189
.//Rx host interface            (//Rx host interface        ),
190
.MAC_rx_add_chk_en                      (MAC_rx_add_chk_en                  ),
191
.MAC_rx_add_prom_data           (MAC_rx_add_prom_data       ),
192
.MAC_rx_add_prom_add                (MAC_rx_add_prom_add                ),
193
.MAC_rx_add_prom_wr                     (MAC_rx_add_prom_wr                 ),
194
.broadcast_filter_en            (broadcast_filter_en        ),
195
.broadcast_MAX                  (broadcast_MAX              ),
196
.RX_APPEND_CRC                          (RX_APPEND_CRC                      ),
197
.CRC_chk_en                                     (CRC_chk_en                                 ),
198
.RX_IFG_SET                                     (RX_IFG_SET                                 ),
199
.RX_MAX_LENGTH                          (RX_MAX_LENGTH                      ),
200
.RX_MIN_LENGTH                          (RX_MIN_LENGTH                      ),
201
.//RMON host interface          (//RMON host interface      ),
202
.CPU_rd_addr                                (CPU_rd_addr                                ),
203
.CPU_rd_apply                           (CPU_rd_apply                       ),
204
.CPU_rd_grant                           (CPU_rd_grant                       ),
205
.CPU_rd_dout                                (CPU_rd_dout                                ),
206
.//Phy int host interface       (//Phy int host interface   ),
207
.Line_loop_en                           (Line_loop_en                       ),
208
.Speed                                          (Speed                                      ),
209
.//MII to CPU                   (//MII to CPU               ),
210
.Divider                            (Divider                            ),
211
.CtrlData                           (CtrlData                           ),
212
.Rgad                               (Rgad                               ),
213
.Fiad                               (Fiad                               ),
214
.NoPre                              (NoPre                              ),
215
.WCtrlData                          (WCtrlData                          ),
216
.RStat                              (RStat                              ),
217
.ScanStat                           (ScanStat                           ),
218
.Busy                               (Busy                               ),
219
.LinkFail                           (LinkFail                           ),
220
.Nvalid                             (Nvalid                             ),
221
.Prsd                               (Prsd                               ),
222
.WCtrlDataStart                     (WCtrlDataStart                     ),
223
.RStatStart                         (RStatStart                         ),
224
.UpdateMIIRX_DATAReg                (UpdateMIIRX_DATAReg                ),
225
.//MII interface signals        (//MII interface signals    ),
226
.Mdio                           (Mdio                       ),
227
.Mdc                                (Mdc                                )
228
 
229
 
230
);
231
endmodule

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.