CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes | Friends
CSCSPTrailer Class Reference

#include <CSCSPTrailer.h>

Public Member Functions

unsigned int board_id (void) const throw ()
 
bool check (void) const throw ()
 
unsigned int configuration (void) const throw ()
 
unsigned int crc (void) const throw ()
 
 CSCSPTrailer (void)
 
unsigned int day (void) const throw ()
 
unsigned int l1a_7bits (void) const throw ()
 
bool l1a_fifo_full (void) const throw ()
 
unsigned int l1a_queue_size (void) const throw ()
 
unsigned int month (void) const throw ()
 
bool unpack (const unsigned short *&buf) throw ()
 
unsigned int year (void) const throw ()
 

Private Attributes

unsigned bb_: 1
 
unsigned board_id_: 12
 
unsigned core_configuraton: 12
 
unsigned crc_high: 11
 
unsigned crc_high_parity: 1
 
unsigned crc_low: 11
 
unsigned crc_low_parity: 1
 
unsigned day_: 5
 
unsigned l1a_: 8
 
unsigned l1a_fifo_full_: 1
 
unsigned month_: 4
 
unsigned spare_1: 1
 
unsigned spare_2: 1
 
unsigned trailer_mark_1: 4
 
unsigned trailer_mark_10: 4
 
unsigned trailer_mark_2: 4
 
unsigned trailer_mark_3: 3
 
unsigned trailer_mark_4: 4
 
unsigned trailer_mark_5: 4
 
unsigned trailer_mark_6: 4
 
unsigned trailer_mark_7: 4
 
unsigned trailer_mark_8: 4
 
unsigned trailer_mark_9: 4
 
unsigned word_count_high: 4
 
unsigned word_count_low: 4
 
unsigned year_: 4
 
unsigned zero_1: 1
 
unsigned zero_2: 7
 

Friends

class CSCTFPacker
 

Detailed Description

Definition at line 4 of file CSCSPTrailer.h.

Constructor & Destructor Documentation

CSCSPTrailer::CSCSPTrailer ( void  )
inline

Definition at line 71 of file CSCSPTrailer.h.

71 {}

Member Function Documentation

unsigned int CSCSPTrailer::board_id ( void  ) const
throw (
)
inline

Definition at line 65 of file CSCSPTrailer.h.

References board_id_.

65 { return board_id_; }
unsigned board_id_
Definition: CSCSPTrailer.h:32
bool CSCSPTrailer::check ( void  ) const
throw (
)
inline

Definition at line 46 of file CSCSPTrailer.h.

References spare_1, spare_2, trailer_mark_1, trailer_mark_10, trailer_mark_2, trailer_mark_3, trailer_mark_4, trailer_mark_5, trailer_mark_6, trailer_mark_7, trailer_mark_8, trailer_mark_9, zero_1, and zero_2.

Referenced by unpack().

46  {
47  return spare_1!=0 || spare_2!=0 || zero_1!=0 || zero_2!=0 ||
48  trailer_mark_1!=0xF || trailer_mark_2!=0xF || trailer_mark_3!=0x7 || trailer_mark_4!=0xF || trailer_mark_5!=0xF || trailer_mark_6!=0xF ||
49  trailer_mark_7!=0xE || trailer_mark_8!=0xE || trailer_mark_9!=0xE || trailer_mark_10!=0xE;
50  }
unsigned trailer_mark_10
Definition: CSCSPTrailer.h:41
unsigned trailer_mark_2
Definition: CSCSPTrailer.h:11
unsigned trailer_mark_4
Definition: CSCSPTrailer.h:15
unsigned zero_1
Definition: CSCSPTrailer.h:22
unsigned trailer_mark_6
Definition: CSCSPTrailer.h:26
unsigned trailer_mark_3
Definition: CSCSPTrailer.h:12
unsigned trailer_mark_7
Definition: CSCSPTrailer.h:30
unsigned trailer_mark_1
Definition: CSCSPTrailer.h:9
unsigned spare_2
Definition: CSCSPTrailer.h:21
unsigned trailer_mark_8
Definition: CSCSPTrailer.h:33
unsigned trailer_mark_5
Definition: CSCSPTrailer.h:23
unsigned spare_1
Definition: CSCSPTrailer.h:20
unsigned trailer_mark_9
Definition: CSCSPTrailer.h:37
unsigned zero_2
Definition: CSCSPTrailer.h:29
unsigned int CSCSPTrailer::configuration ( void  ) const
throw (
)
inline

Definition at line 59 of file CSCSPTrailer.h.

References core_configuraton.

59 { return core_configuraton; }
unsigned core_configuraton
Definition: CSCSPTrailer.h:25
unsigned int CSCSPTrailer::crc ( void  ) const
throw (
)
inline

Definition at line 67 of file CSCSPTrailer.h.

References crc_high, and crc_low.

67 { return crc_low|(crc_high<<11); }
unsigned crc_low
Definition: CSCSPTrailer.h:35
unsigned crc_high
Definition: CSCSPTrailer.h:39
unsigned int CSCSPTrailer::day ( void  ) const
throw (
)
inline

Definition at line 58 of file CSCSPTrailer.h.

References day_.

58 { return day_; }
unsigned day_
Definition: CSCSPTrailer.h:28
unsigned int CSCSPTrailer::l1a_7bits ( void  ) const
throw (
)
inline

Definition at line 52 of file CSCSPTrailer.h.

References l1a_.

52 { return l1a_; }
unsigned l1a_
Definition: CSCSPTrailer.h:7
bool CSCSPTrailer::l1a_fifo_full ( void  ) const
throw (
)
inline

Definition at line 54 of file CSCSPTrailer.h.

References l1a_fifo_full_.

54 { return l1a_fifo_full_; }
unsigned l1a_fifo_full_
Definition: CSCSPTrailer.h:13
unsigned int CSCSPTrailer::l1a_queue_size ( void  ) const
throw (
)
inline

Definition at line 53 of file CSCSPTrailer.h.

References word_count_high, and word_count_low.

53 { return (word_count_high<<4)|word_count_low; }
unsigned word_count_low
Definition: CSCSPTrailer.h:8
unsigned word_count_high
Definition: CSCSPTrailer.h:14
unsigned int CSCSPTrailer::month ( void  ) const
throw (
)
inline

Definition at line 57 of file CSCSPTrailer.h.

References month_.

57 { return month_; }
unsigned month_
Definition: CSCSPTrailer.h:17
bool CSCSPTrailer::unpack ( const unsigned short *&  buf)
throw (
)
inline

Definition at line 69 of file CSCSPTrailer.h.

References check().

69 { memcpy(this, buf, 8*sizeof(short)); buf+=8; return check(); }
bool check(void) const
Definition: CSCSPTrailer.h:46
unsigned int CSCSPTrailer::year ( void  ) const
throw (
)
inline

Definition at line 56 of file CSCSPTrailer.h.

References bb_, and year_.

56 { return 2000+16*bb_+year_; }
unsigned bb_
Definition: CSCSPTrailer.h:19
unsigned year_
Definition: CSCSPTrailer.h:18

Friends And Related Function Documentation

friend class CSCTFPacker
friend

Definition at line 43 of file CSCSPTrailer.h.

Member Data Documentation

unsigned CSCSPTrailer::bb_
private

Definition at line 19 of file CSCSPTrailer.h.

Referenced by year().

unsigned CSCSPTrailer::board_id_
private

Definition at line 32 of file CSCSPTrailer.h.

Referenced by board_id().

unsigned CSCSPTrailer::core_configuraton
private

Definition at line 25 of file CSCSPTrailer.h.

Referenced by configuration().

unsigned CSCSPTrailer::crc_high
private

Definition at line 39 of file CSCSPTrailer.h.

Referenced by crc().

unsigned CSCSPTrailer::crc_high_parity
private

Definition at line 40 of file CSCSPTrailer.h.

unsigned CSCSPTrailer::crc_low
private

Definition at line 35 of file CSCSPTrailer.h.

Referenced by crc().

unsigned CSCSPTrailer::crc_low_parity
private

Definition at line 36 of file CSCSPTrailer.h.

unsigned CSCSPTrailer::day_
private

Definition at line 28 of file CSCSPTrailer.h.

Referenced by day().

unsigned CSCSPTrailer::l1a_
private

Definition at line 7 of file CSCSPTrailer.h.

Referenced by l1a_7bits().

unsigned CSCSPTrailer::l1a_fifo_full_
private

Definition at line 13 of file CSCSPTrailer.h.

Referenced by l1a_fifo_full().

unsigned CSCSPTrailer::month_
private

Definition at line 17 of file CSCSPTrailer.h.

Referenced by month().

unsigned CSCSPTrailer::spare_1
private

Definition at line 20 of file CSCSPTrailer.h.

Referenced by check().

unsigned CSCSPTrailer::spare_2
private

Definition at line 21 of file CSCSPTrailer.h.

Referenced by check().

unsigned CSCSPTrailer::trailer_mark_1
private

Definition at line 9 of file CSCSPTrailer.h.

Referenced by check(), and CSCTFPacker::produce().

unsigned CSCSPTrailer::trailer_mark_10
private

Definition at line 41 of file CSCSPTrailer.h.

Referenced by check(), and CSCTFPacker::produce().

unsigned CSCSPTrailer::trailer_mark_2
private

Definition at line 11 of file CSCSPTrailer.h.

Referenced by check(), and CSCTFPacker::produce().

unsigned CSCSPTrailer::trailer_mark_3
private

Definition at line 12 of file CSCSPTrailer.h.

Referenced by check(), and CSCTFPacker::produce().

unsigned CSCSPTrailer::trailer_mark_4
private

Definition at line 15 of file CSCSPTrailer.h.

Referenced by check(), and CSCTFPacker::produce().

unsigned CSCSPTrailer::trailer_mark_5
private

Definition at line 23 of file CSCSPTrailer.h.

Referenced by check(), and CSCTFPacker::produce().

unsigned CSCSPTrailer::trailer_mark_6
private

Definition at line 26 of file CSCSPTrailer.h.

Referenced by check(), and CSCTFPacker::produce().

unsigned CSCSPTrailer::trailer_mark_7
private

Definition at line 30 of file CSCSPTrailer.h.

Referenced by check(), and CSCTFPacker::produce().

unsigned CSCSPTrailer::trailer_mark_8
private

Definition at line 33 of file CSCSPTrailer.h.

Referenced by check(), and CSCTFPacker::produce().

unsigned CSCSPTrailer::trailer_mark_9
private

Definition at line 37 of file CSCSPTrailer.h.

Referenced by check(), and CSCTFPacker::produce().

unsigned CSCSPTrailer::word_count_high
private

Definition at line 14 of file CSCSPTrailer.h.

Referenced by l1a_queue_size().

unsigned CSCSPTrailer::word_count_low
private

Definition at line 8 of file CSCSPTrailer.h.

Referenced by l1a_queue_size().

unsigned CSCSPTrailer::year_
private

Definition at line 18 of file CSCSPTrailer.h.

Referenced by year().

unsigned CSCSPTrailer::zero_1
private

Definition at line 22 of file CSCSPTrailer.h.

Referenced by check().

unsigned CSCSPTrailer::zero_2
private

Definition at line 29 of file CSCSPTrailer.h.

Referenced by check().