adrv9001/zed: Add TDD support

main
Laszlo Nagy 2020-08-24 11:35:58 +01:00 committed by Laszlo Nagy
parent 0c2745361b
commit 18b2a8b0a7
1 changed files with 38 additions and 14 deletions

View File

@ -111,7 +111,7 @@ module system_top (
input rx1_dclk_in_n,
input rx1_dclk_in_p,
inout rx1_enable,
output rx1_enable,
input rx1_idata_in_n,
input rx1_idata_in_p,
input rx1_qdata_in_n,
@ -121,7 +121,7 @@ module system_top (
input rx2_dclk_in_n,
input rx2_dclk_in_p,
inout rx2_enable,
output rx2_enable,
input rx2_idata_in_n,
input rx2_idata_in_p,
input rx2_qdata_in_n,
@ -133,7 +133,7 @@ module system_top (
output tx1_dclk_out_p,
input tx1_dclk_in_n,
input tx1_dclk_in_p,
inout tx1_enable,
output tx1_enable,
output tx1_idata_out_n,
output tx1_idata_out_p,
output tx1_qdata_out_n,
@ -145,7 +145,7 @@ module system_top (
output tx2_dclk_out_p,
input tx2_dclk_in_n,
input tx2_dclk_in_p,
inout tx2_enable,
output tx2_enable,
output tx2_idata_out_n,
output tx2_idata_out_p,
output tx2_qdata_out_n,
@ -165,6 +165,10 @@ module system_top (
wire [63:0] gpio_i;
wire [63:0] gpio_o;
wire [63:0] gpio_t;
wire gpio_rx1_enable_in;
wire gpio_rx2_enable_in;
wire gpio_tx1_enable_in;
wire gpio_tx2_enable_in;
wire [ 1:0] iic_mux_scl_i_s;
wire [ 1:0] iic_mux_scl_o_s;
wire iic_mux_scl_t_s;
@ -174,6 +178,10 @@ module system_top (
wire spi_clk_s;
wire spi_en_s;
wire spi_dio_s;
wire rx1_enable_s;
wire rx2_enable_s;
wire tx1_enable_s;
wire tx2_enable_s;
// instantiations
@ -191,15 +199,11 @@ module system_top (
.dio_o(gpio_i[31:0]),
.dio_p(gpio_bd));
ad_iobuf #(.DATA_WIDTH(20)) i_iobuf (
.dio_t (vadj_err ? {20{1'b1}} : gpio_t[51:32]),
.dio_i ({gpio_o[51:32]}),
.dio_o ({gpio_i[51:32]}),
.dio_p ({tx2_enable, // 51
tx1_enable, // 50
rx2_enable, // 49
rx1_enable, // 48
sm_fan_tach, // 47
ad_iobuf #(.DATA_WIDTH(16)) i_iobuf (
.dio_t (vadj_err ? {16{1'b1}} : gpio_t[47:32]),
.dio_i ({gpio_o[47:32]}),
.dio_o ({gpio_i[47:32]}),
.dio_p ({sm_fan_tach, // 47
reset_trx, // 46
mode, // 45
gp_int, // 44
@ -216,7 +220,12 @@ module system_top (
dgpio_1, // 33
dgpio_0 })); // 32
assign gpio_i[54:52] = gpio_o[54:52];
assign gpio_rx1_enable_in = gpio_o[48];
assign gpio_rx2_enable_in = gpio_o[49];
assign gpio_tx1_enable_in = gpio_o[50];
assign gpio_tx2_enable_in = gpio_o[51];
assign gpio_i[54:48] = gpio_o[54:48];
assign gpio_i[55] = vadj_err;
assign gpio_i[63:56] = gpio_o[63:56];
@ -323,6 +332,16 @@ module system_top (
.tx2_strobe_out_n (tx2_strobe_out_n),
.tx2_strobe_out_p (tx2_strobe_out_p),
.rx1_enable (rx1_enable_s),
.rx2_enable (rx2_enable_s),
.tx1_enable (tx1_enable_s),
.tx2_enable (tx2_enable_s),
.gpio_rx1_enable_in (gpio_rx1_enable_in),
.gpio_rx2_enable_in (gpio_rx2_enable_in),
.gpio_tx1_enable_in (gpio_tx1_enable_in),
.gpio_tx2_enable_in (gpio_tx2_enable_in),
.spi0_clk_i (1'b0),
.spi0_clk_o (spi_clk_s),
.spi0_csn_0_o (spi_en_s),
@ -347,6 +366,11 @@ module system_top (
assign spi_en = vadj_err ? 1'bz : spi_en_s;
assign spi_dio = vadj_err ? 1'bz : spi_dio_s;
assign rx1_enable = vadj_err ? 1'bz : rx1_enable_s;
assign rx2_enable = vadj_err ? 1'bz : rx2_enable_s;
assign tx1_enable = vadj_err ? 1'bz : tx1_enable_s;
assign tx2_enable = vadj_err ? 1'bz : tx2_enable_s;
endmodule
// ***************************************************************************