Altera_Forum
Honored Contributor
9 years agoModule Declaration Question for Transceiver Design
Hi, I was hoping someone could answer a fairly simple question. Here is my module declaration code for a transceiver design:
module xcvr_prbs ( //inputs input wire phy_mgmt_clk, input wire pll_ref_clk, input wire reset_reset, input wire reconfig_reset, input wire rx_serial_data, input wire rx_seriallpbken, input wire xgmii_tx_clk, input wire rx_serial_data_0, input wire xgmii_tx_dc_0[71:0], output wire xgmii_rx_clk, output wire rx_data_ready, output wire xgmii_rx_dc_0[71:0], output wire tx_serial_data_0, //ouputs output wire errorFlag, output wire [100:0] errorCount, output wire tx_serial_data, output wire tx_ready, output wire rx_ready, output wire [63:0] prbs_data_rx_top ); My question is, how do I know whether to put input/output wires and registers inside the module parenthesis, or outside the parenthesis? I have been following some example transceiver designs and in those examples, some wires are declared inside and some outside. I am assuming the ones declared inside the module also need pin assignments. Is that correct? Thanks in advance!