Belle II Software development
dhc_dhe_end_frame Struct Reference

DHE End frame data struct. More...

#include <PXDRawDataStructs.h>

Public Member Functions

unsigned int get_words (void) const
 get words
 
unsigned int getFixedSize (void) const
 get fixed size
 
void print (void) const
 print
 
unsigned int getDHEId (void) const
 get DHE Id
 
unsigned int getErrorInfo (void) const
 get error info
 
unsigned int getErrorStateMachineDHP (int dhpid) const
 get error state machine DHP
 
unsigned int getErrorStateMachineStartDHP (int dhpid) const
 get error state machine start DHP
 
unsigned int getErrorStateMachineEndDHP (int dhpid) const
 get error state machine end DHP
 

Public Attributes

const dhc_frame_header_word0 word0
 word0
 
const ubig16_t trigger_nr_lo
 trigger_nr_lo
 
const ubig16_t wordsineventlo
 words swapped... because of DHE 16 bit handling
 
const ubig16_t wordsineventhi
 wordsineventhi
 
const ubig32_t errorinfo
 not well defined yet
 
const unsigned int crc32
 crc32
 

Detailed Description

DHE End frame data struct.

Encapsules the access for different bits and data words See Data format definitions [BELLE2-NOTE-TE-2016-009] on https://docs.belle2.org/

Definition at line 501 of file PXDRawDataStructs.h.

Member Function Documentation

◆ get_words()

unsigned int get_words ( void  ) const
inline

get words

Definition at line 511 of file PXDRawDataStructs.h.

512 {
513 return wordsineventlo | ((unsigned int)wordsineventhi << 16);
514 }
const ubig16_t wordsineventhi
wordsineventhi
const ubig16_t wordsineventlo
words swapped... because of DHE 16 bit handling

◆ getDHEId()

unsigned int getDHEId ( void  ) const
inline

get DHE Id

Definition at line 523 of file PXDRawDataStructs.h.

524 {
525 return (word0.getMisc() >> 4) & 0x3F;
526 };
const dhc_frame_header_word0 word0
word0
unsigned short getMisc(void) const
get misc

◆ getErrorInfo()

unsigned int getErrorInfo ( void  ) const
inline

get error info

Definition at line 528 of file PXDRawDataStructs.h.

529 {
530 return errorinfo;
531 };
const ubig32_t errorinfo
not well defined yet

◆ getErrorStateMachineDHP()

unsigned int getErrorStateMachineDHP ( int  dhpid) const

get error state machine DHP

Definition at line 190 of file PXDRawDataStructs.cc.

191 {
192 switch (dhpid) {
193 case 0: return ((uint32_t)errorinfo >> 24) & 0xFF;
194 case 1: return ((uint32_t)errorinfo >> 16) & 0xFF;
195 case 2: return ((uint32_t)errorinfo >> 8) & 0xFF;
196 case 3: return errorinfo & 0xFF;
197 default: return 0;
198 }
199 };

◆ getErrorStateMachineEndDHP()

unsigned int getErrorStateMachineEndDHP ( int  dhpid) const

get error state machine end DHP

Definition at line 212 of file PXDRawDataStructs.cc.

213 {
214 switch (dhpid) {
215 case 0: return ((uint32_t)errorinfo >> 28) & 0xF;
216 case 1: return ((uint32_t)errorinfo >> 20) & 0xF;
217 case 2: return ((uint32_t)errorinfo >> 12) & 0xF;
218 case 3: return ((uint32_t)errorinfo >> 4) & 0xF;
219 default: return 0;
220 }
221 };

◆ getErrorStateMachineStartDHP()

unsigned int getErrorStateMachineStartDHP ( int  dhpid) const

get error state machine start DHP

Definition at line 201 of file PXDRawDataStructs.cc.

202 {
203 switch (dhpid) {
204 case 0: return ((uint32_t)errorinfo >> 24) & 0xF;
205 case 1: return ((uint32_t)errorinfo >> 16) & 0xF;
206 case 2: return ((uint32_t)errorinfo >> 8) & 0xF;
207 case 3: return errorinfo & 0xF;
208 default: return 0;
209 }
210 };

◆ getFixedSize()

unsigned int getFixedSize ( void  ) const
inline

get fixed size

Definition at line 516 of file PXDRawDataStructs.h.

517 {
518 return 16;
519 };

◆ print()

void print ( void  ) const

print

Definition at line 183 of file PXDRawDataStructs.cc.

184 {
185 word0.print();
186 B2DEBUG(99, "DHC DHE End Frame TNRLO $" << std::hex << trigger_nr_lo << " WIEVT $" << std::hex << wordsineventhi << "." <<
187 wordsineventlo << " ERR $" << std::hex << errorinfo << " CRC " << std::hex << crc32);
188 };
const unsigned int crc32
crc32
const ubig16_t trigger_nr_lo
trigger_nr_lo

Member Data Documentation

◆ crc32

const unsigned int crc32

crc32

Definition at line 507 of file PXDRawDataStructs.h.

◆ errorinfo

const ubig32_t errorinfo

not well defined yet

Definition at line 506 of file PXDRawDataStructs.h.

◆ trigger_nr_lo

const ubig16_t trigger_nr_lo

trigger_nr_lo

Definition at line 503 of file PXDRawDataStructs.h.

◆ word0

word0

Definition at line 502 of file PXDRawDataStructs.h.

◆ wordsineventhi

const ubig16_t wordsineventhi

wordsineventhi

Definition at line 505 of file PXDRawDataStructs.h.

◆ wordsineventlo

const ubig16_t wordsineventlo

words swapped... because of DHE 16 bit handling

Definition at line 504 of file PXDRawDataStructs.h.


The documentation for this struct was generated from the following files: