GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> ITC / V3-9-2 > itc_dump / rad750
#include <stdio.h>
#include <time.h>
#include <PBI/Endianness.h>
#include <PBS/BSWP.h>
#include <PBS/BSWP.ih>
#include <PBS/WCT.h>
#include <CCSDS/CCSDS_pkt.h>
#include <ITC/ITC_dump.h>
#include <ITC/ITC_pubdefs.h>
Classes | |
struct | _ITC_PrimaryCtl_bf |
Define bitfields for a CCSDS primary header (first two bytes). More... | |
union | _ITC_PrimaryCtl |
Union CCSDS header bitfields (first two bytes) with an unsigned short. More... | |
struct | _ITC_PrimarySeq_bf |
Define bitfields for a CCSDS primary header (second two bytes). More... | |
union | _ITC_PrimarySeq |
Union CCSDS header bitfields (second two bytes) with an unsigned short. More... | |
struct | _ITC_SecondaryCmd_bf |
Define bitfields for a CCSDS secondary header (telecommand). More... | |
union | _ITC_SecondaryCmd |
Union CCSDS header bitfields (two bytes) with an unsigned short. More... | |
struct | _ITC_CmdHeader |
Structure to define the CCSDS telecommand primary/secondary headers. More... | |
struct | _ITC_TlmHeader |
Structure to define the CCSDS telemetry primary/secondary headers. More... | |
Typedefs | |
typedef struct _ITC_PrimaryCtl_bf | ITC_PrimaryCtl_bf |
Typedef for struct _ITC_PrimaryCtl_bf. | |
typedef union _ITC_PrimaryCtl | ITC_PrimaryCtl |
Typedef for struct _ITC_PrimaryCtl. | |
typedef struct _ITC_PrimarySeq_bf | ITC_PrimarySeq_bf |
Typedef for struct _ITC_PrimarySeq_bf. | |
typedef union _ITC_PrimarySeq | ITC_PrimarySeq |
Typedef for struct _ITC_PrimarySeq. | |
typedef struct _ITC_SecondaryCmd_bf | ITC_SecondaryCmd_bf |
Typedef for struct _ITC_SecondaryCmd_bf. | |
typedef union _ITC_SecondaryCmd | ITC_SecondaryCmd |
Typedef for struct _ITC_SecondaryCmd. | |
typedef struct _ITC_CmdHeader | ITC_CmdHeader |
Typedef for struct _ITC_CmdHeader. | |
typedef struct _ITC_TlmHeader | ITC_TlmHeader |
Typedef for struct _ITC_TlmHeader. | |
Functions | |
static void | dumpBoiler (void) |
Dump a boilerplate title. | |
static void | dumpHeader (const unsigned char *pkt, unsigned int off) |
Dump a CCSDS packet header. | |
void | ITC_dumpHeader (const unsigned char *pkt) |
Dump a CCSDS packet header. | |
void | ITC_dumpPayload (const unsigned char *pkt) |
Dump a CCSDS payload as a simple string of bytes (endianness unknown). | |
void | ITC_dumpChecksum (const unsigned char *pkt) |
Dump a CCSDS telecommand packet checksum. | |
void | ITC_dumpComplete () |
Rule off a dump. | |
void | ITC_dumpResponse (const unsigned char *pkt) |
Dump a CCSDS telecommand command-response payload. |
CVS $Id: ITC_dump.c,v 1.8 2011/03/25 21:01:10 apw Exp $
void dumpBoiler | ( | void | ) | [static] |
Dump a boilerplate title.
dumpBioler() prints a boilerplate titling line
Referenced by ITC_dumpChecksum(), ITC_dumpHeader(), ITC_dumpPayload(), and ITC_dumpResponse().
static void dumpHeader | ( | const unsigned char * | pkt, | |
unsigned int | off | |||
) | [static] |
Dump a CCSDS packet header.
ITC_dumpHeader() assumes that pkt points to a CCSDS packet in machine local byte order.
References _ITC_PrimaryCtl_bf::apid, _ITC_SecondaryCmd::bf, _ITC_PrimarySeq::bf, _ITC_PrimaryCtl::bf, _ITC_CmdHeader::cmd, _ITC_PrimarySeq_bf::cnt, _ITC_CmdHeader::ctl, _ITC_PrimarySeq_bf::flg, _ITC_SecondaryCmd_bf::fnc, _ITC_CmdHeader::len, _ITC_SecondaryCmd_bf::mbz, _ITC_TlmHeader::secl, _ITC_TlmHeader::secm, _ITC_CmdHeader::seq, _ITC_PrimaryCtl_bf::shdr, _ITC_TlmHeader::subl, _ITC_TlmHeader::subm, _ITC_PrimaryCtl_bf::type, and _ITC_PrimaryCtl_bf::ver.
Referenced by ITC_dumpHeader(), and ITC_dumpResponse().
void ITC_dumpChecksum | ( | const unsigned char * | pkt | ) |
Dump a CCSDS telecommand packet checksum.
ITC_dumpChecksum() assumes that pkt points to a CCSDS packet in machine local byte order (or more specifically, that the checksum is in machine local order).
References _ITC_PrimaryCtl::bf, _ITC_CmdHeader::ctl, dumpBoiler(), _ITC_CmdHeader::len, and _ITC_PrimaryCtl_bf::type.
void ITC_dumpHeader | ( | const unsigned char * | pkt | ) |
Dump a CCSDS packet header.
ITC_dumpHeader() assumes that pkt points to a CCSDS packet in machine local byte order (or more specifically, that the header is in machine local order).
References dumpBoiler(), and dumpHeader().
void ITC_dumpResponse | ( | const unsigned char * | pkt | ) |
Dump a CCSDS telecommand command-response payload.
This dump is a little out of the ordinary, because it's a payload dump. This routine therefore assumes that the payload has been presented in network (big-endian) byte order.
References dumpBoiler(), and dumpHeader().