GLAST/LAT > DAQ and FSW > FSW > Doxygen Index > PBC / V4-10-0

Constituent: pbc_scp     Tag: sun-gcc


Interface   Data Structures   File List   Data Fields   Globals  

PBC_scpside.c File Reference

SCP side of PBC command and telemetry handling. More...

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "MSG/MSG_pubdefs.h"
#include "CCSDS/CCSDS_pkt.h"
#include "CCSDS/CCSDS_swap.h"
#include "ITC/ITC_dump.h"
#include "ITC/ITC_pubdefs.h"
#include "PBC/PBC_dump.h"
#include "PBC/PBC_msgs.h"
#include "PBC/PBC_scpside.h"
#include "PBC/PBC_tlmdefs.h"
#include "PBS/BSWP.h"
#include "PBS/MBA.h"
#include "PBS/SPIN.h"
#include "BootDiagnostics.h"
#include "CLI/CLI_pubdefs.h"

Include dependency graph for PBC_scpside.c:


Typedefs

typedef void(* PBC_DumpCB )(char *pkt)
 PBC command dump callback pointer.

Functions

int PBC_setDisplayLevelCmd (int level)
 Set the verbosity level of the PBC command display.
int PBC_setDisplayLevelTlm (int level)
 Set the verbosity level of the PBC telemetry display.
unsigned int PBC_dispatchTlm (void *prm, unsigned char *pkt)
 Dispatch routine for arriving boot housekeeping telemetry.
static void pbc_free_cb (ITC_QueueItem *qitem_p, unsigned int status, void *parm_0, void *parm_1, void *parm_2, unsigned int tx)
 ITC callback to free command packet memory.
static unsigned int pbc_send_command (unsigned int num_parms, unsigned int *parm_bytes, unsigned int *parm_values, unsigned int func_code, PBC_DumpCB dump_func_p)
 Send a PBC command.
unsigned int PBC_sendBoot (unsigned short unit, unsigned short rtos, unsigned short ssb0, unsigned short ssb1)
 Send the Boot RTOS Execute command.
unsigned int PBC_sendErrDump (unsigned short unit)
 Send the Boot Error Dump command.
unsigned int PBC_sendReset (unsigned short unit, unsigned int flags)
 Send the Boot Reset command.
unsigned int PBC_sendStart (unsigned short unit)
 Send the Boot Start command.
static unsigned int PBC_sendBoot_cli (CLI_Control *cli, void *prm)
 CLI callback for the "PBC_sendBoot" command.
static unsigned int PBC_sendErrDump_cli (CLI_Control *cli, void *prm)
 CLI callback for the "PBC_sendErrDump" command.
static unsigned int PBC_sendReset_cli (CLI_Control *cli, void *prm)
 CLI callback for the "PBC_sendReset" command.
static unsigned int PBC_sendStart_cli (CLI_Control *cli, void *prm)
 CLI callback for the "PBC_sendStart" command.
static unsigned int PBC_setDisplayLevelCmd_cli (CLI_Control *cli, void *prm)
 CLI callback for the "PBC_setDisplayLevelCmd" command.
static unsigned int PBC_setDisplayLevelTlm_cli (CLI_Control *cli, void *prm)
 CLI callback for the "PBC_setDisplayLevelTlm" command.
static unsigned int PBC_setDumpDisplayLimit_cli (CLI_Control *cli, void *prm)
 CLI callback for the "PBC_setDumpDisplayLimit" command.
unsigned int PBC_addSyntaxSCP (CLI_Syntax *syntax)
 Add PBC commands to the command-line syntax.

Variables

int PBC_displayLevelCmd = 1
 The verbosity level of the PBC command display.
int PBC_displayLevelTlm = 4
 The verbosity level of the PBC telemetry display.

Detailed Description

SCP side of PBC command and telemetry handling.

  CVS $Id: PBC_scpside.c,v 1.15 2005/08/12 16:44:01 dmay Exp $
  

Send PBC commands and handle boot housekeeping telemetry.


Function Documentation

unsigned int PBC_addSyntaxSCP CLI_Syntax *  syntax  ) 
 

Add PBC commands to the command-line syntax.

Parameters:
syntax Syntax handle.
Returns:
MSG code.

unsigned int PBC_dispatchTlm void *  prm,
unsigned char *  pkt
 

Dispatch routine for arriving boot housekeeping telemetry.

Parameters:
prm User parameter (unused).
pkt Pointer to CCSDS packet.
Returns:
MSG code.

void pbc_free_cb ITC_QueueItem *  qitem_p,
unsigned int  status,
void *  parm_0,
void *  parm_1,
void *  parm_2,
unsigned int  tx
[static]
 

ITC callback to free command packet memory.

Parameters:
qitem_p Pointer to packet's queue item.
status Status of packet transmission.
parm_0 Callback parameter 0 - first item to free.
parm_1 Callback parameter 1 - second item to free.
parm_2 Callback parameter 2 - third item to free.
tx Flag indicating sender-side failure (unused).
Returns:
Nothing.

unsigned int pbc_send_command unsigned int  num_parms,
unsigned int *  parm_bytes,
unsigned int *  parm_values,
unsigned int  func_code,
PBC_DumpCB  dump_func_p
[static]
 

Send a PBC command.

Parameters:
num_parms Number of command parameters.
parm_bytes Pointer to array of parameter sizes, in bytes.
parm_values Pointer to array of parameter values.
func_code Function code of the command.
dump_func_p Pointer to function that dumps the command payload.
Return values:
0 Success.
Nonzero Failure.

unsigned int PBC_sendBoot unsigned short  unit,
unsigned short  rtos,
unsigned short  ssb0,
unsigned short  ssb1
 

Send the Boot RTOS Execute command.

Parameters:
unit LAT unit to receive the command (0 => SIU, 1 => EPU0, ...).
rtos Location of RTOS (0 => RAM, 1 => EE lower, 2 => EE upper).
ssb0 Location of SBC module 0 (0 => RAM, 1 => EE lower, ...).
ssb1 Location of SBC module 1 (0 => RAM, 1 => EE lower, ...).
Returns:
MSG code.

unsigned int PBC_sendBoot_cli CLI_Control *  cli,
void *  prm
[static]
 

CLI callback for the "PBC_sendBoot" command.

Parameters:
cli CLI control handle.
prm User parameter (unused).
Return values:
0 Success.
Nonzero Failure.

unsigned int PBC_sendErrDump unsigned short  unit  ) 
 

Send the Boot Error Dump command.

Parameters:
unit LAT unit to receive the command (0 => SIU, 1 => EPU0, ...).
Returns:
MSG code.

unsigned int PBC_sendErrDump_cli CLI_Control *  cli,
void *  prm
[static]
 

CLI callback for the "PBC_sendErrDump" command.

Parameters:
cli CLI control handle.
prm User parameter (unused).
Return values:
0 Success.
Nonzero Failure.

unsigned int PBC_sendReset unsigned short  unit,
unsigned int  flags
 

Send the Boot Reset command.

Parameters:
unit LAT unit to receive the command (0 => SIU, 1 => EPU0, ...).
flags Primary boot flags.
Returns:
MSG code.

unsigned int PBC_sendReset_cli CLI_Control *  cli,
void *  prm
[static]
 

CLI callback for the "PBC_sendReset" command.

Parameters:
cli CLI control handle.
prm User parameter (unused).
Return values:
0 Success.
Nonzero Failure.

unsigned int PBC_sendStart unsigned short  unit  ) 
 

Send the Boot Start command.

Parameters:
unit LAT unit to receive the command (0 => SIU, 1 => EPU0, ...).
Returns:
MSG code.

unsigned int PBC_sendStart_cli CLI_Control *  cli,
void *  prm
[static]
 

CLI callback for the "PBC_sendStart" command.

Parameters:
cli CLI control handle.
prm User parameter (unused).
Return values:
0 Success.
Nonzero Failure.

int PBC_setDisplayLevelCmd int  level  ) 
 

Set the verbosity level of the PBC command display.

Parameters:
level Level of verbosity - set higher to display more.
Returns:
Previous verbosity level.

unsigned int PBC_setDisplayLevelCmd_cli CLI_Control *  cli,
void *  prm
[static]
 

CLI callback for the "PBC_setDisplayLevelCmd" command.

Parameters:
cli CLI control handle.
prm User parameter (unused).
Return values:
0 Success.
Nonzero Failure.

int PBC_setDisplayLevelTlm int  level  ) 
 

Set the verbosity level of the PBC telemetry display.

Parameters:
level Level of verbosity - set higher to display more.
Returns:
Previous verbosity level.

unsigned int PBC_setDisplayLevelTlm_cli CLI_Control *  cli,
void *  prm
[static]
 

CLI callback for the "PBC_setDisplayLevelTlm" command.

Parameters:
cli CLI control handle.
prm User parameter (unused).
Return values:
0 Success.
Nonzero Failure.

unsigned int PBC_setDumpDisplayLimit_cli CLI_Control *  cli,
void *  prm
[static]
 

CLI callback for the "PBC_setDumpDisplayLimit" command.

Parameters:
cli CLI control handle.
prm User parameter (unused).
Return values:
0 Success.
Nonzero Failure.


Variable Documentation

int PBC_displayLevelCmd = 1
 

The verbosity level of the PBC command display.

This variable determines the amount of information that is displayed for each boot command that is sent. The higher the value, the more information that is displayed. Use PBC_setDisplayLevelCmd() to change this value.

int PBC_displayLevelTlm = 4
 

The verbosity level of the PBC telemetry display.

This variable determines the amount of information that is displayed for each boot housekeeping telemetry packet that is received. The higher the value, the more information that is displayed. Use PBC_setDisplayLevelTlm() to change this value.


Generated on Thu Nov 10 22:00:30 2005 by  doxygen 1.4.4