From e08d82facf25d45c2647f613167eaef4f39528ca Mon Sep 17 00:00:00 2001 From: Jan Michel Date: Thu, 23 Aug 2018 16:36:43 +0200 Subject: [PATCH] Add hardware ID to TDC header. Remove unnecessary no-hit-detection --- releases/tdc_v2.3/Readout_record.vhd | 29 ++++++++++++++-------------- 1 file changed, 15 insertions(+), 14 deletions(-) diff --git a/releases/tdc_v2.3/Readout_record.vhd b/releases/tdc_v2.3/Readout_record.vhd index a5666af..b7bfaab 100644 --- a/releases/tdc_v2.3/Readout_record.vhd +++ b/releases/tdc_v2.3/Readout_record.vhd @@ -688,8 +688,9 @@ begin -- behavioral -- Error, warning bits set in the header header_error_bits(0) <= or_all(CH_ALMOST_FULL_IN); - header_error_bits(15 downto 1) <= (others => '0'); - + header_error_bits(7 downto 1) <= (others => '0'); + header_error_bits(15 downto 8) <= HARDWARE_INFO(31 downto 24); + -- Error, warning bits set in the trailer trailer_error_bits(0) <= missing_ref_time; -- info from the triggerhandler trailer_error_bits(1) <= READOUT_RX.trg_spurious; -- if there is a wrong readout because of a spurious timing trigger @@ -724,20 +725,20 @@ begin -- behavioral -- any_hit <= or_all(hit_in_i); - CheckHitStatus : process (CLK_100) is - begin - if rising_edge(CLK_100) then -- rising clock edge - if LIGHT_MODE_IN = '0' or TRG_WIN_EN_IN = '1' then +-- CheckHitStatus : process (CLK_100) is +-- begin +-- if rising_edge(CLK_100) then -- rising clock edge +-- if LIGHT_MODE_IN = '0' or TRG_WIN_EN_IN = '1' then isNoHit <= '0'; isNoHit_r <= '0'; - elsif READOUT_RX.valid_timing_trg = '1' then - isNoHit <= '1'; - isNoHit_r <= isNoHit; - elsif or_all(hit_in_i) = '1' then - isNoHit <= '0'; - end if; - end if; - end process CheckHitStatus; +-- elsif READOUT_RX.valid_timing_trg = '1' then +-- isNoHit <= '1'; +-- isNoHit_r <= isNoHit; +-- elsif or_all(hit_in_i) = '1' then +-- isNoHit <= '0'; +-- end if; +-- end if; +-- end process CheckHitStatus; ------------------------------------------------------------------------------- -- Debug and statistics words ------------------------------------------------------------------------------- -- 2.43.0