REGION "MEDIA_RIGHT" "R102C92D" 13 75; # RIGHT is for PCSA/PCSC
LOCATE UGROUP "gen_PCSB.THE_MEDIA_PCSB/media_interface_group" REGION "MEDIA_LEFT";
+#LOCATE UGROUP "gen_PCSB.THE_MEDIA_PCSB/gen_control.3.gen_phaser.THE_PHASER/THE_PHASER_CORE/phaser_core_group" SITE "R113C61D"; # 181039
+#LOCATE UGROUP "gen_PCSB.THE_MEDIA_PCSB/gen_control.3.gen_phaser.THE_PHASER/THE_PHASER_CORE/phaser_core_group" SITE "R114C90D"; # 184235
+#LOCATE UGROUP "gen_PCSB.THE_MEDIA_PCSB/gen_control.3.gen_phaser.THE_PHASER/THE_PHASER_CORE/phaser_core_group" SITE "R107C74D"; # 191203
+LOCATE UGROUP "gen_PCSB.THE_MEDIA_PCSB/gen_control.3.gen_phaser.THE_PHASER/THE_PHASER_CORE/phaser_core_group" SITE "R111C77D"; #
+
BLOCK PATH FROM CELL THE_TDC/calibration_o*;
BLOCK PATH FROM CELL THE_CTS/TIME_REFERENCE_OUT TO CELL THE_TDC/ReferenceChannel/Channel200/SimAdderNo.FC/FF*;
BLOCK PATH FROM CELL THE_CTS/TIME_REFERENCE_OUT TO CELL THE_TDC/TheTriggerHandler/trg_in_r[0];
make_reset_by_gbe <= last_reset_via_gbe_long and not reset_via_gbe_long; -- pulse, 1 clock cycle
end process;
-- REMARK: this should be transfered to GbE part.
-
+-- BUG: for some reasons, some TRB3sc refuse to work with this reset. Links are not destroyed reliably,
+-- and strange things happen with WAP.
+
pll_calibration : entity work.pll_in125_out33
port map (
CLK => CLK_SUPPL_PCLK,
-- Clocks and reset
CLK_REF_FULL => clk_full_osc,
SYSCLK => clk_sys,
+ SAMPLE_CLK => CLK_SUPPL_PCLK,
RESET => reset_i, -- check
-- Media Interface TX/RX
MEDIA_MED2INT(0) => open,
DESTROY_LINK_IN(3) => destroy_link_i,
WAP_REQUESTED_IN => wap_requested_i,
RX_INDEX_OUT => rx_index_i,
+ DLM_RESULT_OUT(0*32+31 downto 0*32) => open,
+ DLM_RESULT_OUT(1*32+31 downto 1*32) => open,
+ DLM_RESULT_OUT(2*32+31 downto 2*32) => open,
+ DLM_RESULT_OUT(3*32+31 downto 3*32) => phaser_data,
--SFP Connection
SD_PRSNT_N_IN(0) => '1',
SD_LOS_IN(0) => '1',
STATE_OUT => tx_reset_state
);
- --------------------------------------------------------------------
- --------------------------------------------------------------------
- THE_PHASER: entity phaser
- port map(
- SAMPLE_CLK => CLK_SUPPL_PCLK,
- RESET => reset_i,
- SIGNAL_A_IN => word_sync_i,
- SIGNAL_B_IN => rx_index_i(3),
- LOW_CNT_OUT => open,
- HI_CNT_OUT => phaser_data(31 downto 16),
- UPDATE_OUT => phaser_update
- );
-
- THE_COARSE_COUNTER_PROC: process( clk_full_osc )
- begin
- if( rising_edge(clk_full_osc) ) then
- if( tx_dlm_i = '1' ) then
- coarse_counter <= (others => '0');
- else
- coarse_counter <= coarse_counter + 1;
- end if;
- if( rx_dlm_i = '1' ) then
- coarse_delay <= std_logic_vector(coarse_counter);
- end if;
- end if;
- end process THE_COARSE_COUNTER_PROC;
-
- phaser_data(15 downto 0) <= coarse_delay;
- --------------------------------------------------------------------
- --------------------------------------------------------------------
-
PCSSW <= "01001110"; --SFP2 on B3, AddOn on D1
-- just for testing