GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> THS / dev > ths / rhel5-64


Interface   Data Structures   File List   Data Fields   Globals  

THS_lsf.c File Reference

Convenience routines for handling LSF packets. More...

#include <THS/THS.h>
#include <PBS/WCT.h>
#include <MSG/MSG_pubdefs.h>
#include <PBI/Endianness.h>
#include <string.h>

Functions

void THS_lsfStatClear (LSF_statsHdr *statsHdr)
 Clear the LSF_statsHdr structure.
unsigned int THS_lsfStatFirstEvt (LSF_statsHdr *statsHdr, unsigned long long seq, unsigned int gemClock, unsigned int gemStrobe)
 Sets first event parms within LSF_statsHdr.
void THS_lsfStatIncEvt (LSF_statsHdr *statsHdr, int increment)
 Increment event counter in LSF_statsHdr structure.
unsigned int THS_lsfStatLastEvt (LSF_statsHdr *statsHdr, unsigned long long seq, unsigned int gemClock, unsigned int gemStrobe)
 Sets last event parms within LSF_statsHdr.


Detailed Description

Convenience routines for handling LSF packets.

CVS $Id: THS_lsf.c,v 1.2 2011/03/26 19:33:05 russell Exp $
Author:
E.Bacho

A.P.Waite

Convenience routines for handling LSF packets.

Moved out of file THS_gem.c to improve packaging of constituent ths4ddt.


Function Documentation

void THS_lsfStatClear ( LSF_statsHdr *  statsHdr  ) 

Clear the LSF_statsHdr structure.

Parameters:
statsHdr pointer to LSF_statsHdr structure to fill in
Returns:
nothing

unsigned int THS_lsfStatFirstEvt ( LSF_statsHdr *  statsHdr,
unsigned long long  seq,
unsigned int  gemClock,
unsigned int  gemStrobe 
)

Sets first event parms within LSF_statsHdr.

Parameters:
statsHdr pointer to LSF_statsHdr structure to fill in
seq extended seqence number of the event
gemClock evt clock register read from GEM contributor of event
gemStrobe evt PPS cock register read from GEM contributor of event
Returns:
status This is convenient routine to fill in event info that is stored in a LSF_statsHdr structure within an LSF packet for eventual output as science data on the SSR.

References THS_prevTimtoneFromEvent().

void THS_lsfStatIncEvt ( LSF_statsHdr *  statsHdr,
int  increment 
)

Increment event counter in LSF_statsHdr structure.

Parameters:
statsHdr pointer to LSF_statsHdr structure to fill in
increment number of events to increase evt count by
Returns:
nothing This is convenient routine to increment the event counter within LSF_statsHdr structure. Note that this in the number of events seen by the callback, the raw events rather than the number of prescaled events.

unsigned int THS_lsfStatLastEvt ( LSF_statsHdr *  statsHdr,
unsigned long long  seq,
unsigned int  gemClock,
unsigned int  gemStrobe 
)

Sets last event parms within LSF_statsHdr.

Parameters:
statsHdr pointer to LSF_statsHdr structure to fill in
seq extended seqence number of the event
gemClock evt clock register read from GEM contributor of event
gemStrobe evt PPS cock register read from GEM contributor of event
Returns:
status This is convenient routine to fill in event info that is stored in a LSF_statsHdr structure within an LSF packet for eventual output as science data on the SSR.

References THS_prevTimtoneFromEvent().


Generated on Thu Mar 31 12:53:03 2011 by  doxygen 1.5.8