GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> CTDB / V5-5-5 > ctdb_unit_test / rhel4-32


Interface   Data Structures   File List   Data Fields   Globals  

ctdb_unit_test_private.h File Reference

CTDB package unit test private definitions. More...

#include <PBS/RW.h>

Defines

#define CO1553_ARG_VALUE_0   (void*) 0x12345678
#define CO1553_ARG_VALUE_1   (void*) 0xabcd0123

Functions

int co1553_rt_sim_test_sizeof (void)
int co1553_rt_sim_test_param (void)
int co1553_bc_sim_test_sizeof (void)
int co1553_bc_sim_test_param (void)
int co1553_rt_test_sizeof (void)
int co1553_rt_test_param (void)
int co1553_rt_test_cmd_rx (void)
int co1553_rt_test_cmd_tx (void)
int co1553_rt_test_telem (void)
int co1553_rt_test_err (void)
int co1553_bc_test_sizeof (void)
int co1553_bc_test_param (void)
int co1553_bc_test_cmd_rx (void)
int co1553_bc_test_cmd_tx (void)
int co1553_bc_test_telem (void)
void co1553_pkt_free (void *pkt, void *arg)
void co1553_mem_copy (void *dest, void *src, unsigned int numWord)

Variables

unsigned short co1553_cmd_rx_msg_0 []
unsigned short co1553_cmd_rx_msg_1 []
unsigned short co1553_cmd_rx_msg_2 []
unsigned short co1553_cmd_rx_msg_3 []
unsigned short co1553_cmd_rx_msg_4 []
unsigned short co1553_cmd_rx_pkt_0 []
unsigned short co1553_cmd_rx_pkt_1 []
unsigned short co1553_cmd_rx_pkt_2 []
unsigned int co1553_cmd_rx_pkt_0_size
unsigned int co1553_cmd_rx_pkt_1_size
unsigned int co1553_cmd_rx_pkt_2_size
unsigned short co1553_cmd_tx_pkt_0 []
unsigned short co1553_cmd_tx_pkt_1 []
unsigned short co1553_cmd_tx_pkt_2 []
unsigned short co1553_cmd_tx_msg_0 []
unsigned short co1553_cmd_tx_msg_1 []
unsigned short co1553_cmd_tx_msg_2 []
unsigned int co1553_cmd_tx_pkt_0_size
unsigned int co1553_cmd_tx_pkt_1_size
unsigned int co1553_cmd_tx_pkt_2_size
unsigned short co1553_hkp_pkt_0 []
unsigned int co1553_hkp_pkt_0_size
unsigned short co1553_hkp_pkt_1 []
unsigned int co1553_hkp_pkt_1_size
unsigned short co1553_telem_pkt_0 []
unsigned short co1553_telem_pkt_1 []
unsigned short co1553_telem_pkt_2 []
unsigned short co1553_telem_msg_0 []
unsigned short co1553_telem_msg_1 []
unsigned short co1553_telem_msg_2 []
unsigned short co1553_telem_msg_3 []
unsigned int co1553_telem_pkt_0_size
unsigned int co1553_telem_pkt_1_size
unsigned int co1553_telem_pkt_2_size
const char * sepStr
const char * sepStr2
RW_ctl diagLock


Detailed Description

CTDB package unit test private definitions.

Author:
D.L. Wood

Define Documentation

#define CO1553_ARG_VALUE_0   (void*) 0x12345678

A dummy value passed to the memory allocation callbacks. Used to check that callback arg passing is working correctly.

Referenced by co1553_bc_test_cmd_rx(), co1553_bc_test_param(), co1553_hkp_0(), co1553_pkt_free(), co1553_rt_test_cmd_tx(), co1553_rt_test_param(), and co1553_rt_test_telem().

#define CO1553_ARG_VALUE_1   (void*) 0xabcd0123

A dummy value passed to the memory allocation callbacks. Used to check that callback arg passing is working correctly.

Referenced by co1553_hkp_1(), and co1553_rt_test_telem().


Function Documentation

int co1553_bc_sim_test_param ( void   ) 

Performs invalid and out of range tests on parameters for co1553_bc_sim library functions.

Return values:
0 Success.
-1 Failure

References CO1553_bcSimExit(), CO1553_bcSimInit(), CO1553_bcSimPktCmdRxSend(), CO1553_bcSimPktCmdTxRecv(), CO1553_bcSimPktTelemRecv(), CO1553_bcSimSizeof(), CO1553_bcSimStart(), CO1553_bcSimStop(), and sepStr.

Referenced by ctdb_unit_test().

int co1553_bc_sim_test_sizeof ( void   ) 

Performs checks on return values from co1553_bc_sim sizeof library functions.

Return values:
0 Success.
-1 Failure

References CO1553_bcSimSizeof().

Referenced by ctdb_unit_test().

int co1553_bc_test_cmd_rx ( void   ) 

int co1553_bc_test_cmd_tx ( void   ) 

int co1553_bc_test_param ( void   ) 

int co1553_bc_test_sizeof ( void   ) 

Performs checks on return values from co1553_bc sizeof library functions.

Return values:
0 Success.
-1 Failure

References CO1553_bcCmdRxSizeof(), CO1553_bcCmdTxSizeof(), and CO1553_bcTelemSizeof().

Referenced by ctdb_unit_test().

int co1553_bc_test_telem ( void   ) 

void co1553_mem_copy ( void *  dest,
void *  src,
unsigned int  numWord 
)

Memory copy function used for the unit tests.

Parameters:
dest The destination address.
src The source address.
numWord The number of 16-bit words to copy.

Referenced by co1553_bc_test_cmd_rx(), co1553_bc_test_cmd_tx(), co1553_bc_test_telem(), co1553_rt_test_cmd_rx(), co1553_rt_test_cmd_tx(), co1553_rt_test_err(), and co1553_rt_test_telem().

void co1553_pkt_free ( void *  pkt,
void *  arg 
)

Memory release function used for the unit tests.

Parameters:
pkt A pointer to the packet buffer to free.
arg A user defined argument.

References CO1553_ARG_VALUE_0.

Referenced by co1553_bc_test_cmd_rx(), co1553_bc_test_param(), co1553_rt_test_cmd_tx(), co1553_rt_test_param(), and co1553_rt_test_telem().

int co1553_rt_sim_test_param ( void   ) 

Performs invalid and out of range tests on parameters for co1553_rt_sim library functions.

Return values:
0 Success.
-1 Failure

References CO1553_rtSimExit(), CO1553_rtSimHkpGet(), CO1553_rtSimHkpSet(), CO1553_rtSimInit(), CO1553_rtSimPktCmdRxRecv(), CO1553_rtSimPktCmdTxSend(), CO1553_rtSimPktTelemSend(), CO1553_rtSimSizeof(), CO1553_rtSimStart(), CO1553_rtSimStop(), and sepStr.

Referenced by ctdb_unit_test().

int co1553_rt_sim_test_sizeof ( void   ) 

Performs checks on return values from co1553_rt_sim sizeof library functions.

Return values:
0 Success.
-1 Failure

References CO1553_rtSimSizeof().

Referenced by ctdb_unit_test().

int co1553_rt_test_cmd_rx ( void   ) 

int co1553_rt_test_cmd_tx ( void   ) 

int co1553_rt_test_err ( void   ) 

Performs test of telecommand receive exception conditions.

Return values:
0 Success.
-1 Failure

References co1553_cmd_rx_msg_3, co1553_cmd_rx_msg_4, co1553_diag(), co1553_mem_copy(), CO1553_rtCmdRxExit(), CO1553_rtCmdRxInit(), CO1553_rtCmdRxMsg(), CO1553_rtCmdRxPktRecv(), CO1553_rtCmdRxSizeof(), diagLock, sepStr, and sepStr2.

Referenced by ctdb_unit_test().

int co1553_rt_test_param ( void   ) 

int co1553_rt_test_sizeof ( void   ) 

Performs checks on return values from co1553_rt sizeof library functions.

Return values:
0 Success.
-1 Failure

References CO1553_rtCmdRxSizeof(), CO1553_rtCmdTxSizeof(), and CO1553_rtTelemSizeof().

Referenced by ctdb_unit_test().

int co1553_rt_test_telem ( void   ) 


Variable Documentation

unsigned short co1553_cmd_rx_msg_0[]

A sample 1553 cmd receive message

Sample 1553 telecommand receive data message. Contains one CCSDS telecommand packet.

APID = 0x640, FC=0, SF=NONE, SC=0, LEN=32

Referenced by co1553_bc_test_cmd_rx(), and co1553_rt_test_cmd_rx().

unsigned short co1553_cmd_rx_msg_1[]

A sample 1553 cmd receive message

Sample 1553 telecommand receive data message. Contains one CCSDS telecommand packet.

APID = 0x641, FC=3, SF=FIRST, SC=10, LEN=54

Referenced by co1553_bc_test_cmd_rx(), and co1553_rt_test_cmd_rx().

unsigned short co1553_cmd_rx_msg_2[]

A sample 1553 cmd receive message

Sample 1553 telecommand receive data message. Contains one CCSDS telecommand packet.

APID = 0x642, FC=2, SF=NONE, SC=1, LEN=2

Referenced by co1553_bc_test_cmd_rx(), and co1553_rt_test_cmd_rx().

unsigned short co1553_cmd_rx_msg_3[]

A sample 1553 cmd receive message

Sample 1553 telecommand receive data message. Contains bogus information - no CCSDS packet header.

Referenced by co1553_rt_test_err().

unsigned short co1553_cmd_rx_msg_4[]

A sample 1553 cmd receive message

Sample 1553 telecommand receive data message. Contains one CCSDS telecommand packet with out of range length

APID = 0x642, FC=2, SF=NONE, SC=1, LEN=100

Referenced by co1553_rt_test_err().

unsigned short co1553_cmd_rx_pkt_0[]

A sample 1553 cmd receive packet

Sample CCSDS telecommand packet.

APID = 0x640, FC=0, SF=NONE, SC=0, LEN=32

Referenced by co1553_bc_test_cmd_rx(), and co1553_rt_test_cmd_rx().

The size in bytes of co1553_cmd_rx_pkt_0.

unsigned short co1553_cmd_rx_pkt_1[]

A sample 1553 cmd receive packet

Sample CCSDS telecommand packet.

APID = 0x641, FC=3, SF=FIRST, SC=10, LEN=54

Referenced by co1553_bc_test_cmd_rx(), and co1553_rt_test_cmd_rx().

The size in bytes of co1553_cmd_rx_pkt_1.

unsigned short co1553_cmd_rx_pkt_2[]

A sample 1553 cmd receive packet

Sample CCSDS telecommand packet.

APID = 0x642, FC=2, SF=NONE, SC=1, LEN=2

Referenced by co1553_bc_test_cmd_rx(), and co1553_rt_test_cmd_rx().

The size in bytes of co1553_cmd_rx_pkt_2.

unsigned short co1553_cmd_tx_msg_0[]

A sample cmd transmit msg

Sample 1553 telecommand transmit msg. Contains on CCSDS telecommand packet.

APID = 0x600, FC=0, SF=NONE, SC=0, LEN=32

Referenced by co1553_bc_test_cmd_tx(), and co1553_rt_test_cmd_tx().

unsigned short co1553_cmd_tx_msg_1[]

A sample cmd transmit msg

Sample 1553 telecommand transmit msg. Contains on CCSDS telecommand packet.

APID = 0x601, FC=3, SF=FIRST, SC=10, LEN=54

Referenced by co1553_bc_test_cmd_tx(), and co1553_rt_test_cmd_tx().

unsigned short co1553_cmd_tx_msg_2[]

A sample cmd transmit msg

Sample 1553 telecommand transmit msg. Contains on CCSDS telecommand packet.

APID = 0x602, FC=2, SF=NONE, SC=1, LEN=2

Referenced by co1553_bc_test_cmd_tx(), and co1553_rt_test_cmd_tx().

unsigned short co1553_cmd_tx_pkt_0[]

A sample cmd transmit packet

Sample 1553 telecommand transmit packet.

APID = 0x600, FC=0, SF=NONE, SC=0, LEN=32

Referenced by co1553_bc_test_cmd_tx(), and co1553_rt_test_cmd_tx().

The size of co1553_cmd_tx_pkt_0

The size in bytes of co1553_cmd_tx_pkt_0.

Referenced by co1553_rt_test_cmd_tx().

unsigned short co1553_cmd_tx_pkt_1[]

A sample cmd transmit packet

Sample 1553 telecommand transmit packet.

APID = 0x601, FC=3, SF=FIRST, SC=10, LEN=54

Referenced by co1553_bc_test_cmd_tx(), and co1553_rt_test_cmd_tx().

The size of co1553_cmd_tx_pkt_1

The size in bytes of co1553_cmd_tx_pkt_1.

Referenced by co1553_rt_test_cmd_tx().

unsigned short co1553_cmd_tx_pkt_2[]

A sample cmd transmit packet

Sample 1553 telecommand transmit packet.

APID = 0x602, FC=2, SF=NONE, SC=1, LEN=2

Referenced by co1553_bc_test_cmd_tx(), and co1553_rt_test_cmd_tx().

The size of co1553_cmd_tx_pkt_2

The size in bytes of co1553_cmd_tx_pkt_2.

Referenced by co1553_rt_test_cmd_tx().

unsigned short co1553_hkp_pkt_0[]

A sample houskeeping telemetry packet

Sample 1553 telemetry HKP packet.

APID = 0x210, SF=NONE, SC=1, LEN=102, SEC=100, SSEC=0

Referenced by co1553_bc_test_telem(), and co1553_hkp_0().

unsigned int co1553_hkp_pkt_0_size

The size of co1553_hkp_pkt_0

The size in bytes of co1553_hkp_pkt_0.

Referenced by co1553_hkp_0().

unsigned short co1553_hkp_pkt_1[]

A sample houskeeping telemetry packet

Sample 1553 telemetry HKP packet.

APID = 0x210, SF=NONE, SC=1, LEN=102, SEC=100, SSEC=0

Referenced by co1553_hkp_1().

unsigned int co1553_hkp_pkt_1_size

The size of co1553_hkp_pkt_1

The size in bytes of co1553_hkp_pkt_1.

Referenced by co1553_hkp_1().

unsigned short co1553_telem_msg_0[]

A sample telemetry message block.

Sample 1553 telemetry message block. Contains 2 CCSDS telemetry packets.

Referenced by co1553_bc_test_telem(), and co1553_rt_test_telem().

unsigned short co1553_telem_msg_1[]

A sample telemetry message block.

Sample 1553 telemetry message block. Contains 5 CCSDS telemetry packets.

Referenced by co1553_bc_test_telem(), and co1553_rt_test_telem().

unsigned short co1553_telem_msg_2[]

A sample telemetry message block.

Sample 1553 telemetry message block. Contains 2 CCSDS telemetry packets.

Referenced by co1553_rt_test_telem().

unsigned short co1553_telem_msg_3[]

A sample telemetry message block.

Sample 1553 telemetry message block. Contains 2 CCSDS telemetry packets.

Referenced by co1553_rt_test_telem().

unsigned short co1553_telem_pkt_0[]

A sample diagonostics telemetry packet

Sample 1553 telemetry packet.

APID = 0x260, SF=NONE, SC=5, LEN=800, SEC=400, SSEC=1000

Referenced by co1553_bc_test_telem(), and co1553_rt_test_telem().

The size of co1553_telem_pkt_0

The size in bytes of co1553_telem_pkt_0.

Referenced by co1553_rt_test_telem().

unsigned short co1553_telem_pkt_1[]

A sample diagonostics telemetry packet

Sample 1553 telemetry packet.

APID = 0x261, SF=MID, SC=20, LEN=20, SEC=500, SSEC=10000

Referenced by co1553_bc_test_telem(), and co1553_rt_test_telem().

The size of co1553_telem_pkt_1

The size in bytes of co1553_telem_pkt_1.

Referenced by co1553_rt_test_telem().

unsigned short co1553_telem_pkt_2[]

A sample diagonostics telemetry packet

Sample 1553 telemetry packet.

APID = 0x265, SF=LAST, SC=21, LEN=12, SEC=500, SSEC=100004

Referenced by co1553_bc_test_telem(), and co1553_rt_test_telem().

The size of co1553_telem_pkt_2

The size in bytes of co1553_telem_pkt_2.

Referenced by co1553_rt_test_telem().

RW_ctl diagLock

A RW lock for protecting diagnostics structure.

Referenced by co1553_rt_test_cmd_rx(), co1553_rt_test_cmd_tx(), co1553_rt_test_err(), co1553_rt_test_telem(), and ctdb_unit_test().

const char* sepStr

const char* sepStr2


Generated on Sat Apr 9 19:05:35 2011 by  doxygen 1.5.8