GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> GNAT / V2-0-1 > gnat_cio / linux-gcc


Interface   Data Structures   File List   Data Fields   Globals  

bndl.h File Reference

Defines public methods for creating/accessing channel bundles. More...


Typedefs

typedef struct _chnlBndl * bndlHandle
 Typedef for struct _chnlBndl*.

Functions

int gBndlClear (gnatHandle gh)
 zeroes out the bundle array
int gBndlAddChnl (gnatHandle gh, unsigned char chnlNum, unsigned int nChnlData, unsigned int *chnlData)
 Inserts the bits pointed to by chnlData into channel chnlNum of the channel bundle.
int gBndlGetDepth (gnatHandle gh, unsigned int *depth32)
 Returns the depth of the bunlde bh in the pointer depth.
int gBndlGetChnl (gnatHandle gh, unsigned char chnlNum, unsigned int nChnlData, unsigned int *chnlData)
 Retrieves the bits contained in channel number chnlNum of bundle in gh.
unsigned short * gBndlGetBndl (gnatHandle gh)
 returns pointer to bundle storage


Detailed Description

Defines public methods for creating/accessing channel bundles.

Author:
Curt Brune -- curt@slac.stanford.edu

Function Documentation

int gBndlAddChnl ( gnatHandle  gh,
unsigned char  chnlNum,
unsigned int  nChnlData,
unsigned int *  pChnlData 
)

Inserts the bits pointed to by chnlData into channel chnlNum of the channel bundle.

Parameters:
gh gnat driver handle previously allocated
chnlNum the channel in the bundle that chnlData is to be inserted into (0-15)
nChnlData the number of 32-bit words in pChnlData
pChnlData a pointer to the channel bits.
Returns:
OK if close successful
See also:
gBndlGetChnl()
The number of unsigned ints in pChnlData must be less than or equal to the bundle depth of gh, i.e. if pChnlData points to two unsigned ints (64 bits) then depth of gh must be two 32-entry blocks (64 entries total) or greater.

References BNDL_DATA, G_OK, GERR_BAD_PARAM, _gnat::m_bndlDepth, MAX_CHANNEL, and VERIFY_HANDLE.

Referenced by sendLATpCell().

int gBndlClear ( gnatHandle  gh  ) 

zeroes out the bundle array

Parameters:
gh gnat driver handle previously allocated
Returns:
OK if close successful

References G_OK, _gnat::m_bndlData, and VERIFY_HANDLE.

Referenced by sendLATpCell().

unsignd short * gBndlGetBndl ( gnatHandle  gh  ) 

returns pointer to bundle storage

Parameters:
gh gnat driver handle previously allocated
Returns:
pointer to bunlde storage or NULL

References _gnat::m_bndlData.

int gBndlGetChnl ( gnatHandle  gh,
unsigned char  chnlNum,
unsigned int  nChnlData,
unsigned int *  pChnlData 
)

Retrieves the bits contained in channel number chnlNum of bundle in gh.

Parameters:
gh gnat driver handle previously allocated
chnlNum the channel number in the bundle bh to fetch.
nChnlData the number of 32-bit words to fetch and store in pChnlData
pChnlData a pointer to store to hold the channel bits.
Returns:
OK if close successful
See also:
gBndlAddChnl()
The number of unsigned ints nChnlData in pChnlData must be less than or equal to the bundle depth of @ gh, i.e. if gh has a depth of 2 nChnlData can be 2 or 1.

References BNDL_DATA, G_OK, GERR_BAD_PARAM, _gnat::m_bndlDepth, MAX_CHANNEL, and VERIFY_HANDLE.

int gBndlGetDepth ( gnatHandle  gh,
unsigned int *  depth 
)

Returns the depth of the bunlde bh in the pointer depth.

Parameters:
gh gnat driver handle previously allocated
depth output parameter used to return the depth of bh
Returns:
OK if close successful

References G_OK, GERR_BAD_PARAM, _gnat::m_bndlDepth, and VERIFY_HANDLE.


Generated on Fri Sep 30 19:17:54 2011 by  doxygen 1.5.8