diff --git a/scripts/filesets/gbt_toplevel_fileset.tcl b/scripts/filesets/gbt_toplevel_fileset.tcl index 7baf0d7ca4e2509264d1c56d2a8d98062ba53bea..f06d5eaf233f5f9e9a2cad76fb363af7d2069c36 100644 --- a/scripts/filesets/gbt_toplevel_fileset.tcl +++ b/scripts/filesets/gbt_toplevel_fileset.tcl @@ -39,14 +39,12 @@ set XDC_FILES_HTG710 [concat $XDC_FILES_HTG710 \ set XDC_FILES_BNL711 [concat $XDC_FILES_BNL711 \ felix_top_BNL711_v1.5.xdc \ felix_gbt_minipod_BNL711_transceiver_8ch.xdc \ - felix_gbt_minipod_BNL711_transceiver_16ch.xdc \ felix_gbt_minipod_BNL711_transceiver_24ch.xdc \ timing_constraints.xdc] set XDC_FILES_BNL712 [concat $XDC_FILES_BNL712 \ felix_top_BNL711_v2.0.xdc \ felix_gbt_minipod_BNL711_transceiver_8ch.xdc \ - felix_gbt_minipod_BNL711_transceiver_16ch.xdc \ felix_gbt_minipod_BNL711_transceiver_24ch.xdc \ felix_gbt_minipod_BNL711_v2.0_transceiver_48ch.xdc \ timing_constraints.xdc] diff --git a/scripts/filesets/lpgbt_toplevel_fileset.tcl b/scripts/filesets/lpgbt_toplevel_fileset.tcl index 16f3649dc739c74fa59fd453ac0b7da35ea1b9a5..b45ba6fdbc0c5bcadefddc40e0f91be4df3fe853 100644 --- a/scripts/filesets/lpgbt_toplevel_fileset.tcl +++ b/scripts/filesets/lpgbt_toplevel_fileset.tcl @@ -41,7 +41,6 @@ set XDC_FILES_BNL711 [concat $XDC_FILES_BNL711 \ felix_top_BNL711_v1.5.xdc \ felix_gbt_minipod_BNL711.xdc \ felix_gbt_minipod_BNL711_transceiver_8ch.xdc \ - felix_gbt_minipod_BNL711_transceiver_16ch.xdc \ felix_gbt_minipod_BNL711_transceiver_24ch.xdc \ timing_constraints.xdc \ pblocks_KCU_BNL711_v1.5.xdc \ @@ -51,7 +50,6 @@ set XDC_FILES_BNL712 [concat $XDC_FILES_BNL712 \ felix_top_BNL711_v2.0_lpgbt.xdc \ felix_gbt_minipod_BNL711_lpgbt.xdc \ felix_gbt_minipod_BNL711_transceiver_8ch.xdc \ - felix_gbt_minipod_BNL711_transceiver_16ch.xdc \ felix_gbt_minipod_BNL711_transceiver_24ch.xdc \ felix_gbt_minipod_BNL711_v2.0_transceiver_48ch.xdc \ timing_constraints.xdc \ diff --git a/scripts/helper/do_implementation_post.tcl b/scripts/helper/do_implementation_post.tcl index 5ef81003b9fd1c27f7eda7f5bcf65458d829f169..cf8d847acb4566907a95f6fc9e4a8ab238275758 100644 --- a/scripts/helper/do_implementation_post.tcl +++ b/scripts/helper/do_implementation_post.tcl @@ -187,59 +187,36 @@ if {($FIRMWARE_MODE == $FIRMWARE_MODE_GBT|| \ $FIRMWARE_MODE == $FIRMWARE_MODE_STRIP|| \ $FIRMWARE_MODE == $FIRMWARE_MODE_LPGBT) \ && ($CARD_TYPE == 712) } { - if {$GBT_NUM <= 16 && $FE_EMU_EN == 0} { - if {$GBT_NUM > 8} { - set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_8ch.xdc] - set_property is_enabled true [get_files felix_gbt_minipod_BNL711_transceiver_16ch.xdc] - set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_24ch.xdc] - } else { - set_property is_enabled true [get_files felix_gbt_minipod_BNL711_transceiver_8ch.xdc] - set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_16ch.xdc] - set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_24ch.xdc] - } + if {$GBT_NUM <= 8 && $FE_EMU_EN == 0} { + set_property is_enabled true [get_files felix_gbt_minipod_BNL711_transceiver_8ch.xdc] + set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_24ch.xdc] } else { set_property is_enabled true [get_files felix_gbt_minipod_BNL711_transceiver_24ch.xdc] - set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_16ch.xdc] set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_8ch.xdc] } if {$GBT_NUM > 24 || ($FE_EMU_EN > 0 && $GBT_NUM > 12)} { set_property is_enabled true [get_files felix_gbt_minipod_BNL711_v2.0_transceiver_48ch.xdc] set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_8ch.xdc] - set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_16ch.xdc] set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_24ch.xdc] } else { set_property is_enabled false [get_files felix_gbt_minipod_BNL711_v2.0_transceiver_48ch.xdc] } } -### if {($FIRMWARE_MODE == $FIRMWARE_MODE_FULL) \ -### && ($CARD_TYPE == 712) } { -### set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_8ch.xdc] -### set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_16ch.xdc] -### set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_24ch.xdc] -### set_property is_enabled false [get_files felix_gbt_minipod_BNL711_v2.0_transceiver_48ch.xdc] -### # ToDo: # import and enable felix_gbt_minipod_FM_BNL711_v1.5_transceiver_12ch.xdc -### } if {($FIRMWARE_MODE == $FIRMWARE_MODE_GBT||\ + $FIRMWARE_MODE == $FIRMWARE_MODE_FULL|| \ $FIRMWARE_MODE == $FIRMWARE_MODE_LTDB||\ $FIRMWARE_MODE == $FIRMWARE_MODE_FEI4|| \ + $FIRMWARE_MODE == $FIRMWARE_MODE_PIXEL|| \ $FIRMWARE_MODE == $FIRMWARE_MODE_STRIP||\ $FIRMWARE_MODE == $FIRMWARE_MODE_LPGBT) &&\ ($CARD_TYPE == 711) } { - if {$GBT_NUM <= 16} { - if {$GBT_NUM > 8} { - set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_8ch.xdc] - set_property is_enabled true [get_files felix_gbt_minipod_BNL711_transceiver_16ch.xdc] - set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_24ch.xdc] - } else { - set_property is_enabled true [get_files felix_gbt_minipod_BNL711_transceiver_8ch.xdc] - set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_16ch.xdc] - set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_24ch.xdc] - } + if {$GBT_NUM <= 8} { + set_property is_enabled true [get_files felix_gbt_minipod_BNL711_transceiver_8ch.xdc] + set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_24ch.xdc] } else { set_property is_enabled true [get_files felix_gbt_minipod_BNL711_transceiver_24ch.xdc] - set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_16ch.xdc] set_property is_enabled false [get_files felix_gbt_minipod_BNL711_transceiver_8ch.xdc] } } diff --git a/sources/FullModeWrapper/FELIX_FM_gbt_wrapper.vhd b/sources/FullModeWrapper/FELIX_FM_gbt_wrapper.vhd index f90cac0203b07f9fa434b0897fe6b3cddf5baf33..b20f3526d051507127d7e48832db3a17f1786328 100644 --- a/sources/FullModeWrapper/FELIX_FM_gbt_wrapper.vhd +++ b/sources/FullModeWrapper/FELIX_FM_gbt_wrapper.vhd @@ -278,7 +278,7 @@ g_709a: if CARD_TYPE = 709 or CARD_TYPE = 710 generate ); end generate; g_709or712b: if CARD_TYPE = 709 or CARD_TYPE = 710 or CARD_TYPE = 711 or CARD_TYPE = 712 generate - g_GBTNUM24: if GBT_NUM > 12 and GBT_NUM <= 24 generate + g_GBTNUM24: if GBT_NUM > 8 and GBT_NUM <= 24 generate GTH_RefClk(0) <= CXP1_GTH_RefClk; GTH_RefClk(1) <= CXP1_GTH_RefClk; GTH_RefClk(2) <= CXP1_GTH_RefClk; @@ -305,21 +305,7 @@ g_709a: if CARD_TYPE = 709 or CARD_TYPE = 710 generate GTH_RefClk(22) <= CXP2_GTH_RefClk; GTH_RefClk(23) <= CXP2_GTH_RefClk; end generate; - g_GBTNUM12: if GBT_NUM > 8 and GBT_NUM <= 12 generate - GTH_RefClk(0) <= CXP1_GTH_RefClk; - GTH_RefClk(1) <= CXP1_GTH_RefClk; - GTH_RefClk(2) <= CXP1_GTH_RefClk; - GTH_RefClk(3) <= CXP1_GTH_RefClk; - GTH_RefClk(4) <= CXP1_GTH_RefClk; - GTH_RefClk(5) <= CXP1_GTH_RefClk; - GTH_RefClk(6) <= CXP1_GTH_RefClk; - GTH_RefClk(7) <= CXP1_GTH_RefClk; - - GTH_RefClk(8) <= CXP2_GTH_RefClk; - GTH_RefClk(9) <= CXP2_GTH_RefClk; - GTH_RefClk(10) <= CXP2_GTH_RefClk; - GTH_RefClk(11) <= CXP2_GTH_RefClk; - end generate; + g_GBTNUM8: if GBT_NUM <= 8 generate GTH_RefClk(0) <= CXP1_GTH_RefClk; GTH_RefClk(1) <= CXP1_GTH_RefClk; diff --git a/sources/GBT/gbt_code/FELIX_gbt_wrapper_KCU.vhd b/sources/GBT/gbt_code/FELIX_gbt_wrapper_KCU.vhd index 6b9f16b937df9871c5dc139b1af44c85adce1504..88b83ba81c8edd736d6b371849e5ae6d8d06e236 100644 --- a/sources/GBT/gbt_code/FELIX_gbt_wrapper_KCU.vhd +++ b/sources/GBT/gbt_code/FELIX_gbt_wrapper_KCU.vhd @@ -473,27 +473,27 @@ begin GTH_RefClk( 7) <= CXP2_GTH_RefClk;--bank 133 (up to 8 channels) end generate g_refclk_8ch; - g_refclk_16ch: if ((8 < GBT_NUM) and (GBT_NUM <= 16)) generate - GTH_RefClk( 0) <= CXP1_GTH_RefClk;--bank 128 (up to 8 channels) - GTH_RefClk( 1) <= CXP1_GTH_RefClk;--bank 128 (up to 8 channels) - GTH_RefClk( 2) <= CXP1_GTH_RefClk;--bank 128 (up to 8 channels) - GTH_RefClk( 3) <= CXP1_GTH_RefClk;--bank 128 (up to 8 channels) - GTH_RefClk( 4) <= CXP1_GTH_RefClk;--bank 127 (up to 16 channels) - GTH_RefClk( 5) <= CXP1_GTH_RefClk;--bank 127 (up to 16 channels) - GTH_RefClk( 6) <= CXP1_GTH_RefClk;--bank 127 (up to 16 channels) - GTH_RefClk( 7) <= CXP1_GTH_RefClk;--bank 127 (up to 16 channels) - - GTH_RefClk( 8) <= CXP2_GTH_RefClk;--bank 133 (up to 8 channels) - GTH_RefClk( 9) <= CXP2_GTH_RefClk;--bank 133 (up to 8 channels) - GTH_RefClk(10) <= CXP2_GTH_RefClk;--bank 133 (up to 8 channels) - GTH_RefClk(11) <= CXP2_GTH_RefClk;--bank 133 (up to 8 channels) - GTH_RefClk(12) <= CXP2_GTH_RefClk;--bank 132 (up to 16 channels) - GTH_RefClk(13) <= CXP2_GTH_RefClk;--bank 132 (up to 16 channels) - GTH_RefClk(14) <= CXP2_GTH_RefClk;--bank 132 (up to 16 channels) - GTH_RefClk(15) <= CXP2_GTH_RefClk;--bank 132 (up to 16 channels) - end generate g_refclk_16ch; - - g_refclk_24ch: if ((16 < GBT_NUM) and (GBT_NUM <= 24)) generate + --g_refclk_16ch: if ((8 < GBT_NUM) and (GBT_NUM <= 16)) generate + -- GTH_RefClk( 0) <= CXP1_GTH_RefClk;--bank 128 (up to 8 channels) + -- GTH_RefClk( 1) <= CXP1_GTH_RefClk;--bank 128 (up to 8 channels) + -- GTH_RefClk( 2) <= CXP1_GTH_RefClk;--bank 128 (up to 8 channels) + -- GTH_RefClk( 3) <= CXP1_GTH_RefClk;--bank 128 (up to 8 channels) + -- GTH_RefClk( 4) <= CXP1_GTH_RefClk;--bank 127 (up to 16 channels) + -- GTH_RefClk( 5) <= CXP1_GTH_RefClk;--bank 127 (up to 16 channels) + -- GTH_RefClk( 6) <= CXP1_GTH_RefClk;--bank 127 (up to 16 channels) + -- GTH_RefClk( 7) <= CXP1_GTH_RefClk;--bank 127 (up to 16 channels) + -- + -- GTH_RefClk( 8) <= CXP2_GTH_RefClk;--bank 133 (up to 8 channels) + -- GTH_RefClk( 9) <= CXP2_GTH_RefClk;--bank 133 (up to 8 channels) + -- GTH_RefClk(10) <= CXP2_GTH_RefClk;--bank 133 (up to 8 channels) + -- GTH_RefClk(11) <= CXP2_GTH_RefClk;--bank 133 (up to 8 channels) + -- GTH_RefClk(12) <= CXP2_GTH_RefClk;--bank 132 (up to 16 channels) + -- GTH_RefClk(13) <= CXP2_GTH_RefClk;--bank 132 (up to 16 channels) + -- GTH_RefClk(14) <= CXP2_GTH_RefClk;--bank 132 (up to 16 channels) + -- GTH_RefClk(15) <= CXP2_GTH_RefClk;--bank 132 (up to 16 channels) + --end generate g_refclk_16ch; + + g_refclk_24ch: if ((8 < GBT_NUM) and (GBT_NUM <= 24)) generate GTH_RefClk( 0) <= CXP1_GTH_RefClk;--bank 128 (up to 8 channels) GTH_RefClk( 1) <= CXP1_GTH_RefClk;--bank 128 (up to 8 channels) GTH_RefClk( 2) <= CXP1_GTH_RefClk;--bank 128 (up to 8 channels) diff --git a/sources/LpGBT/LpGBT_FELIX/RefClk_Gen.vhd b/sources/LpGBT/LpGBT_FELIX/RefClk_Gen.vhd index d699cd5a704ef6f20b297f6c304b6b5158f6d0e7..29e67ebcd6a4e5823bec715469b738a26cc41909 100644 --- a/sources/LpGBT/LpGBT_FELIX/RefClk_Gen.vhd +++ b/sources/LpGBT/LpGBT_FELIX/RefClk_Gen.vhd @@ -384,8 +384,8 @@ g_refclk_48ch_sel2: if ((12 < GBT_NUM) and (GBT_NUM <= 24) and (FE_EMU_EN = 1) a GTH_EMU_REFCLK_OUT(GBT_NUM-1 downto 0) <= GTH_RefClk(GBT_NUM+23 downto 24); end generate; -g_refclk_24ch: if ( ( (12 < GBT_NUM) and (GBT_NUM <= 24) and (FE_EMU_EN = 0) and (CLK_CHIP_SEL = 1) ) -or ((6 < GBT_NUM) and (GBT_NUM <= 12) and (FE_EMU_EN = 1) and (CLK_CHIP_SEL = 1))) generate +g_refclk_24ch: if ( ( (8 < GBT_NUM) and (GBT_NUM <= 24) and (FE_EMU_EN = 0) and (CLK_CHIP_SEL = 1) ) +or ((4< GBT_NUM) and (GBT_NUM <= 12) and (FE_EMU_EN = 1) and (CLK_CHIP_SEL = 1))) generate GTH_RefClk( 0) <= LMK1_REFCLK; GTH_RefClk( 1) <= LMK1_REFCLK; @@ -414,28 +414,28 @@ or ((6 < GBT_NUM) and (GBT_NUM <= 12) and (FE_EMU_EN = 1) and (CLK_CHIP_SEL = 1) GTH_RefClk(23) <= LMK2_REFCLK; end generate g_refclk_24ch; -g_refclk_24ch_sel2: if ((6 < GBT_NUM) and (GBT_NUM <= 12) and (FE_EMU_EN = 1) and (CLK_CHIP_SEL = 1)) generate +g_refclk_24ch_sel2: if ((4 < GBT_NUM) and (GBT_NUM <= 12) and (FE_EMU_EN = 1) and (CLK_CHIP_SEL = 1)) generate GTH_REFCLK_OUT(GBT_NUM-1 downto 0) <= GTH_RefClk(GBT_NUM-1 downto 0); GTH_EMU_REFCLK_OUT(GBT_NUM-1 downto 0) <= GTH_RefClk(GBT_NUM+11 downto 12); end generate; -g_refclk_12ch: if ( (8 < GBT_NUM) and (GBT_NUM <= 12) and (FE_EMU_EN = 0) and (CLK_CHIP_SEL = 1) ) generate - - GTH_RefClk( 0) <= LMK1_REFCLK; - GTH_RefClk( 1) <= LMK1_REFCLK; - GTH_RefClk( 2) <= LMK1_REFCLK; - GTH_RefClk( 3) <= LMK1_REFCLK; - GTH_RefClk( 4) <= LMK1_REFCLK; - GTH_RefClk( 5) <= LMK1_REFCLK; - GTH_RefClk( 6) <= LMK1_REFCLK; - GTH_RefClk( 7) <= LMK1_REFCLK; - - GTH_RefClk( 8) <= LMK3_REFCLK; - GTH_RefClk( 9) <= LMK3_REFCLK; - GTH_RefClk(10) <= LMK3_REFCLK; - GTH_RefClk(11) <= LMK3_REFCLK; - -end generate g_refclk_12ch; +--g_refclk_12ch: if ( (8 < GBT_NUM) and (GBT_NUM <= 12) and (FE_EMU_EN = 0) and (CLK_CHIP_SEL = 1) ) generate +-- +-- GTH_RefClk( 0) <= LMK1_REFCLK; +-- GTH_RefClk( 1) <= LMK1_REFCLK; +-- GTH_RefClk( 2) <= LMK1_REFCLK; +-- GTH_RefClk( 3) <= LMK1_REFCLK; +-- GTH_RefClk( 4) <= LMK1_REFCLK; +-- GTH_RefClk( 5) <= LMK1_REFCLK; +-- GTH_RefClk( 6) <= LMK1_REFCLK; +-- GTH_RefClk( 7) <= LMK1_REFCLK; +-- +-- GTH_RefClk( 8) <= LMK3_REFCLK; +-- GTH_RefClk( 9) <= LMK3_REFCLK; +-- GTH_RefClk(10) <= LMK3_REFCLK; +-- GTH_RefClk(11) <= LMK3_REFCLK; +-- +--end generate g_refclk_12ch; g_refclk_8ch: if ( (GBT_NUM <= 8) and (FE_EMU_EN = 0) and (CLK_CHIP_SEL = 1) ) generate @@ -515,8 +515,8 @@ g_refclk_48ch_SI_sel2: if ((12 < GBT_NUM) and (GBT_NUM <= 24) and (FE_EMU_EN = 1 GTH_EMU_REFCLK_OUT(GBT_NUM-1 downto 0) <= GTH_RefClk(GBT_NUM+23 downto 24); end generate; -g_refclk_24ch_SI: if ((12 < GBT_NUM) and (GBT_NUM <= 24) and (FE_EMU_EN = 0) and (CLK_CHIP_SEL = 0)) -or ((6 < GBT_NUM) and (GBT_NUM <= 12) and (FE_EMU_EN = 1) and (CLK_CHIP_SEL = 0))generate +g_refclk_24ch_SI: if ((8 < GBT_NUM) and (GBT_NUM <= 24) and (FE_EMU_EN = 0) and (CLK_CHIP_SEL = 0)) +or ((4 < GBT_NUM) and (GBT_NUM <= 12) and (FE_EMU_EN = 1) and (CLK_CHIP_SEL = 0))generate GTH_RefClk( 0) <= SI0_REFCLK; GTH_RefClk( 1) <= SI0_REFCLK; @@ -545,28 +545,28 @@ or ((6 < GBT_NUM) and (GBT_NUM <= 12) and (FE_EMU_EN = 1) and (CLK_CHIP_SEL = 0) GTH_RefClk(23) <= SI2_REFCLK; end generate g_refclk_24ch_SI; -g_refclk_24ch_SI_sel2: if ((6 < GBT_NUM) and (GBT_NUM <= 12) and (FE_EMU_EN = 1) and (CLK_CHIP_SEL = 0)) generate +g_refclk_24ch_SI_sel2: if ((4 < GBT_NUM) and (GBT_NUM <= 12) and (FE_EMU_EN = 1) and (CLK_CHIP_SEL = 0)) generate GTH_REFCLK_OUT(GBT_NUM-1 downto 0) <= GTH_RefClk(GBT_NUM-1 downto 0); GTH_EMU_REFCLK_OUT(GBT_NUM-1 downto 0) <= GTH_RefClk(GBT_NUM+11 downto 12); end generate; -g_refclk_12ch_SI: if ( (8 < GBT_NUM) and (GBT_NUM <= 12) and (FE_EMU_EN = 0) and (CLK_CHIP_SEL = 0)) generate - - GTH_RefClk( 0) <= SI0_REFCLK; - GTH_RefClk( 1) <= SI0_REFCLK; - GTH_RefClk( 2) <= SI0_REFCLK; - GTH_RefClk( 3) <= SI0_REFCLK; - GTH_RefClk( 4) <= SI0_REFCLK; - GTH_RefClk( 5) <= SI0_REFCLK; - GTH_RefClk( 6) <= SI0_REFCLK; - GTH_RefClk( 7) <= SI0_REFCLK; - GTH_RefClk( 8) <= SI2_REFCLK; - GTH_RefClk( 9) <= SI2_REFCLK; - GTH_RefClk(10) <= SI2_REFCLK; - GTH_RefClk(11) <= SI2_REFCLK; - -end generate g_refclk_12ch_SI; +--g_refclk_12ch_SI: if ( (8 < GBT_NUM) and (GBT_NUM <= 12) and (FE_EMU_EN = 0) and (CLK_CHIP_SEL = 0)) generate +-- +-- GTH_RefClk( 0) <= SI0_REFCLK; +-- GTH_RefClk( 1) <= SI0_REFCLK; +-- GTH_RefClk( 2) <= SI0_REFCLK; +-- GTH_RefClk( 3) <= SI0_REFCLK; +-- GTH_RefClk( 4) <= SI0_REFCLK; +-- GTH_RefClk( 5) <= SI0_REFCLK; +-- GTH_RefClk( 6) <= SI0_REFCLK; +-- GTH_RefClk( 7) <= SI0_REFCLK; +-- GTH_RefClk( 8) <= SI2_REFCLK; +-- GTH_RefClk( 9) <= SI2_REFCLK; +-- GTH_RefClk(10) <= SI2_REFCLK; +-- GTH_RefClk(11) <= SI2_REFCLK; +-- +--end generate g_refclk_12ch_SI; g_refclk_8ch_SI: if ( (GBT_NUM <= 8) and (FE_EMU_EN = 0) and (CLK_CHIP_SEL = 0)) generate