GLAST/LAT > DAQ and FSW > FSW > Doxygen Index > PIG / V8-8-0

Constituent: pig_lcb_init     Tag: rad750


Interface   Data Structures   File List   Data Fields   Globals  

lcb.c File Reference

Initialise the LCB driver. More...

#include "PIG/lcb.h"
#include "PIG/PIG_msgs.h"
#include "LEM/defs.h"
#include "LEM/msg_macros.h"
#include "LCBD/LCBD.h"
#include "MSG/MSG_pubdefs.h"
#include "PBS/MBA.h"
#include <stdio.h>
#include <string.h>

Include dependency graph for lcb.c:


Enumerations

enum  {
  LCBD_RST_PRIORITY = 65,
  LCBD_EVT_PRIORITY = 67,
  LCBD_NUT_PRIORITY = 69
}

Functions

static unsigned rst_queue_install (LCBD lcb, FORK_fcb **fcb)
 Create the result queue and install it in the LCBD.
static unsigned nut_queue_install (LCBD lcb, FORK_fcb **fcb)
 Create the clock notification queue and install it in the LCBD.
static unsigned evt_queue_install (LCBD lcb, FORK_fcb **fcb)
 Create the event queue and install it in the LCBD.
unsigned create_queue (FORK_fcb **fcb, const char *name, int priority, LCBD lcb, int que_cnt, const FORK_que_cfg *que_cfg, unsigned failure)
 Creates a FORK processing task.
void PIG_fabric_select (unsigned use_sec_dab)
 Select the primary or redundant fabric.
unsigned PIG_lcb_init (unsigned bit_wide)
unsigned PIG_lcb_complete ()
 Complete the LCB initialisation by enabling the clock and result interrupts, waiting for the LCB to come online and setting the board ID.

Detailed Description

Initialise the LCB driver.

Author:
James Swain - jswain@slac.stanford.edu

Function Documentation

unsigned create_queue FORK_fcb **  fcb,
const char *  name,
int  priority,
LCBD  lcb,
int  que_cnt,
const FORK_que_cfg *  que_cfg,
unsigned  failure
 

Creates a FORK processing task.

Returns:
Status
Parameters:
fcb Pointer to pointer to fork control block
name The name of the FORK task
priority The priority of the task
lcb Used as the callback parameter to the handler
que_cnt The number of queues to configure
que_cfg The configuration of each que
failure Status code to use in case of failure

unsigned evt_queue_install LCBD  lcb,
FORK_fcb **  fcb
[inline, static]
 

Create the event queue and install it in the LCBD.

Parameters:
lcb LCB driver control block
fcb Pointer to pointer to FORK function control block
Returns:
MSG error code

unsigned nut_queue_install LCBD  lcb,
FORK_fcb **  fcb
[inline, static]
 

Create the clock notification queue and install it in the LCBD.

Parameters:
lcb LCB driver control block
fcb Pointer to pointer to FORK function control block
Returns:
MSG error code

void PIG_fabric_select unsigned  use_sec_dab  ) 
 

Select the primary or redundant fabric.

Parameters:
use_sec_dab 0 if the primary fabric is to be used, non-zero otherwise

unsigned PIG_lcb_complete void   ) 
 

Complete the LCB initialisation by enabling the clock and result interrupts, waiting for the LCB to come online and setting the board ID.

Returns:
PIG_BADCPU If siu_id is not 0, 1 or 2, or an error from LCBD_load_wait or LCBD_csr_access

unsigned PIG_lcb_init unsigned  bit_wide  ) 
 

Parameters:
bit_wide 0 (byte wide) | 1 (bit wide)
Return values:
PIG_INMUD if all goes well
LCBD_ Another error code from the underlying LCBD functions

unsigned rst_queue_install LCBD  lcb,
FORK_fcb **  fcb
[inline, static]
 

Create the result queue and install it in the LCBD.

Parameters:
lcb LCB driver control block
fcb Pointer to pointer to FORK function control block
Returns:
MSG error code


Generated on Wed Feb 8 20:54:27 2006 by  doxygen 1.4.4