CCAENV560 Class Reference

#include <CCAENV560.h>

List of all members.

Public Member Functions

 CCAENV560 (unsigned long base, int crate=0) throw (STD(string))
 ~CCAENV560 ()
int getCrate () const
int getModuleType () const
int getVersion () const
int getSerial () const
void setCrate (int crate)
bool GetSectStat (int nSection) throw (STD(string))
void ScalInc ()
void SetVeto ()
void ResetVeto ()
void Clear ()
bool GetVetoStat ()
int ReadCounter (int nChannel) throw (STD(string))

Protected Member Functions

void ComputeEventSize ()
void MapModule () throw (STD(string))
void InitModule ()
void UnmapModule ()

Private Member Functions

 CCAENV560 (const CCAENV560 &rhs)
CCAENV560operator= (const CCAENV560 &rhs)
int operator== (const CCAENV560 &rhs) const
int operator!= (const CCAENV560 &rhs) const

Private Attributes

int m_nCrate
int m_nBase
CVmeModulem_pModule
int m_nModuleType
int m_nSerialno
int m_nVersion


Detailed Description

Encapsulates the readout driver for a CCAENV560 scaler. This class was contributed by Kevin Carnes, Kansas State University. Only minor modifications have been made from the original. I believe that due to the use of the CVmeModule abstraction of the VME, this should be vme bus controller inependent.

Summary of changes at the NSCL:

Definition at line 337 of file CCAENV560.h.


Constructor & Destructor Documentation

CCAENV560::CCAENV560 ( unsigned long  base,
int  crate = 0 
) throw (STD(string))

Make a new CCAENV560 module. This involves:

Definition at line 353 of file CCAENV560.cpp.

CCAENV560::~CCAENV560 (  ) 

Destroy a VME module; the address map created is deleted.

Definition at line 371 of file CCAENV560.cpp.

References UnmapModule().

CCAENV560::CCAENV560 ( const CCAENV560 rhs  )  [private]


Member Function Documentation

CCAENV560& CCAENV560::operator= ( const CCAENV560 rhs  )  [private]

int CCAENV560::operator== ( const CCAENV560 rhs  )  const [private]

int CCAENV560::operator!= ( const CCAENV560 rhs  )  const [private]

int CCAENV560::getCrate (  )  const [inline]

Definition at line 369 of file CCAENV560.h.

References m_nCrate.

int CCAENV560::getModuleType (  )  const [inline]

Definition at line 372 of file CCAENV560.h.

References m_nModuleType.

int CCAENV560::getVersion (  )  const [inline]

Definition at line 375 of file CCAENV560.h.

References m_nVersion.

int CCAENV560::getSerial (  )  const [inline]

Definition at line 379 of file CCAENV560.h.

References m_nSerialno.

void CCAENV560::setCrate ( int  crate  )  [inline]

Definition at line 385 of file CCAENV560.h.

References m_nCrate.

bool CCAENV560::GetSectStat ( int  nSection  )  throw (STD(string))

Get the scale status (bit=0, two 32-bit scales, bit=1, one 64 bit) of one of the 8 sections of the module; each representing a pair of scalers.

Parameters:
nSection (in): Number of section to check status of [0-7].

Definition at line 389 of file CCAENV560.cpp.

References GetShort, SSRMask, and ThrowIfBadSection().

void CCAENV560::ScalInc (  ) 

Increment all counters by 1. Simple VME access (r or w) to address.

Definition at line 400 of file CCAENV560.cpp.

References GetShort.

void CCAENV560::SetVeto (  ) 

Set the VME VETO, preventing counters from counting. Simple VME access.

Definition at line 409 of file CCAENV560.cpp.

References GetShort.

Referenced by InitModule().

void CCAENV560::ResetVeto (  ) 

Reset (clear) the VME VETO, allowing the counters to count. Simple VME access.

Definition at line 419 of file CCAENV560.cpp.

References GetShort.

void CCAENV560::Clear (  ) 

Clear all scalers, remove VME interrupt request if asserted, disable VME interrupt generation. Simple VME access.

Definition at line 429 of file CCAENV560.cpp.

References GetShort.

Referenced by InitModule().

bool CCAENV560::GetVetoStat (  ) 

Get latched status of VETO from last counter read

Definition at line 439 of file CCAENV560.cpp.

References GetShort, and Vetostat.

int CCAENV560::ReadCounter ( int  nChannel  )  throw (STD(string))

Read an individual instantaneous scaler channel.

Parameters:
nChannel (int in): Number of channel to read must be in the range [0,15].
Returns:
int Instantaneous value of the counter for the selected channel.
Exceptions:
string If nChannel is invalid, an explanatory string exception is thrown.

Definition at line 525 of file CCAENV560.cpp.

References GetLong, and msg.

void CCAENV560::ComputeEventSize (  )  [protected]

void CCAENV560::MapModule (  )  throw (STD(string)) [protected]

Map the vme module. This involves:

Definition at line 454 of file CCAENV560.cpp.

References CVmeModule::a32d32, FixedCode(), GetShort, m_nBase, m_nCrate, m_nModuleType, m_nSerialno, m_nVersion, m_pModule, Manufacturer(), MIMfrNo, MIModTyp, MISN, MIVer, ModelNumber(), and ThrowIntString().

void CCAENV560::InitModule (  )  [protected]

Setup the initial module state. The default setup is:

Definition at line 497 of file CCAENV560.cpp.

References Clear(), and SetVeto().

void CCAENV560::UnmapModule (  )  [protected]

Destroy any memory map held on the module:

Definition at line 509 of file CCAENV560.cpp.

References m_pModule.

Referenced by ~CCAENV560().


Member Data Documentation

int CCAENV560::m_nCrate [private]

Definition at line 342 of file CCAENV560.h.

Referenced by getCrate(), MapModule(), and setCrate().

int CCAENV560::m_nBase [private]

Definition at line 343 of file CCAENV560.h.

Referenced by MapModule().

CVmeModule* CCAENV560::m_pModule [private]

Definition at line 344 of file CCAENV560.h.

Referenced by MapModule(), and UnmapModule().

int CCAENV560::m_nModuleType [private]

Definition at line 345 of file CCAENV560.h.

Referenced by getModuleType(), and MapModule().

int CCAENV560::m_nSerialno [private]

Definition at line 346 of file CCAENV560.h.

Referenced by getSerial(), and MapModule().

int CCAENV560::m_nVersion [private]

Definition at line 347 of file CCAENV560.h.

Referenced by getVersion(), and MapModule().


The documentation for this class was generated from the following files:
Generated on Wed Sep 17 08:38:11 2008 for NSCL Device support. by  doxygen 1.5.1