Main Page | Class List | Class Members

hcalDCC::Memory Class Reference

Instances of this class correspond to a requested or allocated memory region of a PCI device (Memory, Fast Memory or I/O). More...

#include <memory.hh>

List of all members.

Public Types

typedef enum hcalDCC::Memory::_MEMTYPE MEMTYPE
enum  _MEMTYPE

Public Member Functions

 Memory (MEMTYPE type, unsigned int barOffs, unsigned int size, unsigned int memAlnt, bool debug=0)
 ~Memory ()
const char * getType_s () const
const MEMTYPE getType () const
const unsigned int getBarOffset () const
const unsigned int getOffset () const
const unsigned int getSize () const
const unsigned int getAlignment () const
void setOffset (unsigned int offs)
void setSize (unsigned int size)


Detailed Description

Instances of this class correspond to a requested or allocated memory region of a PCI device (Memory, Fast Memory or I/O).

Author:
Fernando Varela (Boston University)
Revision
1.1

Date
2005/04/29 19:52:42


Member Typedef Documentation

typedef enum hcalDCC::Memory::_MEMTYPE hcalDCC::Memory::MEMTYPE
 

Definition of the memory types:

  • undef: Undefined
  • mem: PCI memory space accesible via single transfers
  • fmem: PCI memory space accessible via single and block transfers
  • io: PCI I/O space


Member Enumeration Documentation

enum hcalDCC::Memory::_MEMTYPE
 

Definition of the memory types:

  • undef: Undefined
  • mem: PCI memory space accesible via single transfers
  • fmem: PCI memory space accessible via single and block transfers
  • io: PCI I/O space


Constructor & Destructor Documentation

hcalDCC::Memory::Memory MEMTYPE  type,
unsigned int  barOffs,
unsigned int  size,
unsigned int  memAlnt,
bool  debug = 0
 

Memory class constructor to set up memory objects

Parameters:
type defines the type of memory object according to the list previously defined
barOffs is the PCI Base Address Register (BAR) offset as a unsigned int
size is the size of the memory region as a unsigned int
memAlnt is the PCI memory region alignment as a unsigned int
debug is a debugging flag. Prints out complementary information if set to 1. Default value is 0.

hcalDCC::Memory::~Memory  ) 
 

Memory class destructor


Member Function Documentation

const unsigned int hcalDCC::Memory::getAlignment  )  const [inline]
 

These methods return the alignment of the memory region

Returns:
Memory region alignment as a unsigned int

const unsigned int hcalDCC::Memory::getBarOffset  )  const [inline]
 

These methods provide the PCI BAR offset of the current memory region

Returns:
Base Address Register Offset as a unsigned int

const unsigned int hcalDCC::Memory::getOffset  )  const [inline]
 

These methods return the memory region offset with respect to the corresponding VSI base address

Returns:
Memory region offset w.r.t VSI base address as a unsigned int

const unsigned int hcalDCC::Memory::getSize  )  const [inline]
 

These methods return the size of the memory region

Returns:
Memory region size as a unsigned int

const MEMTYPE hcalDCC::Memory::getType  )  const [inline]
 

Returns the memory type as MEMTYPE

Returns:
MEMTYPE

const char * hcalDCC::Memory::getType_s  )  const
 

Returns the memory type as char * (string)

Returns:
Memory type: "undef", "mem", "fmem" or "io" as a const char*

void hcalDCC::Memory::setOffset unsigned int  offs  )  [inline]
 

This methods sets the offset of the memory region w.r.t the corresponding VSI VME base address

Parameters:
offs is the new value of the memory region offset as a unsigned int

void hcalDCC::Memory::setSize unsigned int  size  )  [inline]
 

This method sets the size of the memory region

Parameters:
size is the new value of the memory region size as a unsigned int


The documentation for this class was generated from the following files:
Generated on Fri Jul 8 20:52:05 2005 for HCAL Data Concentrator Card by  doxygen 1.3.9.1