CbmRoot
CbmTrdParAsic.h
Go to the documentation of this file.
1 #ifndef CBMTRDPARASIC_H
2 #define CBMTRDPARASIC_H
3 
4 #include <Rtypes.h> // for THashConsistencyHolder, ClassDef
5 #include <RtypesCore.h> // for Int_t, Double_t, Option_t
6 
7 #include "CbmTrdParMod.h" // for CbmTrdParMod
8 
9 #include <stdint.h> // for uint64_t
10 #include <vector> // for vector
11 
12 class FairParamList;
13 
15 class CbmTrdParAsic : public CbmTrdParMod {
16 public:
17  CbmTrdParAsic(Int_t address = 0,
18  Int_t FebGrouping = -1,
19  Double_t x = 0,
20  Double_t y = 0,
21  Double_t z = 0,
22  std::uint64_t compId = 0);
23  virtual ~CbmTrdParAsic() { ; }
24 
27  enum ECbmTrdComponentIdDecoding : ULong_t {
31  kCriIdPosition = 100000
32  };
33 
35  virtual Double_t GetSizeX() const = 0;
36  virtual Double_t GetSizeY() const = 0;
37  virtual Double_t GetX() const { return fX; }
38  virtual Double_t GetY() const { return fY; }
39  virtual Double_t GetZ() const { return fZ; }
40 
41  virtual Int_t GetAddress() const { return fAddress; }
42  virtual std::uint64_t GetComponentId() const { return fComponentId; }
43  virtual Int_t GetNchannels() const = 0;
44  virtual Int_t GetFebGrouping() const { return fFebGrouping; }
45  virtual Int_t GetChannelAddress(Int_t ich) const {
46  return ((ich < 0 || ich >= GetNchannels()) ? 0 : fChannelAddresses[ich]);
47  }
48  virtual std::vector<Int_t> GetChannelAddresses() const {
49  return fChannelAddresses;
50  }
51  virtual void LoadParams(FairParamList*) { ; }
52  virtual void Print(Option_t* opt = "") const;
57  virtual Int_t QueryChannel(Int_t ch) const;
58  virtual void SetChannelAddress(Int_t address);
59  virtual void SetChannelAddresses(std::vector<Int_t> addresses);
60  virtual void SetFebGrouping(Int_t feb) { fFebGrouping = feb; }
61  virtual void SetPosition(Double_t x = 0, Double_t y = 0, Double_t z = 0) {
62  fX = x;
63  fY = y;
64  fZ = z;
65  }
66  virtual void SetComponentId(std::uint64_t id) { fComponentId = id; }
67 
68 protected:
69  Int_t fAddress;
70  Double_t fX;
71  Double_t fY;
72  Double_t fZ;
73  Int_t fFebGrouping;
74  std::uint64_t
76  std::vector<Int_t>
78 
79  ClassDef(CbmTrdParAsic, 1) // Definition of common ASIC parameters
80 };
81 
82 #endif
CbmTrdParAsic::SetChannelAddresses
virtual void SetChannelAddresses(std::vector< Int_t > addresses)
Definition: CbmTrdParAsic.cxx:51
CbmTrdParAsic::GetAddress
virtual Int_t GetAddress() const
Definition: CbmTrdParAsic.h:41
CbmTrdParAsic::fComponentId
std::uint64_t fComponentId
For the digit decoding see ECbmTrdComponentIdDecoding. nTh cRob on the module counted from top to bot...
Definition: CbmTrdParAsic.h:75
CbmTrdParAsic
Definition of ASIC parameters.
Definition: CbmTrdParAsic.h:15
CbmTrdParAsic::fZ
Double_t fZ
center of asic in global c.s. [cm]
Definition: CbmTrdParAsic.h:72
CbmTrdParAsic::LoadParams
virtual void LoadParams(FairParamList *)
Definition: CbmTrdParAsic.h:51
CbmTrdParAsic::SetComponentId
virtual void SetComponentId(std::uint64_t id)
Definition: CbmTrdParAsic.h:66
CbmTrdParAsic::GetComponentId
virtual std::uint64_t GetComponentId() const
Definition: CbmTrdParAsic.h:42
CbmTrdParAsic::CbmTrdParAsic
CbmTrdParAsic(Int_t address=0, Int_t FebGrouping=-1, Double_t x=0, Double_t y=0, Double_t z=0, std::uint64_t compId=0)
Definition: CbmTrdParAsic.cxx:8
CbmTrdParAsic::GetChannelAddresses
virtual std::vector< Int_t > GetChannelAddresses() const
Definition: CbmTrdParAsic.h:48
CbmTrdParAsic::SetPosition
virtual void SetPosition(Double_t x=0, Double_t y=0, Double_t z=0)
Definition: CbmTrdParAsic.h:61
CbmTrdParAsic::Print
virtual void Print(Option_t *opt="") const
Definition: CbmTrdParAsic.cxx:24
CbmTrdParAsic::GetSizeY
virtual Double_t GetSizeY() const =0
CbmTrdParAsic::GetX
virtual Double_t GetX() const
Definition: CbmTrdParAsic.h:37
CbmTrdParAsic::fChannelAddresses
std::vector< Int_t > fChannelAddresses
addresses of individual output channels
Definition: CbmTrdParAsic.h:77
CbmTrdParMod
Definition of generic parameters for one TRD module.
Definition: CbmTrdParMod.h:9
CbmTrdParAsic::GetSizeX
virtual Double_t GetSizeX() const =0
CbmTrdParAsic::kCrobIdPosition
@ kCrobIdPosition
Definition: CbmTrdParAsic.h:30
CbmTrdParAsic::QueryChannel
virtual Int_t QueryChannel(Int_t ch) const
Query ASIC for specific pad address.
Definition: CbmTrdParAsic.cxx:30
CbmTrdParAsic::SetFebGrouping
virtual void SetFebGrouping(Int_t feb)
Definition: CbmTrdParAsic.h:60
CbmTrdParAsic::~CbmTrdParAsic
virtual ~CbmTrdParAsic()
Definition: CbmTrdParAsic.h:23
CbmTrdParAsic::kCrobNrPosition
@ kCrobNrPosition
Definition: CbmTrdParAsic.h:29
CbmTrdParAsic::ECbmTrdComponentIdDecoding
ECbmTrdComponentIdDecoding
Enum for decodation of spadic componentId (Hardware to software mapping) Since the length of the CriI...
Definition: CbmTrdParAsic.h:27
CbmTrdParAsic::GetNchannels
virtual Int_t GetNchannels() const =0
CbmTrdParAsic::fX
Double_t fX
center of asic in global c.s. [cm]
Definition: CbmTrdParAsic.h:70
CbmTrdParAsic::GetZ
virtual Double_t GetZ() const
Definition: CbmTrdParAsic.h:39
CbmTrdParAsic::fAddress
Int_t fAddress
unique ASIC ID
Definition: CbmTrdParAsic.h:69
CbmTrdParAsic::GetChannelAddress
virtual Int_t GetChannelAddress(Int_t ich) const
Definition: CbmTrdParAsic.h:45
x
Double_t x
Definition: CbmMvdSensorDigiToHitTask.cxx:68
y
Double_t y
Definition: CbmMvdSensorDigiToHitTask.cxx:68
CbmTrdParAsic::fY
Double_t fY
center of asic in global c.s. [cm]
Definition: CbmTrdParAsic.h:71
CbmTrdParAsic::SetChannelAddress
virtual void SetChannelAddress(Int_t address)
Definition: CbmTrdParAsic.cxx:41
CbmTrdParAsic::GetY
virtual Double_t GetY() const
Definition: CbmTrdParAsic.h:38
CbmTrdParMod.h
CbmTrdParAsic::fFebGrouping
Int_t fFebGrouping
no of ASIC in ROB
Definition: CbmTrdParAsic.h:73
CbmTrdParAsic::kElinkIdPosition
@ kElinkIdPosition
Definition: CbmTrdParAsic.h:28
CbmTrdParAsic::kCriIdPosition
@ kCriIdPosition
Definition: CbmTrdParAsic.h:31
CbmTrdParAsic::GetFebGrouping
virtual Int_t GetFebGrouping() const
Definition: CbmTrdParAsic.h:44