GLAST/LAT > DAQ and FSW > FSW > Doxygen Index > RIM / V1-0-0

Constituent: rim     Tag: mv2304


Interface   Data Structures   File List   Data Fields   Globals  

RIM_latp.c File Reference

Functions for performing LATp operations. More...

#include "RIM_p.h"
#include "RIM_AG_init_p.h"
#include "RIM_AG_descriptions_s.h"
#include "RIM_AG_addr_s.h"
#include "RIM_AG_fldEnums_s.h"
#include "RIM_AG_regEnums_s.h"
#include "RIM_number.ic"

Include dependency graph for RIM_latp.c:


Data Structures

struct  _RIM_regmod
 Register modification structure. More...

Typedefs

typedef _RIM_regmod RIM_regmod
 Register modification structure.

Functions

static unsigned traverseRead (RIM *rim, LEM_read *lem_r, RIM_type type, unsigned *index, RIM_addr *addr, unsigned depth, const RIM_map *ignore)
static unsigned traverseLoad (RIM *rim, LEM_load *lem_l, RIM_type type, unsigned *index, RIM_addr *addr, const RIM_regmod *reg, unsigned depth)
static unsigned loadLowSPT (LEM_load *lem_l, RIM_loadFn **loadFn, const RIM_addr *addr, short low)
static unsigned loadHighSPT (LEM_load *lem_l, RIM_loadFn **loadFn, const RIM_addr *addr, short high)
static unsigned loadSimple (RIM *rim, LEM_load *lem_l, RIM_type type, const RIM_regmod *reg)
static unsigned loadSplit (RIM *rim, LEM_load *lem_l, RIM_loadFn **loadFn)
static unsigned loadTracker (RIM *rim, LEM_load *lem_l, RIM_type type, const RIM_regmod *reg)
static unsigned loadCpt (RIM *rim, LEM_load *lem_l, RIM_type type, unsigned index, const RIM_addr *addr, const RIM_regmod *reg)
static unsigned readSimple (RIM *rim, LEM_read *lem_r, RIM_type type, const RIM_map *ignore)
static unsigned readSplit (RIM *rim, LEM_read *lem_r, const RIM_map *ignore)
static unsigned readTracker (RIM *rim, LEM_read *lem_r, RIM_type type, const RIM_map *ignore)
static unsigned readCpt (RIM *rim, LEM_read *lem_r, RIM_type type, unsigned index, const RIM_addr *addr)
unsigned RIM_read (RIM *rim, void *param, RIM_readFn **readFn, RIM_decodeFn **decodeFn, const RIM_map *ign)
 Populate the RIM structure with the current state of the LAT.
unsigned RIM_load (RIM *rim, void *param, RIM_loadFn **loadFn)
 Load the LAT with the configuration held in a RIM structure.
unsigned RIM_loadMdfy (RIM *rim, RIM_type type, unsigned regId, unsigned feMask, void *mask, void *value, void *param, RIM_loadFn **loadFn)
 Load all instances of a register with a modified version of its value in the LAT configuration.
void RIM_setSPT (void *ptr, unsigned short value, unsigned isHigh)
 Decode the result item use to populate a split.
void RIM_correct (RIM *orig, RIM *capt)
 Copy select portions of an original RIM into a copy, to ensure that the subsequent comparison will succeed.

Detailed Description

Functions for performing LATp operations.

Author:
James Swain & Owen Saxton
Id
RIM_latp.c,v 1.2 2007/03/22 23:49:18 saxton Exp

Function Documentation

void RIM_correct RIM orig,
RIM capt
 

Copy select portions of an original RIM into a copy, to ensure that the subsequent comparison will succeed.

Parameters:
orig Orignal RIM
capt New copy of the RIM (probably captured from the LAT)

unsigned RIM_load RIM rim,
void *  param,
RIM_loadFn **  loadFn
 

Load the LAT with the configuration held in a RIM structure.

Parameters:
rim Pointer to the RIM structure to populate from the LAT
param Pointer passed through to the loadRegFn
loadFn Type ordered array of pointers to functions that load the LAT registers

unsigned RIM_loadMdfy RIM rim,
RIM_type  type,
unsigned  regId,
unsigned  feMask,
void *  mask,
void *  value,
void *  param,
RIM_loadFn **  loadFn
 

Load all instances of a register with a modified version of its value in the LAT configuration.

This routine, in its simplest form, allows all registers of a single component of the configuration to be written to the LAT. Additionally this may be further restricted to a single register of that component. In this case, each instance of the register may also have its value modified by a supplied value under a supplied mask. Furthermore, if the register is a front-end one (AFE, CFE or TFE), the modification can be optionally restricted to only those front-ends with a corresponding bit set in the supplied front-end mask.

Parameters:
rim Pointer to the cached in-memory model of the LAT registers
type The type (from RIM/RIM_AG_types.h) of the component to be loaded.
regId The hardware ID of the register being loaded, or RIM_BCAST_ADDR if all registers are to be loaded unmodified.
feMask If the specified register is a front-end register, restricts the modification to only those front-ends with bits set in this mask. The value -1 indicates in an optimal way that all front-ends are modified.
mask The address of the bit mask of the fields of the register being replaced
value The address of the value to use in place of the masked part of the register
param Parameter passed through to the load function
loadFn Type ordered array of pointers to functions that load the LAT registers

unsigned RIM_read RIM rim,
void *  param,
RIM_readFn **  readFn,
RIM_decodeFn **  decodeFn,
const RIM_map ign
 

Populate the RIM structure with the current state of the LAT.

Parameters:
rim Pointer to the RIM structure to populate from the LAT
param Pointer passed through to the readRegFn
readFn Type ordered array of pointers to functions that read the LAT registers
decodeFn Type ordered array of pointers to functions that decode the register responses
ign Map of the sections of the LAT known to be bad or not present so can be ignored.

void RIM_setSPT void *  ptr,
unsigned short  value,
unsigned  isHigh
 

Decode the result item use to populate a split.

Parameters:
ptr Pointer to memory location to put decoded value
value One of the split fields
isHigh Indicates which of the split fields this is


Generated on Fri Jun 15 02:02:44 2007 by  doxygen 1.4.4