Line data Source code
1 : /////////////////////////////////////////////////////////////////
2 : // Author: Henrik Tydesjo //
3 : // This class is used as a container online. //
4 : // It holds additional information needed for a mean threshold //
5 : // scan. //
6 : // This class should only be used through the interface of the //
7 : // AliITSOnlineSPDscanMeanTh class. //
8 : /////////////////////////////////////////////////////////////////
9 :
10 : #include "AliITSOnlineSPDscanInfoMeanTh.h"
11 :
12 116 : ClassImp(AliITSOnlineSPDscanInfoMeanTh)
13 :
14 0 : AliITSOnlineSPDscanInfoMeanTh::AliITSOnlineSPDscanInfoMeanTh() :
15 0 : AliITSOnlineSPDscanInfoMultiple() {}
16 :
17 0 : AliITSOnlineSPDscanInfoMeanTh::~AliITSOnlineSPDscanInfoMeanTh() {}
18 :
19 : UInt_t AliITSOnlineSPDscanInfoMeanTh::AddScanStep() {
20 : // add a new scan step, allocate space in the TArrays
21 0 : UInt_t returnval = AliITSOnlineSPDscanInfoMultiple::AddScanStep();
22 0 : for (UInt_t hs=0; hs<6; hs++) {
23 0 : fDacLow[hs].Set(fNSteps);
24 0 : fDacLow[hs].AddAt(-1, fNSteps-1);
25 0 : fDacHigh[hs].Set(fNSteps);
26 0 : fDacHigh[hs].AddAt(-1, fNSteps-1);
27 0 : fTPAmps[hs].Set(fNSteps);
28 0 : fTPAmps[hs].AddAt(-1, fNSteps-1);
29 : }
30 0 : return returnval;
31 : }
32 :
33 : void AliITSOnlineSPDscanInfoMeanTh::SetDacLow(UInt_t nsi, UInt_t hs, Int_t val) {
34 0 : if (nsi<fNSteps) fDacLow[hs].AddAt(val,nsi);
35 0 : }
36 : void AliITSOnlineSPDscanInfoMeanTh::SetDacHigh(UInt_t nsi, UInt_t hs, Int_t val) {
37 0 : if (nsi<fNSteps) fDacHigh[hs].AddAt(val,nsi);
38 0 : }
39 : void AliITSOnlineSPDscanInfoMeanTh::SetTPAmp(UInt_t nsi, UInt_t hs, Int_t val) {
40 0 : if (nsi<fNSteps) fTPAmps[hs].AddAt(val,nsi);
41 0 : }
42 : Int_t AliITSOnlineSPDscanInfoMeanTh::GetDacLow(UInt_t nsi, UInt_t hs) const {
43 0 : if (nsi<fNSteps) return fDacLow[hs].At(nsi);
44 0 : else return -1;
45 0 : }
46 : Int_t AliITSOnlineSPDscanInfoMeanTh::GetDacHigh(UInt_t nsi, UInt_t hs) const {
47 0 : if (nsi<fNSteps) return fDacHigh[hs].At(nsi);
48 0 : else return -1;
49 0 : }
50 : Int_t AliITSOnlineSPDscanInfoMeanTh::GetTPAmp(UInt_t nsi, UInt_t hs) const {
51 0 : if (nsi<fNSteps) return fTPAmps[hs].At(nsi);
52 0 : else return -1;
53 0 : }
|