CFEL - ASG Software Suite  2.5.0
CASS
Public Types | Public Member Functions | Private Attributes | List of all members
cass::ACQIRIS::SignalProducer Class Reference

A Signal Producer. More...

#include <signal_producer.h>

+ Collaboration diagram for cass::ACQIRIS::SignalProducer:

Public Types

typedef std::vector< double > signal_t
 
typedef std::vector< signal_tsignals_t
 

Public Member Functions

 SignalProducer ()
 default constructor More...
 
void loadSettings (CASSSettings &s)
 loads the settings. More...
 
void associate (const CASSEvent &evt)
 assciate the event with this signalproducer More...
 
double firstGood (const std::pair< double, double > &range)
 returns the time of the first peak in the time range More...
 
double firstGood ()
 returns the time of the first peak in the time range More...
 
signals_toutput ()
 return the signals More...
 

Private Attributes

double _goodHit
 time of the first peak in the "good" range More...
 
std::tr1::shared_ptr< SignalExtractor_signalextractor
 the extractor of the produced signals More...
 
signals_t _signals
 the signals produces by this producer More...
 
bool _newEventAssociated
 flag to show whether there is a new event associated whith this signal producer More...
 
bool _goodHitExtracted
 flag to show whether the first good hit has been extracted More...
 
std::pair< double, double > _range
 the range in which the good hits will appear More...
 

Detailed Description

A Signal Producer.

This class describes all signal producing elements of a detector. It contains an extractor for the produced signals from the event and a list of the signals it produced.

User settable parameters via CASS.ini

Then the specific settings for these objects are:

User definable Parameters:

.../{SignalExtractionMethod}
the method type that will be used to extract the signals from the recorded data. To see what options need to be set for the specific signalextraction methods description. There are the following options :

.../{GoodRangeLow|GoodRangeHigh}
The lower an upper boundaries of the range where good single hits appear in. Default is 0.

Author
Lutz Foucar

Definition at line 59 of file signal_producer.h.

Member Typedef Documentation

typedef std::vector<double> cass::ACQIRIS::SignalProducer::signal_t

Definition at line 62 of file signal_producer.h.

Definition at line 63 of file signal_producer.h.

Constructor & Destructor Documentation

cass::ACQIRIS::SignalProducer::SignalProducer ( )
inline

default constructor

Definition at line 67 of file signal_producer.h.

Member Function Documentation

void SignalProducer::associate ( const CASSEvent evt)

assciate the event with this signalproducer

resets the _newEventAssociated flag to true, clears the _signals vector and associates the event with the signalextractor. See the signal extractors associate() member function for further information.

Parameters
evtthe event that we need to associate with the signalextractor

Definition at line 65 of file signal_producer.cpp.

Referenced by cass::ACQIRIS::TofDetector::associate().

double SignalProducer::firstGood ( const std::pair< double, double > &  range)

returns the time of the first peak in the time range

when the _newEventAssociated flag is true it will look for the first signal whos time is in the requested time range. If there is no signal in the requested timerange the value is set to 0.

Returns
time of the first singal in the requested timerange
Parameters
rangethe timerange to search for the signal

Definition at line 74 of file signal_producer.cpp.

References cass::ACQIRIS::time.

Referenced by cass::HexCalibrator::process(), cass::pp162::process(), cass::pp163::process(), and cass::pp164::process().

double SignalProducer::firstGood ( )

returns the time of the first peak in the time range

when the _newEventAssociated flag is true it will look for the first signal whos time is in the requested time range. If there is no signal in the requested timerange the value is set to 0. It will use the range that is set inside.

Returns
the time of the first good peak

Definition at line 86 of file signal_producer.cpp.

References cass::ACQIRIS::time.

void SignalProducer::loadSettings ( CASSSettings s)

loads the settings.

will load the the requested SignalExtractor by calling SignalExtractor::instance(). And then loads its settings. Please refer the the chosen signal extractors loadSettings memeber for further information.
See class describtion for the type of signalextractor that can be chosen.

Parameters
sthe CASSSettings object we retrieve the data from

Definition at line 48 of file signal_producer.cpp.

References cass::ACQIRIS::com16, cass::ACQIRIS::SignalExtractor::instance(), and QSettings::value().

SignalProducer::signals_t & SignalProducer::output ( )

return the signals

When a new event was associated with this prodcuer, then it will first extract all signals from the event data otherwise it will just return the signals. It will extract the events from the data with the help of the _singalExtractor object that this class owns. This is done by calling the singalextractos operator().

Note
the output of a signal producer are the singals. Unfortunately if we call this function signals it will not compile anymore.
Returns
reference to the singals of this signalproducer

Definition at line 58 of file signal_producer.cpp.

Referenced by cass::pp150::process(), cass::pp5001::process(), cass::pp151::process(), cass::pp152::process(), cass::pp153::process(), and cass::pp220::process().

Member Data Documentation

double cass::ACQIRIS::SignalProducer::_goodHit
private

time of the first peak in the "good" range

Definition at line 137 of file signal_producer.h.

bool cass::ACQIRIS::SignalProducer::_goodHitExtracted
private

flag to show whether the first good hit has been extracted

Definition at line 149 of file signal_producer.h.

bool cass::ACQIRIS::SignalProducer::_newEventAssociated
private

flag to show whether there is a new event associated whith this signal producer

Definition at line 146 of file signal_producer.h.

std::pair<double, double> cass::ACQIRIS::SignalProducer::_range
private

the range in which the good hits will appear

Definition at line 152 of file signal_producer.h.

std::tr1::shared_ptr<SignalExtractor> cass::ACQIRIS::SignalProducer::_signalextractor
private

the extractor of the produced signals

Definition at line 140 of file signal_producer.h.

signals_t cass::ACQIRIS::SignalProducer::_signals
private

the signals produces by this producer

Definition at line 143 of file signal_producer.h.


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