|
发表于 2017-2-23 11:37:08
|
显示全部楼层
回复 6# 金水
我mac是自己写的,你最后就直接把你mac输出的数据写成GMII接口的形式,需要你mac的发时钟送到IP核中你就看下面的这个IP核的顶层(我是之后光口没有电口),rxp/n,txp/n都是直接连接外部接口,然后gtrefclk是transceiver的外部参考时钟
gtx_clk是mac层组帧的时钟,对于光口你这个就相当于phy
gmii2sfp_example_design gmii2sfp_example_design
(
.gtrefclk_p (gtrefclk_p),// Very high quality 125MHz clock for GT transceiver.
.gtrefclk_n (gtrefclk_n),
.rxuserclk2 (rxuserclk2),
.txp (txp),
.txn (txn),
.rxp (rxp),
.rxn (rxn),
// GMII Interface (client MAC <=> PCS)
//---------------
.gmii_tx_clk (gtx_clk), //Transmit clock from client MAC.
.gmii_txd (gmii_tx_dat_sfp),/// Transmit data from client MAC.
.gmii_tx_en (gmii_tx_dv_sfp),
.gmii_tx_er (gmii_tx_err_sfp),
.gmii_rx_clk (gmii_rx_clk_sfp), //Transmit clock from client MAC.
.gmii_rxd (gmii_rx_dat_sfp), // Received Data to client MAC.
.gmii_rx_dv (gmii_rx_dv_sfp),
.gmii_rx_er (gmii_rx_err_sfp),
.an_interrupt (),
.an_adv_config_vector (an_adv_config_vector),
.an_restart_config (an_restart_config),
// General IO's
// General IO's
//-------------
.status_vector (status_vector),
.reset (),
.signal_detect (1'b1)
); |
|