GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> LSF / V2-0-8 > document_lsf / sun-gcc
Classes | |
struct | _LSF_statsHdrTimetone |
Defines the most general version of the timetone information. More... | |
struct | _LSF_statsHdrTimetones |
Captures the information needed to convert a GEM event clock register value into an absolute time. More... | |
struct | _LSF_statsHdrEvtSeq |
Hide the access to the long long to avoid alignment issues. More... | |
struct | _LSF_statsHdrEvt |
Captures the information needed to uniquely identify this event by sequence and time. More... | |
struct | _LSF_statsHdrEvtSpan |
The defining information about the first and last event that went into the sample. More... | |
struct | _LSF_statsHdr |
The standard header for event-based statistics. More... | |
Typedefs | |
typedef struct _LSF_statsHdrTimetone | LSF_statsHdrTimetone |
Typedef for struct _LSF_statsHdrTimetone. | |
typedef struct _LSF_statsHdrTimetones | LSF_statsHdrTimetones |
Typedef for struct _LSF_statsHdrTimetones. | |
typedef struct _LSF_statsHdrEvtSeq | LSF_statsHdrEvtSeq |
Typedef for struct _LSF_statsHdrEvtSeq. | |
typedef struct _LSF_statsHdrEvt | LSF_statsHdrEvt |
Typedef for _LSF_statsHdrEvt. | |
typedef struct _LSF_statsHdrEvtSpan | LSF_statsHdrEvtSpan |
Typedef for struct _LSF_statsHdrEvtSpan. | |
typedef struct _LSF_statsHdr | LSF_statsHdr |
Typedef for struct _LSF_statsHdr LSF_statsHdr. | |
Functions | |
static __inline void | LSF__statsHdrEvtSeqSet (LSF_statsHdrEvtSeq *dst, unsigned long long int src) |
Hide access to the long long sequence number to avoid big/little endian and alignment issues. | |
static __inline unsigned long long int | LSF__statsHdrEvtSeqGet (const LSF_statsHdrEvtSeq *seq) |
Hide access to the long long sequence number to avoid big/little endian and alignment issues. |
CVS $Id: LSF_statsHdr.h,v 1.4 2005/11/17 20:53:18 russell Exp $
Note that the actual first or last event may have not contributed to the statistics.
Typedef for struct _LSF_statsHdr LSF_statsHdr.
first_evt_sequence = hdr->evt.first.seq; last_evt_sequence = hdr->evt.last.seq; beg_seconds = hdr->evt.first.timetones.cur.secs; end_seconds = hdr->evt.last.timetones.cur.secs; elasped_seconds = beg_seconds - end_seconds; events_seen = last_evt_sequence - first_evt_sequence; events_accumulated = hdr->nevts;
unsigned long long int get_event_time (const LSF_statsHdrEvt *evt) { unsigned int curGemStrobe = evt->timetones.cur.gemStrobe & TICKS; unsigned int prvGemStrobe = evt->timetones.cur.gemStrobe & TICKS; unsigned int deltaTicks = curGemStrobe - prvGemStrobe; unsigned int curGemSecs = evt->timetones.cur.secs; unsigned int prvGemSecs = evt->timetones.prv.secs; unsigned int deltaNsecs = ONE_BILLION * (curGemSecs - prvGemSecs); unsigned int curGemClock = evt->gemClock & TICKS; unsigned int elapsedTicks = curGemClock - curGemStrobe; unsigned long long int time; // One needs to exercise caution to make sure the arithmetic // is done properly. In particular the mulitplication, // elapsedTicks * deltaNsecs, should yield an unsigned long long int // while the division by deltaTicks should be considered a 64/32 bit // division. time = ONE_BILLION * secs + (elapsedTicks * deltaNsecs) / deltaTicks; return time;
beg_time = get_event_time (&hdr->evt.first); end_time = get_event_time (&hdr->evt.last); elapsed_time = end_time - beg_time;
Typedef for _LSF_statsHdrEvt.
Typedef for struct _LSF_statsHdrTimetone.
static __inline unsigned long long int LSF__statsHdrEvtSeqGet | ( | const LSF_statsHdrEvtSeq * | seq | ) | [static] |
Hide access to the long long sequence number to avoid big/little endian and alignment issues.
seq | Address of the event sequence number to fetch |
References _LSF_statsHdrEvtSeq::hi, and _LSF_statsHdrEvtSeq::lo.
static __inline void LSF__statsHdrEvtSeqSet | ( | LSF_statsHdrEvtSeq * | dst, | |
unsigned long long int | src | |||
) | [static] |
Hide access to the long long sequence number to avoid big/little endian and alignment issues.
dst | The destintation address | |
src | The source event sequence number |
References _LSF_statsHdrEvtSeq::hi, and _LSF_statsHdrEvtSeq::lo.