CMS 3D CMS Logo

CSCDMBTrailer.h
Go to the documentation of this file.
1 #ifndef EventFilter_CSCRawToDigi_CSCDMBTrailer_h
2 #define EventFilter_CSCRawToDigi_CSCDMBTrailer_h
3 
4 #include <cassert>
5 #include <iosfwd>
6 #include <cstring> // bzero
7 #include <memory>
12 
13 struct CSCDMBTrailer2005;
14 struct CSCDMBTrailer2013;
15 
17 public:
18  CSCDMBTrailer(uint16_t firmware_version = 2005);
19 
20  CSCDMBTrailer(const uint16_t* buf, uint16_t firmware_version = 2005);
21 
23  void setEventInformation(const CSCDMBHeader& header) { return theTrailerFormat->setEventInformation(header); };
24 
25  unsigned crateID() const { return theTrailerFormat->crateID(); };
26  unsigned dmbID() const { return theTrailerFormat->dmbID(); };
27 
28  unsigned dmb_l1a() const { return theTrailerFormat->dmb_l1a(); };
29  unsigned dmb_bxn() const { return theTrailerFormat->dmb_bxn(); };
30 
31  unsigned alct_endtimeout() const { return theTrailerFormat->alct_endtimeout(); };
32  unsigned tmb_endtimeout() const { return theTrailerFormat->tmb_endtimeout(); };
33  unsigned cfeb_endtimeout() const { return theTrailerFormat->cfeb_endtimeout(); };
34 
35  unsigned alct_starttimeout() const { return theTrailerFormat->alct_starttimeout(); };
36  unsigned tmb_starttimeout() const { return theTrailerFormat->tmb_starttimeout(); };
37  unsigned cfeb_starttimeout() const { return theTrailerFormat->cfeb_starttimeout(); };
38 
39  unsigned cfeb_movlp() const { return theTrailerFormat->cfeb_movlp(); };
40  unsigned dmb_l1pipe() const { return theTrailerFormat->dmb_l1pipe(); };
41 
42  unsigned alct_empty() const { return theTrailerFormat->alct_empty(); };
43  unsigned tmb_empty() const { return theTrailerFormat->tmb_empty(); };
44  unsigned cfeb_empty() const { return theTrailerFormat->cfeb_empty(); };
45 
46  unsigned alct_half() const { return theTrailerFormat->alct_half(); };
47  unsigned tmb_half() const { return theTrailerFormat->tmb_half(); };
48  unsigned cfeb_half() const { return theTrailerFormat->cfeb_half(); };
49 
50  unsigned alct_full() const { return theTrailerFormat->alct_full(); };
51  unsigned tmb_full() const { return theTrailerFormat->tmb_full(); };
52  unsigned cfeb_full() const { return theTrailerFormat->cfeb_full(); };
53 
54  unsigned crc22() const { return theTrailerFormat->crc22(); };
55  unsigned crc_lo_parity() const { return theTrailerFormat->crc_lo_parity(); };
56  unsigned crc_hi_parity() const { return theTrailerFormat->crc_hi_parity(); };
57 
58  unsigned short* data() { return theTrailerFormat->data(); };
59  unsigned short* data() const { return theTrailerFormat->data(); };
60 
61  unsigned sizeInWords() const { return theTrailerFormat->sizeInWords(); };
62 
63  bool check() const { return theTrailerFormat->check(); };
64 
68 
69 private:
70  std::shared_ptr<CSCVDMBTrailerFormat> theTrailerFormat;
72 };
73 
74 #endif
unsigned cfeb_full() const
Definition: CSCDMBTrailer.h:52
unsigned tmb_starttimeout() const
Definition: CSCDMBTrailer.h:36
unsigned crc22() const
Definition: CSCDMBTrailer.h:54
unsigned alct_endtimeout() const
Definition: CSCDMBTrailer.h:31
unsigned cfeb_movlp() const
Definition: CSCDMBTrailer.h:39
unsigned cfeb_starttimeout() const
Definition: CSCDMBTrailer.h:37
unsigned sizeInWords() const
Definition: CSCDMBTrailer.h:61
unsigned crc_hi_parity() const
Definition: CSCDMBTrailer.h:56
bool check() const
Definition: CSCDMBTrailer.h:63
unsigned cfeb_empty() const
Definition: CSCDMBTrailer.h:44
int theFirmwareVersion
Definition: CSCDMBTrailer.h:71
unsigned tmb_empty() const
Definition: CSCDMBTrailer.h:43
CSCDMBTrailer2005 dmbTrailer2005() const
will throw if the cast fails
CSCDMBTrailer2013 dmbTrailer2013() const
unsigned short * data() const
Definition: CSCDMBTrailer.h:59
unsigned cfeb_endtimeout() const
Definition: CSCDMBTrailer.h:33
unsigned short * data()
Definition: CSCDMBTrailer.h:58
void setEventInformation(const CSCDMBHeader &header)
@ NEEDS TO BE DONE
Definition: CSCDMBTrailer.h:23
unsigned alct_half() const
Definition: CSCDMBTrailer.h:46
unsigned alct_empty() const
Definition: CSCDMBTrailer.h:42
unsigned tmb_endtimeout() const
Definition: CSCDMBTrailer.h:32
unsigned crateID() const
Definition: CSCDMBTrailer.h:25
unsigned tmb_full() const
Definition: CSCDMBTrailer.h:51
unsigned dmbID() const
Definition: CSCDMBTrailer.h:26
unsigned dmb_l1a() const
Definition: CSCDMBTrailer.h:28
unsigned tmb_half() const
Definition: CSCDMBTrailer.h:47
unsigned dmb_bxn() const
Definition: CSCDMBTrailer.h:29
CSCDMBTrailer(uint16_t firmware_version=2005)
Definition: CSCDMBTrailer.cc:7
unsigned cfeb_half() const
Definition: CSCDMBTrailer.h:48
unsigned alct_starttimeout() const
Definition: CSCDMBTrailer.h:35
unsigned dmb_l1pipe() const
Definition: CSCDMBTrailer.h:40
unsigned alct_full() const
Definition: CSCDMBTrailer.h:50
unsigned crc_lo_parity() const
Definition: CSCDMBTrailer.h:55
std::shared_ptr< CSCVDMBTrailerFormat > theTrailerFormat
Definition: CSCDMBTrailer.h:70