Line 38... |
Line 38... |
//////////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////////////////////////
|
//
|
//
|
// CVS Revision History
|
// CVS Revision History
|
//
|
//
|
// $Log: not supported by cvs2svn $
|
// $Log: not supported by cvs2svn $
|
|
// Revision 1.2 2005/12/16 06:44:13 Administrator
|
|
// replaced tab with space.
|
|
// passed 9.6k length frame test.
|
|
//
|
// Revision 1.1.1.1 2005/12/13 01:51:44 Administrator
|
// Revision 1.1.1.1 2005/12/13 01:51:44 Administrator
|
// no message
|
// no message
|
//
|
//
|
|
|
module tb_top (
|
module tb_top (
|
Line 80... |
Line 84... |
wire Rx_er ;
|
wire Rx_er ;
|
wire Rx_dv ;
|
wire Rx_dv ;
|
wire [7:0] Rxd ;
|
wire [7:0] Rxd ;
|
wire Crs ;
|
wire Crs ;
|
wire Col ;
|
wire Col ;
|
//Tx host interface
|
wire CSB ;
|
wire [4:0] Tx_Hwmark ;
|
wire WRB ;
|
wire [4:0] Tx_Lwmark ;
|
wire [15:0] CD_in ;
|
wire pause_frame_send_en ;
|
wire [15:0] CD_out ;
|
wire [15:0] pause_quanta_set ;
|
wire [7:0] CA ;
|
wire MAC_tx_add_en ;
|
|
wire FullDuplex ;
|
|
wire [3:0] MaxRetry ;
|
|
wire [5:0] IFGset ;
|
|
wire [7:0] MAC_tx_add_prom_data ;
|
|
wire [2:0] MAC_tx_add_prom_add ;
|
|
wire MAC_tx_add_prom_wr ;
|
|
wire tx_pause_en ;
|
|
wire xoff_cpu ;
|
|
wire xon_cpu ;
|
|
//Rx host interface
|
|
wire MAC_rx_add_chk_en ;
|
|
wire [7:0] MAC_rx_add_prom_data ;
|
|
wire [2:0] MAC_rx_add_prom_add ;
|
|
wire MAC_rx_add_prom_wr ;
|
|
wire broadcast_filter_en ;
|
|
wire [15:0] broadcast_MAX ;
|
|
wire RX_APPEND_CRC ;
|
|
wire CRC_chk_en ;
|
|
wire [5:0] RX_IFG_SET ;
|
|
wire [15:0] RX_MAX_LENGTH ;// 1518
|
|
wire [6:0] RX_MIN_LENGTH ;// 64
|
|
//RMON host interface
|
|
wire [5:0] CPU_rd_addr ;
|
|
wire CPU_rd_apply ;
|
|
wire CPU_rd_grant ;
|
|
wire [31:0] CPU_rd_dout ;
|
|
//Phy int host interface
|
//Phy int host interface
|
wire Line_loop_en ;
|
wire Line_loop_en ;
|
wire [2:0] Speed ;
|
wire [2:0] Speed ;
|
//MII to CPU
|
//mii
|
wire [7:0] Divider ;// Divider for the host clock
|
|
wire [15:0] CtrlData ;// Control Data (to be written to the PHY reg.)
|
|
wire [4:0] Rgad ;// Register Address (within the PHY)
|
|
wire [4:0] Fiad ;// PHY Address
|
|
wire NoPre ;// No Preamble (no 32-bit preamble)
|
|
wire WCtrlData ;// Write Control Data operation
|
|
wire RStat ;// Read Status operation
|
|
wire ScanStat ;// Scan Status operation
|
|
wire Busy ;// Busy Signal
|
|
wire LinkFail ;// Link Integrity Signal
|
|
wire Nvalid ;// Invalid Status (qualifier for the valid scan result)
|
|
wire [15:0] Prsd ;// Read Status Data (data read from the PHY)
|
|
wire WCtrlDataStart ;// This signals resets the WCTRLDATA bit in the MIIM Command register
|
|
wire RStatStart ;// This signal resets the RSTAT BIT in the MIIM Command register
|
|
wire UpdateMIIRX_DATAReg ;// Updates MII RX_DATA register with read data
|
|
//MII interface signals
|
|
wire Mdio ;// MII Management Data In
|
wire Mdio ;// MII Management Data In
|
wire Mdc ;// MII Management Data Clock
|
wire Mdc ;// MII Management Data Clock
|
|
wire CPU_init_end ;
|
//******************************************************************************
|
//******************************************************************************
|
//internal signals
|
//internal signals
|
//******************************************************************************
|
//******************************************************************************
|
|
|
initial
|
initial
|
Line 176... |
Line 137... |
//system signals (//system signals ),
|
//system signals (//system signals ),
|
.Reset (Reset ),
|
.Reset (Reset ),
|
.Clk_125M (Clk_125M ),
|
.Clk_125M (Clk_125M ),
|
.Clk_user (Clk_user ),
|
.Clk_user (Clk_user ),
|
.Clk_reg (Clk_reg ),
|
.Clk_reg (Clk_reg ),
|
|
.Speed (Speed ),
|
//user interface (//user interface ),
|
//user interface (//user interface ),
|
.Rx_mac_ra (Rx_mac_ra ),
|
.Rx_mac_ra (Rx_mac_ra ),
|
.Rx_mac_rd (Rx_mac_rd ),
|
.Rx_mac_rd (Rx_mac_rd ),
|
.Rx_mac_data (Rx_mac_data ),
|
.Rx_mac_data (Rx_mac_data ),
|
.Rx_mac_BE (Rx_mac_BE ),
|
.Rx_mac_BE (Rx_mac_BE ),
|
Line 204... |
Line 166... |
.Rx_er (Rx_er ),
|
.Rx_er (Rx_er ),
|
.Rx_dv (Rx_dv ),
|
.Rx_dv (Rx_dv ),
|
.Rxd (Rxd ),
|
.Rxd (Rxd ),
|
.Crs (Crs ),
|
.Crs (Crs ),
|
.Col (Col ),
|
.Col (Col ),
|
//Tx host interface (//Tx host interface ),
|
//host interface
|
.Tx_Hwmark (Tx_Hwmark ),
|
.CSB (CSB ),
|
.Tx_Lwmark (Tx_Lwmark ),
|
.WRB (WRB ),
|
.pause_frame_send_en (pause_frame_send_en ),
|
.CD_in (CD_in ),
|
.pause_quanta_set (pause_quanta_set ),
|
.CD_out (CD_out ),
|
.MAC_tx_add_en (MAC_tx_add_en ),
|
.CA (CA ),
|
.FullDuplex (FullDuplex ),
|
|
.MaxRetry (MaxRetry ),
|
|
.IFGset (IFGset ),
|
|
.MAC_tx_add_prom_data (MAC_tx_add_prom_data ),
|
|
.MAC_tx_add_prom_add (MAC_tx_add_prom_add ),
|
|
.MAC_tx_add_prom_wr (MAC_tx_add_prom_wr ),
|
|
.tx_pause_en (tx_pause_en ),
|
|
.xoff_cpu (xoff_cpu ),
|
|
.xon_cpu (xon_cpu ),
|
|
//Rx host interface (//Rx host interface ),
|
|
.MAC_rx_add_chk_en (MAC_rx_add_chk_en ),
|
|
.MAC_rx_add_prom_data (MAC_rx_add_prom_data ),
|
|
.MAC_rx_add_prom_add (MAC_rx_add_prom_add ),
|
|
.MAC_rx_add_prom_wr (MAC_rx_add_prom_wr ),
|
|
.broadcast_filter_en (broadcast_filter_en ),
|
|
.broadcast_MAX (broadcast_MAX ),
|
|
.RX_APPEND_CRC (RX_APPEND_CRC ),
|
|
.CRC_chk_en (CRC_chk_en ),
|
|
.RX_IFG_SET (RX_IFG_SET ),
|
|
.RX_MAX_LENGTH (RX_MAX_LENGTH ),
|
|
.RX_MIN_LENGTH (RX_MIN_LENGTH ),
|
|
//RMON host interface (//RMON host interface ),
|
|
.CPU_rd_addr (CPU_rd_addr ),
|
|
.CPU_rd_apply (CPU_rd_apply ),
|
|
.CPU_rd_grant (CPU_rd_grant ),
|
|
.CPU_rd_dout (CPU_rd_dout ),
|
|
//Phy int host interface (//Phy int host interface ),
|
|
.Line_loop_en (Line_loop_en ),
|
|
.Speed (Speed ),
|
|
//MII to CPU (//MII to CPU ),
|
|
.Divider (Divider ),
|
|
.CtrlData (CtrlData ),
|
|
.Rgad (Rgad ),
|
|
.Fiad (Fiad ),
|
|
.NoPre (NoPre ),
|
|
.WCtrlData (WCtrlData ),
|
|
.RStat (RStat ),
|
|
.ScanStat (ScanStat ),
|
|
.Busy (Busy ),
|
|
.LinkFail (LinkFail ),
|
|
.Nvalid (Nvalid ),
|
|
.Prsd (Prsd ),
|
|
.WCtrlDataStart (WCtrlDataStart ),
|
|
.RStatStart (RStatStart ),
|
|
.UpdateMIIRX_DATAReg (UpdateMIIRX_DATAReg ),
|
|
//MII interface signals (//MII interface signals ),
|
//MII interface signals (//MII interface signals ),
|
.Mdio (Mdio ),
|
.Mdio (Mdio ),
|
.Mdc (Mdc )
|
.Mdc (Mdc )
|
);
|
);
|
|
|
Line 278... |
Line 195... |
);
|
);
|
|
|
User_int_sim U_User_int_sim(
|
User_int_sim U_User_int_sim(
|
.Reset (Reset ),
|
.Reset (Reset ),
|
.Clk_user (Clk_user ),
|
.Clk_user (Clk_user ),
|
|
.CPU_init_end (CPU_init_end ),
|
//user inputerface (//user inputerface ),
|
//user inputerface (//user inputerface ),
|
.Rx_mac_ra (Rx_mac_ra ),
|
.Rx_mac_ra (Rx_mac_ra ),
|
.Rx_mac_rd (Rx_mac_rd ),
|
.Rx_mac_rd (Rx_mac_rd ),
|
.Rx_mac_data (Rx_mac_data ),
|
.Rx_mac_data (Rx_mac_data ),
|
.Rx_mac_BE (Rx_mac_BE ),
|
.Rx_mac_BE (Rx_mac_BE ),
|
Line 295... |
Line 213... |
.Tx_mac_BE (Tx_mac_BE ),
|
.Tx_mac_BE (Tx_mac_BE ),
|
.Tx_mac_sop (Tx_mac_sop ),
|
.Tx_mac_sop (Tx_mac_sop ),
|
.Tx_mac_eop (Tx_mac_eop )
|
.Tx_mac_eop (Tx_mac_eop )
|
);
|
);
|
|
|
reg_int_sim U_reg_int_sim(
|
host_sim U_host_sim(
|
.Reset (Reset ),
|
.Reset (Reset ),
|
.Clk_reg (Clk_reg ),
|
.Clk_reg (Clk_reg ),
|
//Tx host interface (//Tx host interface ),
|
.CSB (CSB ),
|
.Tx_Hwmark (Tx_Hwmark ),
|
.WRB (WRB ),
|
.Tx_Lwmark (Tx_Lwmark ),
|
.CD_in (CD_in ),
|
.pause_frame_send_en (pause_frame_send_en ),
|
.CD_out (CD_out ),
|
.pause_quanta_set (pause_quanta_set ),
|
.CPU_init_end (CPU_init_end ),
|
.MAC_tx_add_en (MAC_tx_add_en ),
|
.CA (CA )
|
.FullDuplex (FullDuplex ),
|
|
.MaxRetry (MaxRetry ),
|
|
.IFGset (IFGset ),
|
|
.MAC_tx_add_prom_data (MAC_tx_add_prom_data ),
|
|
.MAC_tx_add_prom_add (MAC_tx_add_prom_add ),
|
|
.MAC_tx_add_prom_wr (MAC_tx_add_prom_wr ),
|
|
.tx_pause_en (tx_pause_en ),
|
|
.xoff_cpu (xoff_cpu ),
|
|
.xon_cpu (xon_cpu ),
|
|
//Rx host interface (//Rx host interface ),
|
|
.MAC_rx_add_chk_en (MAC_rx_add_chk_en ),
|
|
.MAC_rx_add_prom_data (MAC_rx_add_prom_data ),
|
|
.MAC_rx_add_prom_add (MAC_rx_add_prom_add ),
|
|
.MAC_rx_add_prom_wr (MAC_rx_add_prom_wr ),
|
|
.broadcast_filter_en (broadcast_filter_en ),
|
|
.broadcast_MAX (broadcast_MAX ),
|
|
.RX_APPEND_CRC (RX_APPEND_CRC ),
|
|
.CRC_chk_en (CRC_chk_en ),
|
|
.RX_IFG_SET (RX_IFG_SET ),
|
|
.RX_MAX_LENGTH (RX_MAX_LENGTH ),
|
|
.RX_MIN_LENGTH (RX_MIN_LENGTH ),
|
|
//RMON host interface (//RMON host interface ),
|
|
.CPU_rd_addr (CPU_rd_addr ),
|
|
.CPU_rd_apply (CPU_rd_apply ),
|
|
.CPU_rd_grant (CPU_rd_grant ),
|
|
.CPU_rd_dout (CPU_rd_dout ),
|
|
//Phy int host interface (//Phy int host interface ),
|
|
.Line_loop_en (Line_loop_en ),
|
|
.Speed (Speed ),
|
|
//MII to CPU (//MII to CPU ),
|
|
.Divider (Divider ),
|
|
.CtrlData (CtrlData ),
|
|
.Rgad (Rgad ),
|
|
.Fiad (Fiad ),
|
|
.NoPre (NoPre ),
|
|
.WCtrlData (WCtrlData ),
|
|
.RStat (RStat ),
|
|
.ScanStat (ScanStat ),
|
|
.Busy (Busy ),
|
|
.LinkFail (LinkFail ),
|
|
.Nvalid (Nvalid ),
|
|
.Prsd (Prsd ),
|
|
.WCtrlDataStart (WCtrlDataStart ),
|
|
.RStatStart (RStatStart ),
|
|
.UpdateMIIRX_DATAReg (UpdateMIIRX_DATAReg )
|
|
);
|
);
|
endmodule
|
endmodule
|
|
|
No newline at end of file
|
No newline at end of file
|