Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2023-03-17 11:00:13

0001 #ifndef EventFilter_RPCRawToDigi_RPCAMCLinkEvents_h
0002 #define EventFilter_RPCRawToDigi_RPCAMCLinkEvents_h
0003 
0004 #include <string>
0005 
0006 #include "EventFilter/RPCRawToDigi/interface/RPCAMCLinkEvent.h"
0007 
0008 class RPCAMCLinkEvents {
0009 public:
0010   // from FED CDF Header and Trailer
0011   static unsigned int const fed_event_ = RPCAMCLinkEvent::fed_ | RPCAMCLinkEvent::debug_ | 0;
0012   static unsigned int const fed_header_check_fail_ = RPCAMCLinkEvent::fed_ | RPCAMCLinkEvent::warn_ | 1;
0013   static unsigned int const fed_header_id_mismatch_ = RPCAMCLinkEvent::fed_ | RPCAMCLinkEvent::warn_ | 2;
0014   static unsigned int const fed_trailer_check_fail_ = RPCAMCLinkEvent::fed_ | RPCAMCLinkEvent::warn_ | 3;
0015   static unsigned int const fed_trailer_length_mismatch_ = RPCAMCLinkEvent::fed_ | RPCAMCLinkEvent::warn_ | 4;
0016   static unsigned int const fed_trailer_crc_mismatch_ = RPCAMCLinkEvent::fed_ | RPCAMCLinkEvent::warn_ | 5;
0017   // from AMC13 Header
0018   static unsigned int const fed_amc13_block_incomplete_ = RPCAMCLinkEvent::fed_ | RPCAMCLinkEvent::warn_ | 6;
0019   // from AMC13 AMC Header
0020   static unsigned int const fed_amc13_amc_number_invalid_ = RPCAMCLinkEvent::fed_ | RPCAMCLinkEvent::warn_ | 7;
0021   static unsigned int const amc_amc13_block_incomplete_ = RPCAMCLinkEvent::amc_ | RPCAMCLinkEvent::warn_ | 1;
0022 
0023   static unsigned int const amc_event_ = RPCAMCLinkEvent::amc_ | RPCAMCLinkEvent::debug_ | 0;
0024   static unsigned int const amc_amc13_evc_bc_invalid_ = RPCAMCLinkEvent::amc_ | RPCAMCLinkEvent::warn_ | 2;
0025   static unsigned int const amc_amc13_length_incorrect_ = RPCAMCLinkEvent::amc_ | RPCAMCLinkEvent::warn_ | 3;
0026   static unsigned int const amc_amc13_crc_mismatch_ = RPCAMCLinkEvent::amc_ | RPCAMCLinkEvent::warn_ | 4;
0027   static unsigned int const amc_amc13_size_inconsistent_ = RPCAMCLinkEvent::amc_ | RPCAMCLinkEvent::warn_ | 5;
0028   static unsigned int const amc_payload_incomplete_ = RPCAMCLinkEvent::amc_ | RPCAMCLinkEvent::warn_ | 6;
0029   // from AMC Payload Header
0030   static unsigned int const amc_number_mismatch_ = RPCAMCLinkEvent::amc_ | RPCAMCLinkEvent::warn_ | 7;
0031   static unsigned int const amc_size_mismatch_ = RPCAMCLinkEvent::amc_ | RPCAMCLinkEvent::warn_ | 8;
0032 
0033   // from RPC Record
0034   static unsigned int const amc_link_invalid_ = RPCAMCLinkEvent::amc_ | RPCAMCLinkEvent::warn_ | 9;
0035 
0036   static unsigned int const input_event_ = RPCAMCLinkEvent::input_ | RPCAMCLinkEvent::debug_ | 0;
0037   static unsigned int const input_link_error_ = RPCAMCLinkEvent::input_ | RPCAMCLinkEvent::warn_ | 1;
0038   static unsigned int const input_link_ack_fail_ = RPCAMCLinkEvent::input_ | RPCAMCLinkEvent::warn_ | 2;
0039   static unsigned int const input_eod_ = RPCAMCLinkEvent::input_ | RPCAMCLinkEvent::info_ | 3;
0040   static unsigned int const input_lb_invalid_ = RPCAMCLinkEvent::input_ | RPCAMCLinkEvent::warn_ | 4;
0041   static unsigned int const input_connector_invalid_ = RPCAMCLinkEvent::input_ | RPCAMCLinkEvent::warn_ | 5;
0042   static unsigned int const input_connector_not_used_ = RPCAMCLinkEvent::input_ | RPCAMCLinkEvent::warn_ | 6;
0043 
0044   static unsigned int const fed_min_ = 0;
0045   static unsigned int const fed_max_ = 8;
0046   static unsigned int const amc_min_ = 0;
0047   static unsigned int const amc_max_ = 10;
0048   static unsigned int const input_min_ = 0;
0049   static unsigned int const input_max_ = 7;
0050 
0051 public:
0052   RPCAMCLinkEvents();
0053 
0054   static std::string getEventName(unsigned int event);
0055 };
0056 
0057 #endif  // EventFilter_RPCRawToDigi_RPCAMCLinkEvents_h