GLAST/LAT > DAQ and FSW > FSW > Doxygen Index > EDS / V2-10-0
Constituent: eds     Tag: mv2304
#include "EDS/EBF_tkr.h"
#include "EDS/FFS.h"
Defines | |
#define | BITCOUNT(x) (((BX_(x)+(BX_(x)>>4)) & 0x0F0F0F0F) % 255) |
Computes the number of bits set (1) in 32-bit argument. | |
#define | BX_(x) |
Replaces each 4-bit sequence in arg by the number of bits in sequence. | |
Functions | |
static __inline int | countLayerEnds (const unsigned int accepts[3]) |
Counts the number of layer ends with data in the accept block. | |
int | EBF_tkrLayerEndCount (const EBF_tkr *tkr) |
Counts the number of layer ends with hit strips. | |
int | EBF_tkrStripCount (const EBF_tkr *tkr, int layerEndCnt, int maxwrds) |
Counts the hit strips. | |
int | EBF_tkrLenCalc (const EBF_tkr *tkr, int maxwrds) |
Calculates the number of bytes, not including any padding, in the EBF_tkr record. |
CVS $Id: EBF_tkr.c,v 1.2 2005/10/13 22:00:58 russell Exp $
#define BITCOUNT | ( | x | ) | (((BX_(x)+(BX_(x)>>4)) & 0x0F0F0F0F) % 255) |
Computes the number of bits set (1) in 32-bit argument.
#define BX_ | ( | x | ) |
Value:
((x) - (((x)>>1)&0x77777777) \ - (((x)>>2)&0x33333333) \ - (((x)>>3)&0x11111111))
int countLayerEnds | ( | const unsigned int | accepts[3] | ) | [static] |
Counts the number of layer ends with data in the accept block.
accepts | The array of the 3 accept words (only 72 bits active) |
int EBF_tkrLayerEndCount | ( | const EBF_tkr * | tkr | ) |
Counts the number of layer ends with hit strips.
tkr | Pointer to the tracker data |
int EBF_tkrLenCalc | ( | const EBF_tkr * | tkr, | |
int | maxwrds | |||
) |
Calculates the number of bytes, not including any padding, in the EBF_tkr record.
tkr | Pointer to the tracker data | |
maxwrds | The maximum number of words that can possibly be in the EBF_tkr record. This serves as a sanity check in case the serial decode of the record goes haywire. |
int EBF_tkrStripCount | ( | const EBF_tkr * | tkr, | |
int | layerEndCnt, | |||
int | maxwrds | |||
) |
Counts the hit strips.
tkr | Pointer to the tracker data | |
layerEndCnt | Count of the number hit layer end ends. This is most easily acquired from EBF_tkrLayerEndCount. | |
maxwrds | The maximum number of words in the TKR record. This value is currently not used, but may be used in the future as an integrity check. |