GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> QMEM / V0-2-1 > qmem_unit_test / rhel6-32


Interface   Data Structures   File List   Data Fields   Globals  

qmem_test_datagram.c File Reference

Test the QMEM_parse_datagram() function. More...

#include <string.h>
#include <LSF/LSF.h>
#include <QMEM/QMEM.h>
#include <qmem_unit_test.h>
#include <qmem_util_wrap.h>

Functions

static void byte_swap (unsigned char *buf_p, unsigned int num_bytes)
 Byte-swap the 32-bit values within a buffer of data.
void qmem_test_datagram (test_Test_Descriptor *td_p, const unsigned int bit_mask)
 Unit test for the QMEM_parse_datagram() function.

Variables

static unsigned char small_dgm []
 Small memory dump datagram.


Detailed Description

Test the QMEM_parse_datagram() function.

**  CVS $Id: qmem_test_datagram.c,v 1.2 2011/03/30 23:56:36 russell Exp $
**  

Function Documentation

void byte_swap ( unsigned char *  buf_p,
unsigned int  num_bytes 
) [static]

Byte-swap the 32-bit values within a buffer of data.

Parameters:
buf_p Pointer to data buffer.
num_bytes Size, in bytes, of the data buffer.
Returns:
Nothing.

Referenced by qmem_test_datagram().

void qmem_test_datagram ( test_Test_Descriptor td_p,
const unsigned int  bit_mask 
)


Variable Documentation

unsigned char small_dgm[] [static]

Initial value:

    {
        0x80, 0x1f, 0x06, 0x00, 0x00, 0x00, 0x00, 0x1d,
        0x00, 0x10, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04,
        0x07, 0x77, 0x00, 0x00, 0xbf, 0x85, 0x00, 0x00,
        0x00, 0x10, 0x00, 0x02, 0x00, 0x00, 0x00, 0x17,
        0x00, 0x00, 0x00, 0x00, 0xbf, 0x86, 0x00, 0x00,
        0xff, 0xff, 0xff, 0xfc, 0xbf, 0x88, 0x00, 0x80,
        0xff, 0xff, 0x00, 0xef, 0x01, 0x3f, 0x00, 0x00,
        0xff, 0xff, 0x00, 0xe7, 0xde, 0xed, 0xfa, 0xde,
        0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x17,
        0x00, 0x00, 0x00, 0x01, 0x40, 0x00, 0x00, 0x00,
        0xff, 0xf0, 0x15, 0xd8, 0x00, 0x3f, 0x00, 0x00,
        0xff, 0xf0, 0x14, 0x40, 0x00, 0x00, 0xff, 0xff,
        0xff, 0xf0, 0x15, 0xd8, 0x00, 0x00, 0x00, 0x00,
        0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
        0x00, 0x00, 0x48, 0x01,
    }
Small memory dump datagram.


Generated on Tue Nov 29 17:31:41 2011 by  doxygen 1.5.8