CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
CSCDCCTrailer.h
Go to the documentation of this file.
1 // Authors Rick W and Alex T 9/24/94
2 //
3 #ifndef CSCDCCTrailer_h
4 #define CSCDCCTrailer_h
5 
6 #include <iostream>
7 #include <string.h> // bzero
9 
10 
14 struct CSCDCCTrailer {
16  {
17  bzero(this, sizeInWords()*2);
18  dcc_trail1 = 0xEF;
19  EOE_1 = 0XA;
20  XXXX_1 = 0X0; //@@ Actually a reserved bit. We should not test on it.
21  }
22 
24  {
25  memcpy(this, digi.trailer(), sizeInWords()*2);
26  }
29  unsigned fifo_status : 8;
30  unsigned ddu_data_status2 : 24;
31  unsigned ddu_data_status1 : 16;
32  unsigned readout_time : 8;
33  unsigned dcc_trail1 : 8;
34 
37  unsigned dollardollar : 1;
38  unsigned Tx : 3;
39  unsigned TTS : 4;
40  unsigned Evt_stat : 4;
41  unsigned XXXX_2 : 4;
42  unsigned CRC : 16;
43  unsigned Evt_lgth : 24;
44  unsigned XXXX_1 : 4;
45  unsigned EOE_1 : 4;
46 
47  static unsigned sizeInWords() {return 8;}
48  //@@ The XXXX_1 is a reserved bit in CMS format - we really should not be testing it
49  bool check() const {return (dcc_trail1 == 0xEF) && (EOE_1 == 0XA) && (XXXX_1 == 0X0);}
50  unsigned short * data() {return (unsigned short *) this;}
51 
52 };
53 #endif
unsigned ddu_data_status1
Definition: CSCDCCTrailer.h:31
bool check() const
Definition: CSCDCCTrailer.h:49
unsigned short * data()
Definition: CSCDCCTrailer.h:50
unsigned ddu_data_status2
Definition: CSCDCCTrailer.h:30
unsigned Evt_stat
Definition: CSCDCCTrailer.h:40
unsigned dcc_trail1
Definition: CSCDCCTrailer.h:33
const uint16_t * trailer() const
unsigned CRC
Definition: CSCDCCTrailer.h:42
unsigned XXXX_1
Definition: CSCDCCTrailer.h:44
CSCDCCTrailer(const CSCDCCStatusDigi &digi)
Definition: CSCDCCTrailer.h:23
unsigned Evt_lgth
Definition: CSCDCCTrailer.h:43
unsigned dollardollar
Definition: CSCDCCTrailer.h:37
unsigned fifo_status
Definition: CSCDCCTrailer.h:29
static unsigned sizeInWords()
Definition: CSCDCCTrailer.h:47
unsigned readout_time
Definition: CSCDCCTrailer.h:32
unsigned EOE_1
Definition: CSCDCCTrailer.h:45
unsigned XXXX_2
Definition: CSCDCCTrailer.h:41
static const double X0
unsigned TTS
Definition: CSCDCCTrailer.h:39