Main Page   Interface   Data Structures   File List   Data Fields   Globals  

BIUSIM.c File Reference

#include "stdio.h"
#include "string.h"
#include "netdb.h"
#include "sys/socket.h"
#include "sys/select.h"
#include "netinet/in.h"
#include "arpa/inet.h"
#include "ctype.h"
#include "BIU/BIUSIM.h"
#include "BIUD/BIUD_port.h"
#include "CCSDS/CCSDS_pkt.h"
#include "CCSDS/CCSDS_bfem.h"
#include "TRX/TRX_port.h"
#include "BIU_telem_private.h"

Functions

int BIUSIM_init (int argc, char **argv)
 Initialize application resources. More...

void BIUSIM_send (int size)
 Send a telemetry packet to the GSE host. More...

int main (int argc, char **argv)

Variables

unsigned short BIUSIM_pktBuf [BIU_TELEM_PKT_MAX_WORDS]
int BIUSIM_hkpRecvSocket
int BIUSIM_eventRecvSocket
int BIUSIM_sendSocket
sockaddr_in BIUSIM_sendAddr

Detailed Description


Function Documentation

int BIUSIM_init int    argc,
char **    argv
[static]
 

Initialize application resources.

This function peforms the following actions to setup the BIUSIM application for operation:

Parameters:
argc  The number of command line arguments.
argv  Pointers to the command line arguments.
Return values:
0  Success.
-1  Failure because a resource could not be created or initialized.

void BIUSIM_send int    size [static]
 

Send a telemetry packet to the GSE host.

After verification, sends the CCSDS telemetry packet in BIUSIM_pktBuf out on BIUSIM_sendSocket.

Parameters:
size  The packet size as reported by UDP.

int main int    argc,
char **    argv
 

After initializing resources, the main application function listens for incomming telemetry packets on BIUSIM_hkpRecvSocket. After verifcation, the CCSDS header is stripped and the packet data is written to BIUSIM_sendSocket.

Parameters:
argc  The number of command line arguments.
argv  Pointers to the command line arguments.


Variable Documentation

int BIUSIM_eventRecvSocket [static]
 

A UDP socket for receiving housekeeping event packets from the DAQ

int BIUSIM_hkpRecvSocket [static]
 

A UDP socket for receiving housekeeping telemetry packets from the DAQ

unsigned short BIUSIM_pktBuf[BIU_TELEM_PKT_MAX_WORDS] [static]
 

A buffer to receive incomming DAQ telemetry packets.

struct sockaddr_in BIUSIM_sendAddr [static]
 

A UDP/IP address structure for the GSE host machine.

int BIUSIM_sendSocket [static]
 

A UDP socket for sending telemetry packets to the GSE


Generated on Wed Mar 6 20:47:42 2002 by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002