JAPAn
Just Another Parity Analyzer
Loading...
Searching...
No Matches
QwModChannelID Class Reference

Mapping information for beam modulation channels. More...

#include <QwBeamMod.h>

Public Member Functions

 QwModChannelID (Int_t subbankid, Int_t wordssofar, TString name, TString modtype, QwBeamMod *obj)
 
 QwModChannelID (Int_t subbankid, QwParameterFile &paramfile)
 
void Print ()
 

Data Fields

Int_t fSubbankIndex
 
Int_t fWordInSubbank
 
TString fmoduletype
 
TString fmodulename
 
Int_t modnum
 
Int_t channum
 
Int_t kUnknownDeviceType
 
Int_t fTypeID
 
Int_t fIndex
 

Detailed Description

Mapping information for beam modulation channels.

Definition at line 44 of file QwBeamMod.h.

Constructor & Destructor Documentation

◆ QwModChannelID() [1/2]

QwModChannelID::QwModChannelID ( Int_t subbankid,
Int_t wordssofar,
TString name,
TString modtype,
QwBeamMod * obj )

◆ QwModChannelID() [2/2]

QwModChannelID::QwModChannelID ( Int_t subbankid,
QwParameterFile & paramfile )

Definition at line 240 of file QwBeamMod.cc.

241 :
242 fSubbankIndex(subbankid), fIndex(-1)
243{
244
245 fmoduletype = paramfile.GetTypedNextToken<TString>();
246 modnum = paramfile.GetTypedNextToken<Int_t>(); //slot number
247 channum = paramfile.GetTypedNextToken<Int_t>(); //channel number
248 // fdetectortype = paramfile.GetTypedNextToken<TString>(); //type-purpose of the detector
249 fmodulename = paramfile.GetTypedNextToken<TString>(); //name of the detector
250 fmoduletype.ToUpper();
251 // fdetectortype.ToLower();
252 fmodulename.ToLower();
253
254 Int_t offset;
255 if (fmoduletype == "VQWK") {
257 if (paramfile.ReturnValue("vqwk_buffer_offset",offset)) {
258 fWordInSubbank += offset;
259 }
260 // } else if (fmoduletype == "ADC18") {
261 //fWordInSubbank = QwADC18_Channel::GetBufferOffset(modnum, channum);
262 //if (paramfile.ReturnValue("adc18_buffer_offset",offset)) {
263 // fWordInSubbank += offset;
264 // }
265 } else if (fmoduletype == "SCALER"|| fmoduletype == "SIS3801D24" || fmoduletype == "SIS3801D32" ) {
267 if (paramfile.ReturnValue("scaler_buffer_offset",offset)) {
268 fWordInSubbank += offset;
269 }
270 } else {
271 fWordInSubbank = -1;
272 }
273}
T GetTypedNextToken()
Get next token into specific type.
Bool_t ReturnValue(const std::string keyname, T &retvalue)
static Int_t GetBufferOffset(Int_t scalerindex, Int_t wordindex, UInt_t header=1)
static Int_t GetBufferOffset(Int_t moduleindex, Int_t channelindex)
Int_t fWordInSubbank
Definition QwBeamMod.h:60
TString fmodulename
Definition QwBeamMod.h:67
Int_t fSubbankIndex
Definition QwBeamMod.h:59
TString fmoduletype
Definition QwBeamMod.h:66

References channum, fIndex, fmodulename, fmoduletype, fSubbankIndex, fWordInSubbank, QwVQWK_Channel::GetBufferOffset(), VQwScaler_Channel::GetBufferOffset(), QwParameterFile::GetTypedNextToken(), modnum, and QwParameterFile::ReturnValue().

+ Here is the call graph for this function:

Member Function Documentation

◆ Print()

void QwModChannelID::Print ( )

Definition at line 893 of file QwBeamMod.cc.

894{
895 QwMessage <<std::endl<<"Detector name= "<<fmodulename<<QwLog::endl;
896 QwMessage <<"SubbankkIndex= "<<fSubbankIndex<<QwLog::endl;
897 QwMessage <<"word index in subbank= "<<fWordInSubbank<<QwLog::endl;
898 QwMessage <<"module type= "<<fmoduletype<<QwLog::endl;
899// QwMessage <<"detector type= "<<fdetectortype<<" that is index="<<fTypeID<<QwLog::endl;
900 QwMessage <<"Index of this detector in the vector of similar detector= "<<
902//QwMessage <<"Subelement index= "<< fSubelement<<QwLog::endl;
903
904
905 QwMessage << "---------------------------------------------------" << QwLog::endl;
907}
#define QwMessage
Predefined log drain for regular messages.
Definition QwLog.h:49
static std::ostream & endl(std::ostream &)
End of the line.
Definition QwLog.cc:297

References QwLog::endl(), fIndex, fmodulename, fmoduletype, fSubbankIndex, fWordInSubbank, and QwMessage.

Referenced by QwBeamMod::LoadChannelMap().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Field Documentation

◆ channum

Int_t QwModChannelID::channum

Definition at line 69 of file QwBeamMod.h.

Referenced by QwModChannelID().

◆ fIndex

Int_t QwModChannelID::fIndex

Definition at line 75 of file QwBeamMod.h.

Referenced by QwBeamMod::LoadChannelMap(), Print(), and QwModChannelID().

◆ fmodulename

TString QwModChannelID::fmodulename

Definition at line 67 of file QwBeamMod.h.

Referenced by QwBeamMod::LoadChannelMap(), Print(), and QwModChannelID().

◆ fmoduletype

TString QwModChannelID::fmoduletype

Definition at line 66 of file QwBeamMod.h.

Referenced by QwBeamMod::LoadChannelMap(), Print(), and QwModChannelID().

◆ fSubbankIndex

Int_t QwModChannelID::fSubbankIndex

Definition at line 59 of file QwBeamMod.h.

Referenced by Print(), and QwModChannelID().

◆ fTypeID

Int_t QwModChannelID::fTypeID

Definition at line 74 of file QwBeamMod.h.

◆ fWordInSubbank

Int_t QwModChannelID::fWordInSubbank

Definition at line 60 of file QwBeamMod.h.

Referenced by Print(), and QwModChannelID().

◆ kUnknownDeviceType

Int_t QwModChannelID::kUnknownDeviceType

Definition at line 73 of file QwBeamMod.h.

◆ modnum

Int_t QwModChannelID::modnum

Definition at line 68 of file QwBeamMod.h.

Referenced by QwBeamMod::LoadChannelMap(), and QwModChannelID().


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