GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> QSE / V2-3-0 > qse / sun-gcc


Interface   Data Structures   File List   Data Fields   Globals  

QDF_acdRepack.c File Reference

Reformats the QDF_acdEvt to EBF format. More...

#include "QSE/QDF_acdRepack.h"
#include "QSE/QDF_esbRepack.h"
#include "QSE/QSE_aemRepack.h"
#include "QSE/QDF_esb.h"
#include "QDF_acd_def.h"
#include "EDS/EBF_cid.h"
#include "EDS/EDA_acd.h"
#include "EDS/FFS.h"
#include "dprintf.h"

Classes

struct  _Hdr0_bf
 Maps out the fields of the first header word as bit fields. More...
union  _Hdr0
 Maps out the fields as a union of a 16-bit integer and its bit field representation. More...
struct  _Hdr1_bf
 Maps out the fields of the second header word as bit fields. More...
union  _Hdr1
 Maps out the fields as a union of a 16-bit integer and its bit field representation. More...
struct  _Hdr2_bf
 Maps out the fields of the third header word as bit fields. More...
union  _Hdr2
 Maps out the fields as a union of a 16-bit integer and its bit field representation. More...

Defines

#define print_channel(_ichn, _dadc, _ped, _pha)
#define _store(_ha, _idx, _val)
 Stores the specified value in the proper half word of a 32-bit integer, respecting the endianness of the host machine.

Typedefs

typedef struct _Hdr0_bf Hdr0_bf
 Typedef struct _Hdr0_bf.
typedef union _Hdr0 Hdr0
 Typedef union _Hdr0.
typedef struct _Hdr1_bf Hdr1_bf
 Typedef struct _Hdr1_bf.
typedef union _Hdr1 Hdr1
 Typedef struct _Hdr1.
typedef struct _Hdr2_bf Hdr2_bf
 Typedef struct _Hdr2_bf.
typedef union _Hdr2 Hdr2
 Typedef struct _Hdr2.

Functions

static __inline int acd_ped_repack (unsigned short int *dst, int left, const QDF_acdPedEvt *aem)
 Reformats the ACD pedestal event back to EBF format.
static __inline int acd_ped_repack_general (unsigned short int *dst, int left, const QDF_acdPedEvt *aem)
 Reformats the ACD pedestal event back to EBF format.
static __inline int acd_ped_repack_clean (unsigned short int *dst, int left, const QDF_acdPedEvt *aem)
 Reformats the ACD pedestal event back to EBF format.
EBF_ctb * QDF_acdStdRepack (const QDF_acdEvt *acd, EBF_ctb *ctb, const EBF_ctb *end)
 Fills in the ACD event contribution.
EBF_ctb * QDF_acdPedRepack (const QDF_acdEvt *acd, EBF_ctb *ctb, const EBF_ctb *end)
 Fills in the ACD event contribution.


Detailed Description

Reformats the QDF_acdEvt to EBF format.

Author:
JJRussell - russell@slac.stanford.edu

   CVS $Id: QDF_acdRepack.c,v 1.4 2007/04/08 22:39:49 russell Exp $

Define Documentation

#define _store ( _ha,
_idx,
_val   ) 

Stores the specified value in the proper half word of a 32-bit integer, respecting the endianness of the host machine.

Parameters:
_ha The half word array
_idx The index
_val The value to store


Function Documentation

static __inline int acd_ped_repack ( unsigned short int *  dst,
int  left,
const QDF_acdPedEvt aem 
) [static]

Reformats the ACD pedestal event back to EBF format.

Returns:
The length, in bytes, used
Parameters:
dst The destination pointer, i.e. where the ACD data goes
left The number of bytes available in dst
aem The ACD pedestal event data

static __inline int acd_ped_repack_clean ( unsigned short int *  dst,
int  left,
const QDF_acdPedEvt aem 
) [static]

Reformats the ACD pedestal event back to EBF format.

Returns:
The length, in bytes, used
Parameters:
dst The destination pointer, i.e. where the ACD data goes
left The number of bytes available in dst
aem The ACD pedestal event data
This is a higher efficiency repacker, but can only be used on events that are error free and have all 12 cables present.

static __inline int acd_ped_repack_general ( unsigned short int *  dst,
int  left,
const QDF_acdPedEvt aem 
) [static]

Reformats the ACD pedestal event back to EBF format.

Returns:
The number of shorts integers consumed
Parameters:
dst The destination pointer, i.e. where the ACD data goes
left The number of bytes available in dst
aem The ACD pedestal event data
This is the general purpose repacker. It is usually used when there is something unusual about the event (timeouts, parity errors, etc.) As such, it is lower efficiency than acd_ped_repack_clean.

EBF_ctb* QDF_acdPedRepack ( const QDF_acdEvt acd,
EBF_ctb *  ctb,
const EBF_ctb *  end 
)

Fills in the ACD event contribution.

Returns:
The next contributor to fill in. Since the ACD is generally the last contributor, this is really a pointer to the end of the event.
Parameters:
acd The ACD event (source)
ctb The EBF contributor to fill in (destination)
end The address after the last available address

EBF_ctb* QDF_acdStdRepack ( const QDF_acdEvt acd,
EBF_ctb *  ctb,
const EBF_ctb *  end 
)

Fills in the ACD event contribution.

Returns:
The next contributor to fill in. Since the ACD is generally the last contributor, this is really a pointer to the end of the event.
Parameters:
acd The ACD event (source)
ctb The EBF contributor to fill in (destination)
end The address after the last available address


Generated on Thu Sep 2 14:54:53 2010 by  doxygen 1.5.3