GLAST/LAT > DAQ and FSW > FSW > Doxygen Index > EDS / V2-10-0

Constituent: eds     Tag: mv2304


Interface   Data Structures   File List   Data Fields   Globals  

ACD_unpack.c File Reference

Routines to unpack the ACD data. More...

#include "EDS/ACD_unpack.h"
#include "EDS/ACD_rec.h"
#include "EDS/FFS.h"
#include "EDS/EDS_endianness.h"

Include dependency graph for ACD_unpack.c:


Defines

#define HW_ACCESS(_hwa, _idx)   _hwa[_idx];
 Addresses the ACD half-word array in a way that is compatiable with big or little endian machines.
#define channel_print(_chn)
#define DPRINTF(format,...)

Functions

int ACD_unpack (ACD_rec *acd, const void *dat, unsigned int len)
 Unpacks an ACD record from the AEM into a standard structure.
int ACD_unpackInit (ACD_rec *acd)
 One-time initialization an ACD_rec structure.
void ACD_unpackReset (ACD_rec *acd)
 Resets the ACD_rec structure, preparing it for a new event.
unsigned int ACD_unpackSizeof (void)
 Returns the size, in bytes, of an ACD_rec structure.

Detailed Description

Routines to unpack the ACD data.

Author:
JJRussell - russell@slac.stanford.edu
    CVS $Id: ACD_unpack.c,v 1.4 2006/04/05 20:04:05 russell Exp $

Define Documentation

#define HW_ACCESS ( _hwa,
_idx   )     _hwa[_idx];

Addresses the ACD half-word array in a way that is compatiable with big or little endian machines.

Returns:
Value at the halfword index
Parameters:
_hwa The halfword array to be accessed
_idx The value to be transformed


Function Documentation

int ACD_unpack ( ACD_rec acd,
const void *  dat,
unsigned int  len 
)

Unpacks an ACD record from the AEM into a standard structure.

Returns:
Status. The only failure is if more than 18 PHAs are found to be present on an given FREE board or the serial decode extends beyond the maxwrds
Parameters:
acd Pointer to the data structure to receive the unpacked data
dat The ACD data for this event
len The length of the data in bytes

int ACD_unpackInit ( ACD_rec acd  ) 

One-time initialization an ACD_rec structure.

Returns:
0, always
Parameters:
acd The ACD_rec structure to initialize

void ACD_unpackReset ( ACD_rec acd  ) 

Resets the ACD_rec structure, preparing it for a new event.

Parameters:
acd The ACD_rec structure to reset

unsigned int ACD_unpackSizeof ( void   ) 

Returns the size, in bytes, of an ACD_rec structure.

Returns:
The size, in bytes, of an ACD_rec structure
This function should be called to determine the size of an ACD_rec structure. This allows the calling program to avoid including the structure definition an ACD_rec.

After allocating an ACD_rec structure, the structure should be initialized using ACD_unpackInit().


Generated on Sat Jun 20 01:25:26 2009 by  doxygen 1.5.3