lcls2
C++ API: public headers of xtcdata, psalg, psdaq and psana
Loading...
Searching...
No Matches
Pds::Xpm::XpmSequenceEngine Class Reference

SequenceEngine for one XPM sequence engine: encodes instructions into its sequence RAM and controls its enable, restart and start-address registers. More...

#include <XpmSequenceEngine.hh>

Inherits TPGen::SequenceEngine.

Public Member Functions

void enable (bool)
 Set or clear the bit of this engine in the sequence enable register.
 
int insertSequence (std::vector< TPGen::Instruction * > &seq)
 Encode seq into the smallest free RAM block that fits, remember it (the engine takes ownership of the instructions) and return its index (0 to 63).
 
int removeSequence (int seq)
 Free sequence seq: delete its instructions, write 0 to its first RAM word and forget it.
 
void setAddress (int seq, unsigned start=0, unsigned sync=1)
 If sequence seq exists, set the manual start address to its instruction start and the manual sync value to sync.
 
void reset ()
 Write the bit of this engine to the restart register.
 
void setMPSJump (int mps, int seq, unsigned pclass, unsigned start=0)
 Does nothing; empty body.
 
void setBCSJump (int seq, unsigned pclass, unsigned start=0)
 Does nothing; empty body.
 
void setMPSState (int mps, unsigned sync=1)
 Does nothing; empty body.
 
void handle (unsigned address)
 Does nothing; empty body.
 
TPGen::InstructionCache cache (unsigned index) const
 Return the RAM description of sequence index, or one with index -1 if it does not exist.
 
std::vector< TPGen::InstructionCache > cache () const
 Return the RAM descriptions of all stored sequences, including the two trap sequences made by the constructor.
 
void dumpSequence (int seq) const
 Print the RAM words of sequence seq; does nothing if seq is not in use.
 
void dump () const
 Print the request, invalid, address and condition registers of this engine and the RAM words of every sequence in use.
 
- Public Member Functions inherited from TPGen::SequenceEngine
virtual ~SequenceEngine ()
 Does nothing; empty virtual destructor.
 

Static Public Member Functions

static void verbosity (unsigned)
 Set the file-static verbosity of the engine code.
 

Protected Member Functions

 XpmSequenceEngine (void *, unsigned)
 
 ~XpmSequenceEngine ()
 

Protected Attributes

PrivateData * _private
 

Friends

class Module
 

Detailed Description

SequenceEngine for one XPM sequence engine: encodes instructions into its sequence RAM and controls its enable, restart and start-address registers.

Created through Module::sequenceEngine().

Constructor & Destructor Documentation

◆ XpmSequenceEngine()

Pds::Xpm::XpmSequenceEngine::XpmSequenceEngine ( void *  ,
unsigned   
)
protected

◆ ~XpmSequenceEngine()

Pds::Xpm::XpmSequenceEngine::~XpmSequenceEngine ( )
protected

Member Function Documentation

◆ cache() [1/2]

std::vector< TPGen::InstructionCache > Pds::Xpm::XpmSequenceEngine::cache ( ) const
virtual

Return the RAM descriptions of all stored sequences, including the two trap sequences made by the constructor.

Implements TPGen::SequenceEngine.

◆ cache() [2/2]

TPGen::InstructionCache Pds::Xpm::XpmSequenceEngine::cache ( unsigned  index) const
virtual

Return the RAM description of sequence index, or one with index -1 if it does not exist.

Implements TPGen::SequenceEngine.

◆ dump()

void Pds::Xpm::XpmSequenceEngine::dump ( ) const
virtual

Print the request, invalid, address and condition registers of this engine and the RAM words of every sequence in use.

Implements TPGen::SequenceEngine.

◆ dumpSequence()

void Pds::Xpm::XpmSequenceEngine::dumpSequence ( int  seq) const
virtual

Print the RAM words of sequence seq; does nothing if seq is not in use.

Implements TPGen::SequenceEngine.

◆ enable()

void Pds::Xpm::XpmSequenceEngine::enable ( bool  )

Set or clear the bit of this engine in the sequence enable register.

◆ handle()

void Pds::Xpm::XpmSequenceEngine::handle ( unsigned  address)

Does nothing; empty body.

◆ insertSequence()

int Pds::Xpm::XpmSequenceEngine::insertSequence ( std::vector< TPGen::Instruction * > &  seq)
virtual

Encode seq into the smallest free RAM block that fits, remember it (the engine takes ownership of the instructions) and return its index (0 to 63).

Returns -1 for a non-Expt request or no RAM space, -2 if all indices are used, -3 for a branch beyond the sequence.

Implements TPGen::SequenceEngine.

◆ removeSequence()

int Pds::Xpm::XpmSequenceEngine::removeSequence ( int  seq)
virtual

Free sequence seq: delete its instructions, write 0 to its first RAM word and forget it.

Returns 0, or -1 if seq is not in use, -2 if it is not found.

Implements TPGen::SequenceEngine.

◆ reset()

void Pds::Xpm::XpmSequenceEngine::reset ( )
virtual

Write the bit of this engine to the restart register.

Implements TPGen::SequenceEngine.

◆ setAddress()

void Pds::Xpm::XpmSequenceEngine::setAddress ( int  seq,
unsigned  start = 0,
unsigned  sync = 1 
)
virtual

If sequence seq exists, set the manual start address to its instruction start and the manual sync value to sync.

Implements TPGen::SequenceEngine.

◆ setBCSJump()

void Pds::Xpm::XpmSequenceEngine::setBCSJump ( int  seq,
unsigned  pclass,
unsigned  start = 0 
)
virtual

Does nothing; empty body.

Implements TPGen::SequenceEngine.

◆ setMPSJump()

void Pds::Xpm::XpmSequenceEngine::setMPSJump ( int  mps,
int  seq,
unsigned  pclass,
unsigned  start = 0 
)
virtual

Does nothing; empty body.

Implements TPGen::SequenceEngine.

◆ setMPSState()

void Pds::Xpm::XpmSequenceEngine::setMPSState ( int  mps,
unsigned  sync = 1 
)
virtual

Does nothing; empty body.

Implements TPGen::SequenceEngine.

◆ verbosity()

static void Pds::Xpm::XpmSequenceEngine::verbosity ( unsigned  )
static

Set the file-static verbosity of the engine code.

Friends And Related Symbol Documentation

◆ Module

friend class Module
friend

Member Data Documentation

◆ _private

PrivateData* Pds::Xpm::XpmSequenceEngine::_private
protected

The documentation for this class was generated from the following file: