Jpp
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Private Attributes | List of all members
DWF_Frame Class Reference

DWF frame. More...

#include <TimeSlice.hh>

Inheritance diagram for DWF_Frame:
Frame< DWF_Item > DaqFramePreamble std::vector< DWF_Item > std::vector< char > benchmark::chronometrable

Public Types

typedef DWF_Item item_type
 item type definition More...
 

Public Member Functions

 DWF_Frame ()
 Default constructor. More...
 
 ClassDef (DWF_Frame, 2)
 ROOT class definition. More...
 
const DAQCommonHeader *const getHeader () const
 
const char *const getPayload () const
 
unsigned int getSeqNumber () const
 
unsigned int getFrameLength () const
 
unsigned int getNItems () const
 
Frame< DWF_Item > & operator+= (const Frame< DWF_Item > &object)
 operator += More...
 
 ClassDef (Frame, 2)
 ROOT class definition. More...
 
 ClassDef (DaqFramePreamble, 2)
 
ulonglong frameTime ()
 
const unsigned short lcm_id () const
 get LCM idendifier More...
 
const unsigned short ars_id () const
 get ARS idendifier More...
 
const unsigned short data_type () const
 get data type More...
 
const unsigned short numberOfItems () const
 get number of items More...
 
virtual const unsigned char * getdata () const
 Return a pointer to the frame data buffer. More...
 
virtual const unsigned int getdatalen () const
 Return the length of the frame data buffer. More...
 

Static Public Member Functions

static const unsigned int Length ()
 Return length of an encoded frame preamble in bytes. More...
 

Public Attributes

unsigned int frameSize
 Total length of the frame in 4-byte words. More...
 
unsigned short dataType
 Data type code (DAQ_xxx) More...
 
unsigned short frameTarget
 Unique code representing the shore station for this frame. More...
 
unsigned int frameTime1
 Frame 'time stamp' in units of 50ns (MSW) More...
 
unsigned int frameTime2
 Frame 'time stamp' in units of 50ns (LSW) More...
 
unsigned int frameIndex
 Number of frames since start of the run. More...
 
unsigned short status
 Status of frame Xon/Xoff. More...
 
unsigned short nbItems
 Number of items actually sent in this frame. More...
 
unsigned short LCM_ID
 ID of originating LCM. More...
 
unsigned short ARS_ID
 ID of originating ARS. More...
 
unsigned int runNumber
 Run-number as given by the RunControl. More...
 

Private Attributes

unsigned int m_seqnumber
 

Detailed Description

DWF frame.

Definition at line 379 of file TimeSlice.hh.

Member Typedef Documentation

◆ item_type

typedef DWF_Item Frame< DWF_Item >::item_type
inherited

item type definition

Definition at line 233 of file TimeSlice.hh.

Constructor & Destructor Documentation

◆ DWF_Frame()

DWF_Frame::DWF_Frame ( )
inline

Default constructor.

Definition at line 386 of file TimeSlice.hh.

386 : Frame<DWF_Item>() {}

Member Function Documentation

◆ ClassDef() [1/3]

DWF_Frame::ClassDef ( DWF_Frame  ,
 
)

ROOT class definition.

◆ getHeader()

const DAQCommonHeader* const Frame< DWF_Item >::getHeader ( ) const
inlineinherited

Definition at line 18 of file frame.hh.

19  {
20  return static_cast<const DAQCommonHeader* const>(
21  static_cast<const void* const>(&front()));
22  }

◆ getPayload()

const char* const Frame< DWF_Item >::getPayload ( ) const
inlineinherited

Definition at line 24 of file frame.hh.

25  {
26  return &front() + sizeof(DAQCommonHeader);
27  }

◆ getSeqNumber()

unsigned int Frame< DWF_Item >::getSeqNumber ( ) const
inlineinherited

Definition at line 29 of file frame.hh.

30  {
31  return m_seqnumber;
32  }

◆ getFrameLength()

unsigned int Frame< DWF_Item >::getFrameLength ( ) const
inlineinherited

Definition at line 34 of file frame.hh.

35  {
36  return size() ? getHeader()->FrameLength : 0;
37  }

◆ getNItems()

unsigned int Frame< DWF_Item >::getNItems ( ) const
inlineinherited

Definition at line 39 of file frame.hh.

40  {
41  return size() ? getHeader()->NumberOfItems : 0;
42  }

◆ operator+=()

Frame<DWF_Item >& Frame< DWF_Item >::operator+= ( const Frame< DWF_Item > &  object)
inlineinherited

operator +=

Parameters
objectframe
Returns
this frame

Definition at line 272 of file TimeSlice.hh.

273  {
274  if ((DaqFramePreamble&) *this == (DaqFramePreamble&) object) {
275  for (typename Frame<T>::const_iterator i = object.begin(); i != object.end(); ++i) {
276  this->insert(std::lower_bound(Frame<T>::begin(),Frame<T>::end(),*i),*i);
277  }
278  }
279 
280  return *this;
281  }

◆ ClassDef() [2/3]

Frame< DWF_Item >::ClassDef ( Frame< DWF_Item ,
 
)
inherited

ROOT class definition.

◆ ClassDef() [3/3]

DaqFramePreamble::ClassDef ( DaqFramePreamble  ,
 
)
inherited

◆ frameTime()

ulonglong DaqFramePreamble::frameTime ( )
inlineinherited
Returns
64 bit frame time

Definition at line 40 of file FramePreamble.hh.

41  {
43  }

◆ lcm_id()

const unsigned short DaqFramePreamble::lcm_id ( ) const
inlineinherited

get LCM idendifier

Returns
LCM identifier

Definition at line 67 of file FramePreamble.hh.

67 { return LCM_ID; }

◆ ars_id()

const unsigned short DaqFramePreamble::ars_id ( ) const
inlineinherited

get ARS idendifier

Returns
ARS identifier

Definition at line 73 of file FramePreamble.hh.

73 { return ARS_ID; }

◆ data_type()

const unsigned short DaqFramePreamble::data_type ( ) const
inlineinherited

get data type

Returns
data type

Definition at line 79 of file FramePreamble.hh.

79 { return dataType; }

◆ numberOfItems()

const unsigned short DaqFramePreamble::numberOfItems ( ) const
inlineinherited

get number of items

Returns
number of items

Definition at line 85 of file FramePreamble.hh.

85 { return nbItems; }

◆ getdata()

virtual const unsigned char* DaqFramePreamble::getdata ( ) const
inlinevirtualinherited

Return a pointer to the frame data buffer.

The returned value points to the start of the frame preamble.

Returns
pointer to data

Definition at line 92 of file FramePreamble.hh.

92 { return NULL; }

◆ getdatalen()

virtual const unsigned int DaqFramePreamble::getdatalen ( ) const
inlinevirtualinherited

Return the length of the frame data buffer.

The returned value is in bytes (not words), and includes the frame preamble.

Returns
length of data

Definition at line 100 of file FramePreamble.hh.

100 { return Length(); }

◆ Length()

static const unsigned int DaqFramePreamble::Length ( )
inlinestaticinherited

Return length of an encoded frame preamble in bytes.

Definition at line 111 of file FramePreamble.hh.

111 { return 32; }

Member Data Documentation

◆ m_seqnumber

unsigned int Frame< DWF_Item >::m_seqnumber
privateinherited

Definition at line 14 of file frame.hh.

◆ frameSize

unsigned int DaqFramePreamble::frameSize
inherited

Total length of the frame in 4-byte words.

Definition at line 27 of file FramePreamble.hh.

◆ dataType

unsigned short DaqFramePreamble::dataType
inherited

Data type code (DAQ_xxx)

Definition at line 30 of file FramePreamble.hh.

◆ frameTarget

unsigned short DaqFramePreamble::frameTarget
inherited

Unique code representing the shore station for this frame.

Definition at line 33 of file FramePreamble.hh.

◆ frameTime1

unsigned int DaqFramePreamble::frameTime1
inherited

Frame 'time stamp' in units of 50ns (MSW)

Definition at line 36 of file FramePreamble.hh.

◆ frameTime2

unsigned int DaqFramePreamble::frameTime2
inherited

Frame 'time stamp' in units of 50ns (LSW)

Definition at line 38 of file FramePreamble.hh.

◆ frameIndex

unsigned int DaqFramePreamble::frameIndex
inherited

Number of frames since start of the run.

Definition at line 46 of file FramePreamble.hh.

◆ status

unsigned short DaqFramePreamble::status
inherited

Status of frame Xon/Xoff.

Definition at line 49 of file FramePreamble.hh.

◆ nbItems

unsigned short DaqFramePreamble::nbItems
inherited

Number of items actually sent in this frame.

Definition at line 52 of file FramePreamble.hh.

◆ LCM_ID

unsigned short DaqFramePreamble::LCM_ID
inherited

ID of originating LCM.

Definition at line 55 of file FramePreamble.hh.

◆ ARS_ID

unsigned short DaqFramePreamble::ARS_ID
inherited

ID of originating ARS.

Definition at line 58 of file FramePreamble.hh.

◆ runNumber

unsigned int DaqFramePreamble::runNumber
inherited

Run-number as given by the RunControl.

Definition at line 61 of file FramePreamble.hh.


The documentation for this class was generated from the following file:
ulonglong
Definition: ulonglong.hh:11
DaqFramePreamble::ARS_ID
unsigned short ARS_ID
ID of originating ARS.
Definition: FramePreamble.hh:58
Frame< DWF_Item >
DaqFramePreamble::frameTime1
unsigned int frameTime1
Frame 'time stamp' in units of 50ns (MSW)
Definition: FramePreamble.hh:36
Frame< DWF_Item >::m_seqnumber
unsigned int m_seqnumber
Definition: frame.hh:14
DaqFramePreamble::LCM_ID
unsigned short LCM_ID
ID of originating LCM.
Definition: FramePreamble.hh:55
DAQCommonHeader::FrameLength
uint32_t FrameLength
Definition: daq_common_header.hh:14
Frame< DWF_Item >::getHeader
const DAQCommonHeader *const getHeader() const
Definition: frame.hh:18
DaqFramePreamble::dataType
unsigned short dataType
Data type code (DAQ_xxx)
Definition: FramePreamble.hh:30
DaqFramePreamble::frameTime2
unsigned int frameTime2
Frame 'time stamp' in units of 50ns (LSW)
Definition: FramePreamble.hh:38
DAQCommonHeader::NumberOfItems
uint32_t NumberOfItems
Definition: daq_common_header.hh:27
DaqFramePreamble::Length
static const unsigned int Length()
Return length of an encoded frame preamble in bytes.
Definition: FramePreamble.hh:111
DaqFramePreamble::nbItems
unsigned short nbItems
Number of items actually sent in this frame.
Definition: FramePreamble.hh:52
DaqFramePreamble
This object holds the information from the 'preamble' of a data frame.
Definition: FramePreamble.hh:23
DAQCommonHeader
Definition: daq_common_header.hh:12