GLAST/LAT > DAQ and FSW > FSW > Doxygen Index > DUMP / V0-1-0

Constituent: dump     Tag: linux-gcc


Interface   Data Structures   File List   Data Fields   Globals  

dump.c File Reference

Framework used to parse the contents of a stream of datagrams. More...

#include "dump_p.h"
#include "list_p.h"
#include "QSD/CCSDS_apidDsc.h"
#include "QSD/CCSDS_istream.h"
#include "QSD/CCSDS_telemetry.h"
#include "LSF/LSF.h"
#include "LSF/LSF_scan.h"
#include "LSF/LSF_print.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>

Include dependency graph for dump.c:


Functions

size_t DUMP_sizeofAstream (void)
 Return the size of the ApidStream structure.
ApidStreamDUMP_constructAstream (void *astream, unsigned int dgmid, unsigned short apid, unsigned char *dsc_buf, size_t buf_size, DUMP_dgmHandler *dgm_handler, void *rsrc)
 Construct an ApidStream structure using the resources provided.
void * DUMP_getResource (ApidStream *astream)
 Hand back the pointer to the application resources.
void DUMP_getTime (ApidStream *astream, unsigned int *secs, unsigned int *usecs)
 Get the packet time for the current datagram.
int DUMP_process (const char *file, int dmp_ccsds)
 Process a file of science datagrams.

Detailed Description

Framework used to parse the contents of a stream of datagrams.

Author:
James Swain & Owen Saxton
Id
dump.c,v 1.5 2008/11/21 17:39:59 saxton Exp

Function Documentation

ApidStream* DUMP_constructAstream void *  astream,
unsigned int  dgmid,
unsigned short  apid,
unsigned char *  dsc_buf,
size_t  buf_size,
DUMP_dgmHandler dgm_handler,
void *  rsrc
 

Construct an ApidStream structure using the resources provided.

Parameters:
astream Pointer to the ApidStream structure.
dgmid The ID of the datagrams to process.
apid The Apid of the packets to process.
dsc_buf The address of the buffer to contain each complete datagram.
buf_size The size, in bytes, of the datagram buffer.
dgm_handler The address of the routine to be called to process each complete datagram.
rsrc Resource handle to be associated with the stream.
Returns:
Pointer to the constructed ApidStream structure

void* DUMP_getResource ApidStream astream  ) 
 

Hand back the pointer to the application resources.

Parameters:
astream Pointer to the ApidStream structure
Returns:
Pointer handed to DUMP when DUMP_constructAstream was invoked

void DUMP_getTime ApidStream astream,
unsigned int *  secs,
unsigned int *  usecs
 

Get the packet time for the current datagram.

This routine returns the time fields from the last telemetry packet of the current datagram.

Parameters:
astream Pointer to the ApidStream structure.
secs The address of an integer to receive the seconds value.
usecs The address of an integer to receive the microseconds value.

int DUMP_process const char *  file,
int  dmp_ccsds
 

Process a file of science datagrams.

Parameters:
file Name of the file to process
dmp_ccsds Flag indicating whether (1) or not (0) to print out the raw CCSDS
Return values:
0 Success
~0 Failure

size_t DUMP_sizeofAstream void   ) 
 

Return the size of the ApidStream structure.

Returns:
Size of the ApidStream structure


Generated on Sat Nov 22 01:09:11 2008 by  doxygen 1.4.4