8 use IEEE.STD_LOGIC_UNSIGNED.
all;
9 use ieee.std_logic_1164.
all;
27 MISS_E_THR : in arr_ctr_31bit(num_thresholds-1 downto 0);
29 SUM_ET_THR : in arr_ctr_15bit(num_thresholds-1 downto 0);
31 XS_T2_A2 : in arr_ctr_31bit(num_thresholds-1 downto 0);
37 XS_B2 : in arr_ctr_15bit(num_thresholds-1 downto 0);
42 LOCAL_CABLE_OUT :
out (4*26-1
downto 0);
49 par_err : in (1 downto 0);
-- parity error (input module - 0, RTM - 1)
50 force : in T_SL;
-- force
52 ncs : in ;
--ports forwarded to the vme register instances
55 addr_vme : in (15 downto 0);
56 data_vme_in : in (15 downto 0);
57 data_vme_out : out (15 downto 0);
104 flavor : T_SLV2 := "
10";
-- JET/CPM/SUMET
109 clk :
in T_SL;
-- clock
110 reset :
in T_SL;
-- reset
149 if rising_edge(CLK) then
168 addr_vme => addr_vme,
169 data_vme_in => data_vme_in,
200 addr_vme => addr_vme,
201 data_vme_in => data_vme_in,
205 --SYSTEM_SUMMING_MODULE_INST : entity work.system_summing_module
208 -- ENERGY_CRATE => local_cable_to_system,
209 -- ENERGY_REMOTE => ENERGY_REMOTE,
210 -- CTP_CABLE_0 => ctp_cable_0_internal, -- CTP_CABLE_0,
211 -- CTP_CABLE_1 => ctp_cable_1_internal, -- CTP_CABLE_1,
212 -- MISS_THR => MISS_THR,
213 -- SUMET_THR => SUMET_THR,
215 -- XS_PARAM => XS_PARAM,
216 -- ov_all_out => ov_all_out,
217 -- sums_all_out => sums_all_out,
221 -- addr_vme => addr_vme,
222 -- data_vme_in => data_vme_in,
223 -- data_vme_out => data_vme_out_local(1),
224 -- bus_drive => bus_drive_local(1)
267 LOCAL_CABLE_OUT(
24 downto 0) <= local_cable_to_system(
24 downto 0);
268 LOCAL_CABLE_OUT(
50 downto 26) <= local_cable_to_system(
50 downto 26);
269 LOCAL_CABLE_OUT(
76 downto 52) <= local_cable_to_system(
76 downto 52);
270 LOCAL_CABLE_OUT(
102 downto 78) <= local_cable_to_system(
102 downto 78);
276 -- ------------------------------------------------------------------------------------
278 -- ------------------------------------------------------------------------------------
280 mult_2x16: for i in 0 to 7 generate
298 end generate mult_2x16;
300 -- ------------------------------------------------------------------------------------
302 -- ------------------------------------------------------------------------------------
324 VME_CNT_SUM_ET_COUNTER_i: for i in 0 to 15 generate
328 ia_vme => ADDR_REG_RO_SUM_ET_COUNTER+
(2*i
),
340 end generate VME_CNT_SUM_ET_COUNTER_i;
342 -- ------------------------------------------------------------------------------------
344 -- ------------------------------------------------------------------------------------
366 VME_CNT_MISSING_ET_COUNTER_i: for i in 0 to 15 generate
370 ia_vme => ADDR_REG_RO_MISSING_ET_COUNTER+
(2*i
),
382 end generate VME_CNT_MISSING_ET_COUNTER_i;
385 -- ------------------------------------------------------------------------------------
386 -- MISSING ET SIGNIFICANCE
387 -- ------------------------------------------------------------------------------------
407 VME_CNT_MISSING_ET_SIGN_COUNTER_i: for i in 0 to 15 generate
411 ia_vme => ADDR_REG_RO_MISSING_ET_SIGN_COUNTER+
(2*i
),
423 end generate VME_CNT_MISSING_ET_SIGN_COUNTER_i;
426 -- ------------------------------------------------------------------------------------
428 -- ------------------------------------------------------------------------------------
448 VME_CNT_SUM_ET_WEIGHTED_COUNTER_i: for i in 0 to 15 generate
452 ia_vme => ADDR_REG_RO_SUM_ET_WEIGHTED_COUNTER+
(2*i
),
465 end generate VME_CNT_SUM_ET_WEIGHTED_COUNTER_i;
467 -- ------------------------------------------------------------------------------------
468 -- MISSING ET RESTRCITED
469 -- ------------------------------------------------------------------------------------
489 VME_CNT_MISS_ET_RESCTRICTED_COUNTER_i: for i in 0 to 15 generate
493 ia_vme => ADDR_REG_RO_MISSING_ET_RES_COUNTER+
(2*i
),
506 end generate VME_CNT_MISS_ET_RESCTRICTED_COUNTER_i;
in BACKPLANE_DATA_INenergy_array
thresholds_numinteger :=25
cnt_mult_arr_2x16 (15 downto 0) cnt_missing_et_2x16
std_logic counter_inhibit_r_local
out sums_all_outarr_ctr_15bit (5 downto 0)
out data_vmestd_logic_vector (15 downto 0)
in BACKPLANE_DATA_INenergy_array
in T_SUM_E_MAXarr_ctr_15bit (num_thresholds - 1 downto 0)
cnt_mult_arr_2x16 (15 downto 0) cnt_sum_et_weighted_2x16
std_logic_vector (4 * 26 - 1 downto 0) local_cable_to_system)
in MISS_E_RES_THRarr_ctr_31bit (num_thresholds - 1 downto 0)
out sums_all_outarr_ctr_15bit (5 downto 0)
in T_MISS_E_MAXarr_ctr_31bit (num_thresholds - 1 downto 0)
arr_16 (1 + (16 * 5) downto 0) data_vme_out_local)
in data_vme_from_belowarr_16
--! inputs from local registers and from
cnt_mult_arr (7 downto 0) cnt_missing_et_sign
std_logic_vector (23 downto 0) ctp_cable_1_internal
out LOCAL_CABLE_OUTstd_logic_vector (4 * 26 - 1 downto 0)
in datastd_logic_vector (width - 1 downto 0)
in SUM_ET_RES_THRarr_ctr_15bit (num_thresholds - 1 downto 0)
in ENERGY_REMOTEstd_logic_vector (26 * 4 - 1 downto 0)
out BCID_delayedstd_logic_vector (11 downto 0)
in T_MISS_E_MINarr_ctr_31bit (num_thresholds - 1 downto 0)
in T_SUM_E_MAXarr_ctr_15bit (num_thresholds - 1 downto 0)
in XS_T2_A2arr_ctr_31bit (num_thresholds - 1 downto 0)
in T_MISS_E_MAXarr_ctr_31bit (num_thresholds - 1 downto 0)
in BCID_instd_logic_vector (11 downto 0)
in T_SUM_E_MINarr_ctr_15bit (num_thresholds - 1 downto 0)
cnt_mult_arr (7 downto 0) cnt_missing_et_res
out CTP_CABLE_1std_logic_vector (23 downto 0)
out LOCAL_CABLE_OUTstd_logic_vector (26 * 4 - 1 downto 0)
in ENERGY_CRATEstd_logic_vector (26 * 4 - 1 downto 0)
out data_vme_upstd_logic_vector (15 downto 0)
--! connect this to
in T_MISS_E_MINarr_ctr_31bit (num_thresholds - 1 downto 0)
out ov_all_outstd_logic_vector (5 downto 0)
in SUM_ET_RES_THRarr_ctr_15bit (num_thresholds - 1 downto 0)
in addr_vmestd_logic_vector (15 downto 0)
cnt_mult_arr (7 downto 0) cnt_missing_et
out BCID_delayedstd_logic_vector (11 downto 0)
cnt_mult_arr_2x16 (15 downto 0) cnt_missing_et_res_2x16
in SUM_ET_THRarr_ctr_15bit (num_thresholds - 1 downto 0)
std_logic_vector (1 + (16 * 5) downto 0) bus_drive_local)
in par_errstd_logic_vector (1 downto 0)
in SUM_ET_THRarr_ctr_15bit (num_thresholds - 1 downto 0)
out bus_drive_upstd_logic
or of all bus drive requests from below
in XS_B2arr_ctr_15bit (num_thresholds - 1 downto 0)
out cnt_arrcnt_mult_arr (thresholds_num - 1 downto 0)
cnt_mult_arr (7 downto 0) cnt_sum_et_weighted
cnt_mult_arr_2x16 (15 downto 0) cnt_sum_et_2x16
std_logic_vector (23 downto 0) ctp_cable_0_internal
in MISS_E_THRarr_ctr_31bit (num_thresholds - 1 downto 0)
cnt_mult_arr_2x16 (15 downto 0) cnt_missing_et_sign_2x16
in XS_B2arr_ctr_15bit (num_thresholds - 1 downto 0)
in MISS_E_THRarr_ctr_31bit (num_thresholds - 1 downto 0)
in T_SUM_E_MINarr_ctr_15bit (num_thresholds - 1 downto 0)
in MISS_E_RES_THRarr_ctr_31bit (num_thresholds - 1 downto 0)
cnt_mult_arr (7 downto 0) cnt_sum_et
in dinstd_logic_vector (width - 1 downto 0)
in XS_T2_A2arr_ctr_31bit (num_thresholds - 1 downto 0)
out ov_all_outstd_logic_vector (5 downto 0)
out CTP_CABLE_1std_logic_vector (23 downto 0)
in data_to_vmestd_logic_vector (width - 1 downto 0)
in BCID_instd_logic_vector (11 downto 0)
in ENERGY_REMOTEstd_logic_vector (26 * 4 - 1 downto 0)
in bus_drive_from_belowstd_logic_vector
out CTP_CABLE_0std_logic_vector (23 downto 0)
out CTP_CABLE_0std_logic_vector (23 downto 0)
std_logic counter_reset_r_local