4#include "KVFAZIADetector.h"
5#include "KVIDTelescope.h"
180 Info(
"SetProperties",
"Unkown format for the detector %s",
GetName());
189 lsignals =
"QH1,I1,QL1";
191 else if (!strcmp(
GetLabel(),
"SI2")) {
194 else if (!strcmp(
GetLabel(),
"CSI")) {
196 dsigs +=
",Q3.FastAmplitude,Q3.FastFPGAEnergy";
203 KVString sigtypes =
"Amplitude,RawAmplitude,FPGAEnergy,RiseTime,BaseLine,SigmaBaseLine";
205 while (!lsignals.
End()) {
208 while (!sigtypes.
End()) {
210 if (sig.
BeginsWith(
"I") && (stype ==
"FPGAEnergy" || stype ==
"RiseTime"))
continue;
211 if (sig ==
"QL1" && stype ==
"FPGAEnergy")
continue;
220 while (!lsignals.
End()) {
254 if (!oldname.
End()) {
255 lab = oldname.
Next();
257 if (!oldname.
End()) {
258 tmp = oldname.
Next();
262 if (!oldname.
End()) {
263 tmp = oldname.
Next();
267 if (!oldname.
End()) {
268 tmp = oldname.
Next();
273 newname.
Form(
"%s-%d", lab.
Data(), bb * 100 + qq * 10 +
tt);
274 return newname.
Data();
353 Warning(
"Fired",
"%s : No signal attached to this detector ...",
GetName());
378 Warning(
"SetSignal",
"%s : No signal of name #%s# is available",
GetName(), signal_name);
460 while ((sig = (
KVSignal*)nexts())) {
478 if (idx == 0)
return SetQH1FPGAEnergy(energy);
485 if (idx == 0)
return SetQ2FPGAEnergy(energy);
490 if (idx == 0)
return SetQ3FPGAEnergy(energy);
491 if (idx == 1)
return SetQ3FastFPGAEnergy(energy);
510 return SetQH1BaseLine(baseline);
517 return SetQ2BaseLine(baseline);
522 return SetQ3BaseLine(baseline);
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t Atom_t Atom_t Time_t type
char * Form(const char *fmt,...)
void SetLabel(const Char_t *lab)
const Char_t * GetLabel() const
const Char_t * GetDataSetEnv(const Char_t *type, const Char_t *defval="") const
Base class for output signal data produced by a detector.
Base class for detector geometry description.
virtual Bool_t IsSimMode() const
void AddDetectorSignal(KVDetectorSignal *ds)
virtual Double_t GetEnergyLoss() const
KVMaterial * GetActiveLayer() const
virtual void Clear(Option_t *opt="")
Bool_t AddDetectorSignalExpression(const KVString &type, const KVString &_expr)
Double_t GetDetectorSignalValue(const KVString &type, const KVNameValueList ¶ms="") const
virtual Bool_t IsDetecting() const
virtual void Copy(TObject &obj) const
Base class for FAZIA detectors.
Bool_t fIsFiredFromSignals
KVSignal * GetSignal(const Char_t *name) const
Bool_t Fired(Option_t *opt="any") const
const KVSeqCollection * GetListOfSignals() const
virtual void Clear(Option_t *opt="")
If opt="N" we do not reset any raw data, signals, etc.
Double_t fQH1Threshold
thresholds defined for this detector
virtual ~KVFAZIADetector()
Destructor.
KVUniqueNameList fSignals
list of electronics signal (current, charge, etc... )
void SetSignal(TGraph *signal, const Char_t *signal_name)
KVFAZIADetector()
Default constructor.
Int_t GetIdentifier() const
virtual void SetName(const char *name)
Bool_t HasSignal() const
Returns kTRUE if detector has at least 1 associated signal.
void Copy(TObject &obj) const
KVDetectorSignal * SetBaseLine(int sigid, Float_t baseline)
KVSignal * GetSignalByType(const Char_t *type) const
Access detector signal of given type: "I1", "I2", "Q2", "Q3", "QH1", "QL1".
Double_t GetSetupParameter(const Char_t *parname)
Int_t GetNumberOfSignals() const
void ComputePSA()
Perform Pulse Shape Analysis on all signals.
Int_t fIdentifier
SI1=0(kSI1) SI2=1(kSI2) CSI=2(kCSI)
static const Char_t * GetNewName(KVString oldname)
void init()
default initialisations
KVDetectorSignal * SetFPGAEnergy(int sigid, Int_t idx, Double_t energy)
Int_t fIndex
100*block+10*quartet+telescope
void AddDetectorLabel(const Char_t *label)
KaliVeda extensions to ROOT collection classes.
virtual TObject * FindObject(const char *name) const
virtual void Clear(Option_t *option="")
virtual Int_t GetSize() const
virtual void Execute(const char *method, const char *params, Int_t *error=0)
virtual TObject * At(Int_t idx) const
virtual TObject * FindObjectByType(const Char_t *) const
virtual Bool_t IsCharge() const
virtual void TreateSignal()
void SetData(Int_t nn, Double_t *xx, Double_t *yy)
operation on data arrays
void SetDetectorName(const Char_t *name)
virtual void LoadPSAParameters()
static KVSignal * MakeSignal(const char *sig_type)
Create new KVSignal instance corresponding to sig_type.
virtual void GetPSAResult(KVDetector *) const
Bool_t IsFired()
ComputeBaseLine and ComputeEndLine methods have to be called before.
void SetType(const Char_t *type)
Bool_t PSAHasBeenComputed() const
virtual Double_t ComputeEndLine()
Extension of ROOT TString class which allows backwards compatibility with ROOT v3....
void Begin(TString delim) const
KVString Next(Bool_t strip_whitespace=kFALSE) const
virtual void Add(TObject *obj)
virtual Int_t GetEntries() const
virtual const char * GetValue(const char *name, const char *dflt) const
void SetName(const char *name="") override
const char * GetName() const override
virtual void SetName(const char *name)
virtual void Warning(const char *method, const char *msgfmt,...) const
virtual void Info(const char *method, const char *msgfmt,...) const
const char * Data() const
Bool_t BeginsWith(const char *s, ECaseCompare cmp=kExact) const
void Form(const char *fmt,...)
TString & ReplaceAll(const char *s1, const char *s2)