1 ////////////////////////////////////////////////////////////
2 // Author: Henrik Tydesjo //
3 // Interface class to the containers of an online mean //
5 ////////////////////////////////////////////////////////////
8 #include "AliITSOnlineSPDscanMeanTh.h"
9 #include "AliITSOnlineSPDscanInfoMeanTh.h"
11 AliITSOnlineSPDscanMeanTh::AliITSOnlineSPDscanMeanTh(const Char_t *fileName) {
14 // look for a previously saved info object
15 // (if file not found create a new one and return, else read)
16 FILE* fp0 = fopen(fFileName.Data(), "r");
18 fScanInfo = new AliITSOnlineSPDscanInfoMeanTh();
19 fFile = new TFile(fFileName.Data(), "RECREATE");
24 fFile = new TFile(fFileName.Data(), "READ");
26 fFile->GetObject("AliITSOnlineSPDscanInfo", fScanInfo);
31 AliITSOnlineSPDscanMeanTh::AliITSOnlineSPDscanMeanTh(const AliITSOnlineSPDscanMeanTh& scan) :
32 AliITSOnlineSPDscanMultiple(scan)
35 AliITSOnlineSPDscanMeanTh::~AliITSOnlineSPDscanMeanTh() {}
37 AliITSOnlineSPDscanMeanTh& AliITSOnlineSPDscanMeanTh::operator=(const AliITSOnlineSPDscanMeanTh& scan) {
38 // assignment operator (should not be used)
39 printf("This object should not be copied!");
41 // still do nothing...
46 UInt_t AliITSOnlineSPDscanMeanTh::AddScanStep() {
48 return ((AliITSOnlineSPDscanInfoMeanTh*)fScanInfo)->AddScanStep();
51 void AliITSOnlineSPDscanMeanTh::SetDacLow(UInt_t nsi, UInt_t hs, Int_t val) {
52 // set dac low value for step nsi and half stave hs
54 ((AliITSOnlineSPDscanInfoMeanTh*)fScanInfo)->SetDacLow(nsi,hs,val);
57 void AliITSOnlineSPDscanMeanTh::SetDacHigh(UInt_t nsi, UInt_t hs, Int_t val) {
58 // set dac high value for step nsi and half stave hs
60 ((AliITSOnlineSPDscanInfoMeanTh*)fScanInfo)->SetDacHigh(nsi,hs,val);
63 void AliITSOnlineSPDscanMeanTh::SetTPAmp(UInt_t nsi, UInt_t hs, Int_t val) {
64 // set test pulse amplitude for step nsi and half stave hs
66 ((AliITSOnlineSPDscanInfoMeanTh*)fScanInfo)->SetTPAmp(nsi,hs,val);
70 Int_t AliITSOnlineSPDscanMeanTh::GetDacLow(UInt_t nsi, UInt_t hs) {
71 return ((AliITSOnlineSPDscanInfoMeanTh*)fScanInfo)->GetDacLow(nsi,hs);
73 Int_t AliITSOnlineSPDscanMeanTh::GetDacHigh(UInt_t nsi, UInt_t hs) {
74 return ((AliITSOnlineSPDscanInfoMeanTh*)fScanInfo)->GetDacHigh(nsi,hs);
76 Int_t AliITSOnlineSPDscanMeanTh::GetTPAmp(UInt_t nsi, UInt_t hs) {
77 return ((AliITSOnlineSPDscanInfoMeanTh*)fScanInfo)->GetTPAmp(nsi,hs);