|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?注册
x
module EDFA_Top(
input i_clk,
input i_rst
);
wire w_S_data_valid ;
wire [7 :0] w_S_data = 8'b10011011;
wire signed[7 :0] w_mod_data ;
wire w_mod_data_valid ;
reg [14:0] cnt = 15'd0 ;
reg r_S_data_valid = 0 ;
wire w_cal_snr_valid ;
wire [15:0] w_cal_snr_tx_data ;
wire [11:0] w_cal_snr_dac_data ;
always @(posedge i_clk)begin
if(i_rst)
cnt <= 15'd0;
else
cnt <= cnt + 1'b1;
end
always @(posedge i_clk)
r_S_data_valid <= (cnt == 15'd30000);
B_modulation B_modulation_inst (
.i_clk (i_clk )
,.i_rst (i_rst )
,.i_S_data_valid (r_S_data_valid )
,.i_S_data (w_S_data )
,.o_mod_data (w_mod_data )
,.o_mod_data_valid(w_mod_data_valid )
);
SNR_Calculate SNR_Calculate_inst(
.i_clk (i_clk )
,.i_rst (i_rst )
,.i_mod_data_valid (w_mod_data_valid )
,.i_mod_data (w_mod_data )
,.i_SNR_data (7'd100 )
,.o_cal_snr_valid (w_cal_snr_valid )
,.o_cal_snr_tx_data (w_cal_snr_tx_data )
,.o_cal_snr_dac_data(w_cal_snr_dac_data)
);
endmodule
|
|