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

Constituent: qlsm_dump     Tag: linux-gcc


Interface   Data Structures   File List   Data Fields   Globals  

QLSM.h File Reference

Science defs for LSM (Lat Spacesraft Messages). More...

This graph shows which files directly or indirectly include this file:


Typedefs

typedef _LSF_datagram LSF_datagram
typedef _LSF_contribution LSF_contribution
typedef _LSF_contribution_hdr LSF_contribution_hdr
typedef _QLSM_anc QLSM_anc
 Pointer to buff used by QLSM_ancXxxx(), size determined by QLSM_sizeof().
typedef _QLSM_att QLSM_att
 Pointer to buff used by QLSM_attXxxx(), size determined by QLSM_sizeof().
typedef _QLSM_tt QLSM_tt
 Pointer to buff used by QLSM_ttXxxx(), size determined by QLSM_sizeof().

Enumerations

enum  QLSM_TYPEID {
  QLSM_TYPEID_UNKNOWN = -1,
  QLSM_TYPEID_ATT = 1,
  QLSM_TYPEID_ANC = 2,
  QLSM_TYPEID_TT = 3
}
 type_id used in LSF contributor for QLSM, also returned from QLSM_typeof() More...
enum  QLSM_STATUS {
  QLSM_OK = 0,
  QLSM_ERR_UNKNOWN_DG_TYPEID = -2,
  QLSM_ERR_UNKNOWN_DG_VER = -3,
  QLSM_ERR_UNKNOWN_CTB_VER = -4,
  QLSM_ERR_BAD_CTB_LEN32 = -5,
  QLSM_ERR_UNKNOWN_CTB_TYPEID = -6,
  QLSM_ERR_WRONG_TYPEID = -7
}
 QLSM errors returned by QLSM_xxxExpand. More...

Functions

unsigned int QLSM_sizeof ()
 get size of buffer to receive uncompressed/swapped data
QLSM_TYPEID QLSM_typeof (const LSF_contribution *ctb)
 get type of given contribution
QLSM_STATUS QLSM_ancExpand (QLSM_anc *anc, const LSF_contribution *ctb)
 Routine to check integrity and swap/uncompress input data into a second buffer.
QLSM_STATUS QLSM_attExpand (QLSM_att *att, const LSF_contribution *ctb)
 Routine to check integrity and swap/uncompress input data into a 2nd buffer.
QLSM_STATUS QLSM_ttExpand (QLSM_tt *ttPtr, const LSF_contribution *ctb)
 Routine to check integrity and swap/uncompress input data into a second buffer.
LSF_contribution_hdr * QLSM_swapCtbHdr (LSF_contribution_hdr *ctbDsc, const LSF_contribution *ctbSrc)
 Routine to pull/swap LSF contributor header from input to output buffer.
const char * QLSM_errToStr (QLSM_STATUS status)
 Convert error code to a string.
unsigned int QLSM_ancGetSec (const QLSM_anc *anc)
 Routine to pull "sec" field out of ANC packet after QLSM_ancExpand().
unsigned int QLSM_ancGetSub (const QLSM_anc *anc)
 Routine to pull "sub" field out of ANC packet after QLSM_ancExpand().
const float * QLSM_ancGetPos (const QLSM_anc *anc)
 Routine to pull "pos" field out of ANC packet after QLSM_ancExpand().
const float * QLSM_ancGetVel (const QLSM_anc *anc)
 Routine to pull "vel" field out of ANC packet after QLSM_ancExpand().
unsigned int QLSM_ancGetMode (const QLSM_anc *anc)
 Routine to pull "mode" field out of ANC packet after QLSM_ancExpand().
unsigned int QLSM_ancGetSsr (const QLSM_anc *anc)
 Routine to pull "ssr" field out of ANC packet after QLSM_ancExpand().
unsigned int QLSM_ancGetFlags (const QLSM_anc *anc)
 Routine to pull "flags" field out of ANC packet after QLSM_ancExpand().
void QLSM_ancPrint (const QLSM_anc *anc)
 Routine to print a ANC buffer.
unsigned int QLSM_attGetSec (const QLSM_att *att)
 Routine to pull "sec" field out of ATT packet after QLSM_attExpand().
unsigned int QLSM_attGetSub (const QLSM_att *att)
 Routine to pull "sub" field out of ATT packet after QLSM_attExpand().
const double * QLSM_attGetQuat (const QLSM_att *att)
 Routine to pull "quat" field out of ATT packet after QLSM_attExpand().
const float * QLSM_attGetAvel (const QLSM_att *att)
 Routine to pull "avel" field out of ATT packet after QLSM_attExpand().
void QLSM_attPrint (const QLSM_att *att)
 Routine to print a ATT buffer.
unsigned int QLSM_ttGetTimetone (const QLSM_tt *tt)
 Routine to pull "timetone" field out of TT packet after QLSM_ttExpand().
unsigned int QLSM_ttGetFlags (const QLSM_tt *tt)
 Routine to pull "flags" field out of TT packet after QLSM_attExpand().
void QLSM_ttPrint (const QLSM_tt *tt)
 Routine to print a TT buffer.
QLSM_STATUS QLSM_printDatagram (const LSF_datagram *dgm)
 Print the Magic7 packet given the pointer to the whole LSF datagram.
QLSM_STATUS QLSM_printCtb (const LSF_contribution *ctb)
 Print the Magic7 packet given the pointer to the LSF contributor.

Detailed Description

Science defs for LSM (Lat Spacesraft Messages).

Author:
Ed Bacho -- ebacho@slac.stanford.edu

JJRussell -- russell@slac.stanford.edu

This module handles the definitions of structures that are output as science data for the LSM package over the SSR.

   CVS $Id: QLSM.h,v 1.7 2008/09/20 00:46:31 russell Exp $
  

Enumeration Type Documentation

enum QLSM_STATUS
 

QLSM errors returned by QLSM_xxxExpand.

Enumerator:
QLSM_OK  Success
QLSM_ERR_UNKNOWN_DG_TYPEID  LSF datagram header has typeid which is not in LSF/LSF_ids.h
QLSM_ERR_UNKNOWN_DG_VER  LSF datagram header has an unknown version number
QLSM_ERR_UNKNOWN_CTB_VER  LSF contributor header has unknown version number
QLSM_ERR_BAD_CTB_LEN32  LSF contributor has an incorrect length for the packet
QLSM_ERR_UNKNOWN_CTB_TYPEID  LSF contributor header has typeid which is not in QLSM_TYPEID
QLSM_ERR_WRONG_TYPEID  Typeid of data does not match the QLSM_xxxGetXxx

enum QLSM_TYPEID
 

type_id used in LSF contributor for QLSM, also returned from QLSM_typeof()

Enumerator:
QLSM_TYPEID_UNKNOWN  Unknown type
QLSM_TYPEID_ATT  Attitude record
QLSM_TYPEID_ANC  Ancillary record
QLSM_TYPEID_TT  Timetone record


Function Documentation

QLSM_STATUS QLSM_ancExpand QLSM_anc ancPtr,
const LSF_contribution *  ctbPtr
 

Routine to check integrity and swap/uncompress input data into a second buffer.

Parameters:
ancPtr output buffer of size QLSM_sizeof(), use as input for QLSM_ancGetXx routines
ctbPtr input buffer
Returns:
status codes QLSM_ERR_Xxxx, 0 if sucessfull
The check routine does integrity checks on the given LSF contributor packet and then decompress/swaps data into the output buffer. The size of the output buffer is determined by QLSM_sizeof(). The output buffer can then be used as input with the QLSM_ancGetXxxx routines.

unsiged int QLSM_ancGetFlags const QLSM_anc ancPtr  ) 
 

Routine to pull "flags" field out of ANC packet after QLSM_ancExpand().

Return values:
If != 0, the "flags" field,
If == 0, unknown version (should have got err on QLSM_ancExpand())
Parameters:
ancPtr Output buffer from QLSM_ancExpand()

unsiged int QLSM_ancGetMode const QLSM_anc ancPtr  ) 
 

Routine to pull "mode" field out of ANC packet after QLSM_ancExpand().

Return values:
If != 0, "mode" field,
If == 0 if unknown version (should have got err on QLSM_ancExpand())
Parameters:
ancPtr Output buffer from QLSM_ancExpand()

float QLSM_ancGetPos const QLSM_anc ancPtr  ) 
 

Routine to pull "pos" field out of ANC packet after QLSM_ancExpand().

Return values:
If != 0, the "pos" field,
If == 0, if unknown version (should have got err on QLSM_ancExpand())
Parameters:
ancPtr Output buffer from QLSM_ancExpand

unsigned int QLSM_ancGetSec const QLSM_anc ancPtr  ) 
 

Routine to pull "sec" field out of ANC packet after QLSM_ancExpand().

Return values:
If != 0, the "sec" field,
If == 0, unknown version (should have got err on QLSM_ancExpand())
Parameters:
ancPtr Output buffer from QLSM_ancExpand()

unsiged int QLSM_ancGetSsr const QLSM_anc ancPtr  ) 
 

Routine to pull "ssr" field out of ANC packet after QLSM_ancExpand().

Return values:
If !=0 The "ssr" field,
If ==0, unknown version (should have got err on QLSM_ancExpand())
Parameters:
ancPtr Output buffer from QLSM_ancExpand()

unsigned int QLSM_ancGetSub const QLSM_anc ancPtr  ) 
 

Routine to pull "sub" field out of ANC packet after QLSM_ancExpand().

Return values:
If != 0, "sub"-second field,
If == 0, unknown version (should have got err on QLSM_ancExpand())
Parameters:
ancPtr Output buffer from QLSM_ancExpand()

float QLSM_ancGetVel const QLSM_anc ancPtr  ) 
 

Routine to pull "vel" field out of ANC packet after QLSM_ancExpand().

Return values:
If != 0, the "vel" field,
If == 0 unknown version (should have got err on QLSM_ancExpand())
Parameters:
ancPtr Output buffer from QLSM_ancExpand()

void QLSM_ancPrint const QLSM_anc ancPtr  ) 
 

Routine to print a ANC buffer.

Parameters:
ancPtr Output buffer from QLSM_ancExpand() ----------------------------------------------------------------------

QLSM_STATUS QLSM_attExpand QLSM_att attPtr,
const LSF_contribution *  ctbPtr
 

Routine to check integrity and swap/uncompress input data into a 2nd buffer.

Parameters:
attPtr output buffer of size QLSM_sizeof(), use as input for QLSM_attGetXxx routines
ctbPtr input buffer
Returns:
status codes QLSM_ERR_Xxxx, 0 if sucessfull
The check routine does integrity checks on the given LSF contributor packet and then decompress/swaps data into the output buffer. The size of the output buffer is determined by QLSM_sizeof(). The output buffer can then be used as input with the QLSM_attGetXxxx routines.

float * QLSM_attGetAvel const QLSM_att attPtr  ) 
 

Routine to pull "avel" field out of ATT packet after QLSM_attExpand().

Return values:
If non-NULL, a pointer to the "avel" field
If NULL, unknown version (should have got err on QLSM_attExpand())
Parameters:
attPtr Output buffer from QLSM_attExpand()
----------------------------------------------------------------------

double * QLSM_attGetQuat const QLSM_att attPtr  ) 
 

Routine to pull "quat" field out of ATT packet after QLSM_attExpand().

Return values:
If non-NULL, pointer to "quat" field,
If NULL, unknown version (should have got err on QLSM_attExpand())
Parameters:
attPtr Output buffer from QLSM_attExpand()

unsiged int QLSM_attGetSec const QLSM_att attPtr  ) 
 

Routine to pull "sec" field out of ATT packet after QLSM_attExpand().

Return values:
If != 0, the "sec" field,
If == 0 unknown version (should have got err on QLSM_attExpand())
Parameters:
attPtr Output buffer from QLSM_attExpand()

unsiged int QLSM_attGetSub const QLSM_att attPtr  ) 
 

Routine to pull "sub" field out of ATT packet after QLSM_attExpand().

Return values:
If !=0, the "sub" field,
If ==0, unknown version (should have got err on QLSM_attExpand())
Parameters:
attPtr Output buffer from QLSM_attExpand()

void QLSM_attPrint const QLSM_att attPtr  ) 
 

Routine to print a ATT buffer.

Parameters:
attPtr Output buffer from QLSM_attExpand()

const char * QLSM_errToStr QLSM_STATUS  status  ) 
 

Convert error code to a string.

Returns:
The string corresponding to the error code
Parameters:
status One of the status codes QLSM_ERR_Xxxx
----------------------------------------------------------------------

unsigned int QLSM_printCtb const LSF_contribution *  ctbPtr  ) 
 

Print the Magic7 packet given the pointer to the LSF contributor.

Returns:
status codes QLSM_ERR_Xxxx, 0 if sucessful
Parameters:
ctbPtr Pointer to start of raw LSF contributor (before QLSM_expandXxxx())

unsigned int QLSM_printDatagram const LSF_datagram *  dgPtr  ) 
 

Print the Magic7 packet given the pointer to the whole LSF datagram.

Returns:
status codes QLSM_ERR_Xxxx, 0 if sucessful
Parameters:
dgPtr Pointer to start of raw LSF datagram (before QLSM_expandXxx())

unsigned int QLSM_sizeof  ) 
 

get size of buffer to receive uncompressed/swapped data

Returns:
Size of required destination buffer in bytes

LSF_contribution_hdr * QLSM_swapCtbHdr LSF_contribution_hdr *  ctbPtrOut,
const LSF_contribution *  ctbPtr
 

Routine to pull/swap LSF contributor header from input to output buffer.

Returns:
Pointer to the given output buffer
Parameters:
ctbPtrOut Output buffer to put LSF contributor header in
ctbPtr Input buffer with possibly swapped LSF contrib data

QLSM_STATUS QLSM_ttExpand QLSM_tt ttPtr,
const LSF_contribution *  ctbPtr
 

Routine to check integrity and swap/uncompress input data into a second buffer.

Parameters:
ttPtr output buffer of size QLSM_sizeof(), use as input for QLSM_ttGetXxx routines
ctbPtr input buffer
Returns:
status codes QLSM_ERR_Xxxx, 0 if sucessfull
The check routine does integrity checks on the given LSF contributor packet and then decompress/swaps data into the output buffer. The size of the output buffer is determined by QLSM_sizeof(). The output buffer can then be used as input with the QLSM_ttGetXxxx routines.

unsigned int QLSM_ttGetFlags const QLSM_tt ttPtr  ) 
 

Routine to pull "flags" field out of TT packet after QLSM_attExpand().

Return values:
If != 0, the "flags" field,
If == 0 if unknown version (should have got err on QLSM_ttExpand())
Parameters:
ttPtr Output buffer from QLSM_ttExpand()

unsigned int QLSM_ttGetTimetone const QLSM_tt ttPtr  ) 
 

Routine to pull "timetone" field out of TT packet after QLSM_ttExpand().

Parameters:
ttPtr Output buffer from QLSM_ttExpand()
Returns:
returns "timetone" field, 0 if unknown version (should have got err on QLSM_ttExpand()) ----------------------------------------------------------------------

void QLSM_ttPrint const QLSM_tt ttPtr  ) 
 

Routine to print a TT buffer.

Parameters:
ttPtr Output buffer from QLSM_ttExpand()

QLSM_TYPEID QLSM_typeof const LSF_contribution *  ctbPtr  ) 
 

get type of given contribution

Returns:
type of record, one of the QLSM_TYPID enumerations
  • QLSM_TYPEID_ATT the attitude record
  • QLSM_TYPEID_TT, the timetone record
  • QLSM_TYPEID_ANC, the ancillary record
Return values:
QLSM_TYPEID_UNKNOWN,if typeid is not recognized
Parameters:
ctbPtr input buffer


Generated on Sun Jun 14 02:17:34 2009 by  doxygen 1.4.4