2 - "Contact:" - henrik.tydesjo@cern.ch
4 - "Run Type:" - DAQ_MIN_TH_SCAN,DAQ_MEAN_TH_SCAN,DAQ_UNIFORMITY_SCAN,DAQ_NOISY_PIX_SCAN,DAQ_PIX_DELAY_SCAN,DAQ_FO_UNIF_SCAN
6 - "Number of events needed:"
7 - "Input Files:" - daq db config files: spd_standal_params,spd_perm_noisy , previous noisy lists: ./calibResults/ScanNoisy/* , raw data
8 - "Output Files:" - Ref Data: ./calibResults/ScanReference/* , DCS update: ./calibResults/ScanDCSconfigToFXS/* , OCDB update: ./calibResults/ScanNoisyToFXS/* , persistent files: ./calibResults/ScanNoisy/*
9 - "Trigger types used:"
12 ////////////////////////////////////////////////////////////////////////////////
13 // This program can be compiled in two modes. //
15 // 1. With the DAQ DA framework on. This is the default operating mode. //
16 // Call this program with the name of the executable followed by the //
17 // data files to process. //
19 // 2. Without the DAQ DA framework on. Define the SPD_DA_OFF environment var. //
20 // Call this program with the name of the executable followed by the //
21 // runNr and the data files to process. //
23 ////////////////////////////////////////////////////////////////////////////////
30 #include "AliRawReaderDate.h"
31 #include "AliITSRawStreamSPD.h"
32 #include "AliITSOnlineSPDscan.h"
33 #include "AliITSOnlineSPDscanSingle.h"
34 #include "AliITSOnlineSPDscanMultiple.h"
35 #include "AliITSOnlineSPDscanMeanTh.h"
36 #include "AliITSOnlineSPDscanAnalyzer.h"
37 #include "AliITSOnlineCalibrationSPDhandler.h"
42 #include <TPluginManager.h>
43 #include <TObjArray.h>
46 int main(int argc, char **argv) {
48 printf("Wrong number of arguments\n");
52 // directory structure, hard coded
53 char *saveDirNoisy = "./calibResults/ScanNoisy"; // may NOT delete content
54 char *saveDirNoisyToFXS = "./calibResults/ScanNoisyToFXS"; // may delete content
55 char *saveDirDCSconfigToFXS= "./calibResults/ScanDCSconfigToFXS"; // may delete content
56 char *saveDirRef = "./calibResults/ScanReference"; // may delete content
57 char *configFilesDir = "./configFiles"; // may delete content
58 // make sure the directory structure is correct:
59 system("mkdir ./calibResults >& /dev/null");
60 system("mkdir ./calibResults/ScanNoisy >& /dev/null");
61 system("mkdir ./calibResults/ScanNoisyToFXS >& /dev/null");
62 system("mkdir ./calibResults/ScanDCSconfigToFXS >& /dev/null");
63 system("mkdir ./calibResults/ScanReference >& /dev/null");
64 system("mkdir ./configFiles >& /dev/null");
65 // prameters config files
66 TString paramsFileName = Form("%s/standal_params.txt",configFilesDir);
67 TString permNoisyFileName = Form("%s/perm_noisy.txt",configFilesDir);
69 // This line is needed in case of a stand-alone application w/o
70 // $ROOTSYS/etc/system.rootrc file
71 gROOT->GetPluginManager()->AddHandler("TVirtualStreamerInfo",
77 // turn off annoying warning messages
79 AliLog::Instance()->SetGlobalDebugLevel(-20);
82 enum calib_types{MINTH,MEANTH,DAC,UNIMA,NOISE,DELAY};
85 // ********* STEP 0: Get configuration files from db (if there are any) , then read parameters*********
86 UInt_t nrTuningParams = 0;
87 TObjArray paramNames; paramNames.SetOwner(kTRUE);
88 TObjArray paramVals; paramVals.SetOwner(kTRUE);
93 TString idp = "spd_standal_params";
94 status=daqDA_DB_getFile(idp.Data(),paramsFileName.Data());
96 printf("Failed to get config file %s: status=%d. Using default tuning parameters.\n",idp.Data(),status);
101 paramsFile.open(paramsFileName.Data(), ifstream::in);
102 if (paramsFile.fail()) {
103 printf("No config file (%s) present. Using default tuning parameters.\n",paramsFileName.Data());
109 paramsFile >> paramN;
110 if (paramsFile.eof()) break;
111 paramsFile >> paramV;
112 TString* paramNS = new TString(paramN);
113 TString* paramVS = new TString(paramV);
114 paramNames.AddAtAndExpand((TObject*)paramNS,nrTuningParams);
115 paramVals.AddAtAndExpand((TObject*)paramVS,nrTuningParams);
117 if (paramsFile.eof()) break;
122 // for (UInt_t i=0; i<nrTuningParams; i++) {
123 // printf("Entry %d: N=%s , V=%s\n",i,((TString*)paramNames.At(i))->Data(),((TString*)paramVals.At(i))->Data());
127 Int_t permstatus = 0;
129 TString idn = "spd_perm_noisy";
130 permstatus=daqDA_DB_getFile(idn.Data(),permNoisyFileName.Data());
132 printf("Failed to get config file %s: status=%d. No permanently noisy pixels will be added.\n",idn.Data(),permstatus);
139 // ********* STEP 1: Produce scan container files (Reference Data). ***********************************
143 int runNr = atoi(getenv("DATE_RUN_NUMBER"));
145 int runNr = atoi(argv[1]);
150 AliITSOnlineSPDscan *scanObj[20];
151 Bool_t bScanInit[20];
152 for (UInt_t eqId=0; eqId<20; eqId++) {
154 bScanInit[eqId]=kFALSE;
156 // header data variables
158 Bool_t halfStaveScanned[20][6];
160 Bool_t dataFormat[20];
162 Bool_t chipPresent[20][6][10];
171 UInt_t dacHigh[20][6];
172 UInt_t dacLow[20][6];
174 Bool_t minTHchipPresent[20][10];
175 // current scan step flag
176 Int_t currentStep[20];
177 for (UInt_t eqId=0; eqId<20; eqId++) currentStep[eqId] = 9999;
179 // loop over run segments
180 for (int segNr=startSeg; segNr<argc; segNr++) {
184 /* define data source : this is argument 1 */
185 status=monitorSetDataSource( argv[segNr] );
187 printf("monitorSetDataSource() failed : %s\n",monitorDecodeError(status));
190 /* declare monitoring program */
191 status=monitorDeclareMp("ITS_SPD_CAL");
193 printf("monitorDeclareMp() failed : %s\n",monitorDecodeError(status));
196 /* define wait event timeout - 1s max */
198 monitorSetNoWaitNetworkTimeout(1000);
203 /* main loop (infinite) */
206 struct eventHeaderStruct *event;
207 eventTypeType eventT;
209 /* check shutdown condition */
211 if (daqDA_checkShutdown()) {break;}
213 /* get next event (blocking call until timeout) */
214 status=monitorGetEventDynamic((void **)&event);
215 if (status==MON_ERR_EOF) {
216 printf ("End of File detected\n");
217 break; /* end of monitoring file has been reached */
220 printf("monitorGetEventDynamic() failed : %s\n",monitorDecodeError(status));
223 /* retry if got no event */
228 eventT=event->eventType;
229 if (eventT == PHYSICS_EVENT) {
232 // printf("eventNr %d\n",eventNr);
234 AliRawReader *reader = new AliRawReaderDate((void*)event);
235 AliITSRawStreamSPD *str = new AliITSRawStreamSPD(reader);
237 for (UInt_t eqId=0; eqId<20; eqId++) {
240 reader->Select("ITSSPD",eqId,eqId);
242 // Hit Event flags, specific for one event
243 Bool_t hitEventHSIncremented[6];
244 Bool_t hitEventChipIncremented[6][10];
245 for (UInt_t hs=0; hs<6; hs++) {
246 hitEventHSIncremented[hs] = kFALSE;
247 for (UInt_t chip=0; chip<10; chip++) {
248 hitEventChipIncremented[hs][chip] = kFALSE;
252 if (str->ReadCalibHeader()) {
253 // first check the type:
254 if (bScanInit[eqId] && type[eqId]!=str->GetHtype()) {
255 printf("Calib header problem. Type changed (%d -> %d)!\n",type[eqId],str->GetHtype());
259 routerNr[eqId] = str->GetHrouterNr();
260 type[eqId] = str->GetHtype();
261 dataFormat[eqId] = str->GetHdataFormat();
262 triggers[eqId] = str->GetHtriggers();
263 dacStart[eqId] = str->GetHdacStart();
264 dacEnd[eqId] = str->GetHdacEnd();
265 dacStep[eqId] = str->GetHdacStep();
266 dacId[eqId] = str->GetHdacId();
267 rowStart[eqId] = str->GetHrowStart();
268 rowEnd[eqId] = str->GetHrowEnd();
269 rowValue[eqId] = str->GetHrowValue();
270 dacValue[eqId] = str->GetHdacValue();
271 for (UInt_t hs=0; hs<6; hs++) {
272 halfStaveScanned[eqId][hs] = str->GetHhalfStaveScanned(hs);
273 dacHigh[eqId][hs] = str->GetHdacHigh(hs);
274 dacLow[eqId][hs] = str->GetHdacLow(hs);
275 TPAmp[eqId][hs] = str->GetHTPAmp(hs);
276 for (UInt_t chip=0; chip<10; chip++) {
277 chipPresent[eqId][hs][chip] = str->GetHchipPresent(hs,chip);
280 for (UInt_t chip=0; chip<10; chip++) {
281 minTHchipPresent[eqId][chip] = str->GetHminTHchipPresent(chip);
284 currentStep[eqId] = (dacValue[eqId]-dacStart[eqId])/dacStep[eqId];
285 if (type[eqId]==DELAY) {
286 currentStep[eqId]=currentStep[eqId]*2;
287 dacValue[eqId]=dacValue[eqId]*2;
288 if (dacHigh[eqId][0]==128) { // misc_ctrl value
289 currentStep[eqId]=currentStep[eqId]+1;
290 dacValue[eqId]=dacValue[eqId]+1;
295 if (routerNr[eqId]!=eqId) {
296 printf("Router nr problem? Router nr %d != EqID %d\n",routerNr[eqId],eqId);
299 if (!bScanInit[eqId]) {
300 // initialize container object
301 TString fileName = Form("%s/SPDcal_run_%d_eq_%d.root",saveDirRef,runNr,eqId);
302 switch (type[eqId]) {
305 scanObj[eqId] = new AliITSOnlineSPDscanSingle(fileName.Data());
306 ((AliITSOnlineSPDscanSingle*)scanObj[eqId])->ClearThis();
307 bScanInit[eqId]=kTRUE;
312 scanObj[eqId] = new AliITSOnlineSPDscanMultiple(fileName.Data());
313 scanObj[eqId]->ClearThis();
314 bScanInit[eqId]=kTRUE;
317 scanObj[eqId] = new AliITSOnlineSPDscanMeanTh(fileName.Data());
318 scanObj[eqId]->ClearThis();
319 bScanInit[eqId]=kTRUE;
322 printf("Unknown scan type: %d.\n",type[eqId]);
324 // some multiple scan data
325 if (type[eqId]==MINTH || type[eqId]==MEANTH || type[eqId]==DAC || type[eqId]==DELAY) {
326 ((AliITSOnlineSPDscanMultiple*)scanObj[eqId])->SetDacId(dacId[eqId]);
329 scanObj[eqId]->SetRunNr((UInt_t)runNr);
330 scanObj[eqId]->SetRouterNr(routerNr[eqId]);
331 for (UInt_t hs=0; hs<6; hs++) {
332 scanObj[eqId]->SetHalfStaveScanned(hs,halfStaveScanned[eqId][hs]);
334 scanObj[eqId]->SetType(type[eqId]);
335 scanObj[eqId]->SetDataFormat(dataFormat[eqId]);
336 for (Int_t hs=0; hs<6; hs++) {
338 // remove later when the chip present is set correctly !!!!!!!!!!!!!!!!!!!!!!!!!!!
339 Bool_t halfStavePresent = str->GetHalfStavePresent(hs);
340 // remove later when the chip present is set correctly !!!!!!!!!!!!!!!!!!!!!!!!!!!
342 for (UInt_t chip=0; chip<10; chip++) {
343 scanObj[eqId]->SetChipPresent(hs,chip,chipPresent[eqId][hs][chip]);
345 // remove later when the chip present is set correctly !!!!!!!!!!!!!!!!!!!!!!!!!!!
346 if (halfStavePresent) scanObj[eqId]->SetChipPresent(hs,chip,kTRUE);
347 // remove later when the chip present is set correctly !!!!!!!!!!!!!!!!!!!!!!!!!!!
351 scanObj[eqId]->SetRowStart(rowStart[eqId]);
352 scanObj[eqId]->SetRowEnd(rowEnd[eqId]);
353 scanObj[eqId]->SetDacStart(dacStart[eqId]);
354 scanObj[eqId]->SetDacEnd(dacEnd[eqId]);
355 scanObj[eqId]->SetDacStep(dacStep[eqId]);
358 if (type[eqId]==MINTH) {
359 scanObj[eqId]->SetTriggers(currentStep[eqId],triggers[eqId]);
361 if (type[eqId]==UNIMA || type[eqId]==NOISE) {
362 if (currentStep[eqId]==9999) printf("SPDcalibratorStep1 (eq %d): single step\n",eqId);
365 if (type[eqId]==MINTH || type[eqId]==MEANTH || type[eqId]==DAC || type[eqId]==DELAY) {
366 ((AliITSOnlineSPDscanMultiple*)scanObj[eqId])->SetDacValue(currentStep[eqId],dacValue[eqId]);
367 if (type[eqId]==DELAY) {
368 printf("SPDcalibratorStep1 (eq %d): DAC %d/%d , step %d\n",eqId,dacValue[eqId]/2,dacHigh[eqId][0],currentStep[eqId]);
371 printf("SPDcalibratorStep1 (eq %d): DAC %d , step %d\n",eqId,dacValue[eqId],currentStep[eqId]);
374 if (type[eqId]==MEANTH) {
375 for (Int_t hs=0; hs<6; hs++) {
376 ((AliITSOnlineSPDscanMeanTh*)scanObj[eqId])->SetDacLow(currentStep[eqId],hs,dacLow[eqId][hs]);
377 ((AliITSOnlineSPDscanMeanTh*)scanObj[eqId])->SetDacHigh(currentStep[eqId],hs,dacHigh[eqId][hs]);
378 ((AliITSOnlineSPDscanMeanTh*)scanObj[eqId])->SetTPAmp(currentStep[eqId],hs,TPAmp[eqId][hs]);
385 if (bScanInit[eqId]) {
386 while (str->Next()) {
387 UInt_t hs = str->GetHalfStaveNr();
388 UInt_t chip = str->GetChipAddr();
389 //***remove last condition when minthpresent put correctly in calib header?
391 if (type[eqId]!=MINTH || minTHchipPresent[eqId][chip] || runNr<=416900) {
393 if (type[eqId]!=MINTH || minTHchipPresent[eqId][chip] || runNr<=416900) {
395 //*************************************************************************
396 scanObj[eqId]->IncrementHits(currentStep[eqId],hs,chip,str->GetChipCol(),str->GetChipRow());
398 if (!hitEventHSIncremented[hs]) {
399 scanObj[eqId]->IncrementHitEventsTot(currentStep[eqId],hs);
400 hitEventHSIncremented[hs]=kTRUE;
403 if (!hitEventChipIncremented[hs][chip]) {
404 scanObj[eqId]->IncrementHitEvents(currentStep[eqId],hs,chip);
405 hitEventChipIncremented[hs][chip]=kTRUE;
411 if (type[eqId]!=MINTH) { // for minth, triggers are set from header info
412 scanObj[eqId]->IncrementTriggers(currentStep[eqId]);
430 daqDA_progressReport((unsigned int)( ((Float_t)(segNr-startSeg+1))/(argc-startSeg)*50 ));
432 printf("progress: %d\n",(unsigned int)( ((Float_t)(segNr-startSeg+1))/(argc-startSeg)*50 ));
438 // clean up scan objects (which also saves them)
439 for (UInt_t eqId=0; eqId<20; eqId++) {
440 if (scanObj[eqId]!=NULL) delete scanObj[eqId];
447 // ********* STEP 2: Analyze scan container files. ************************************************
449 // clear noisyToFXS and DCSconfigToFXS dirs:
450 TString command = Form("cd %s; rm -f *",saveDirNoisyToFXS);
451 system(command.Data());
452 TString command2 = Form("cd %s; rm -f *",saveDirDCSconfigToFXS);
453 system(command2.Data());
454 UInt_t nrNoisyFilesProduced=0;
455 UInt_t nrDCSconfigFilesProduced=0;
457 AliITSOnlineCalibrationSPDhandler* handler = new AliITSOnlineCalibrationSPDhandler();
458 AliITSOnlineSPDscanAnalyzer *analyzer = NULL;
459 AliITSOnlineCalibrationSPDhandler* handlerPermNoisy = NULL;
460 // fill permanent noisy list to add later...
462 handlerPermNoisy = new AliITSOnlineCalibrationSPDhandler();
463 UInt_t permNoisy = handlerPermNoisy->ReadNoisyFromText(permNoisyFileName.Data(),240); // 240 = read for all modules
465 printf("%d noisy pixels read from permanent list.\n",permNoisy);
470 // *** *** *** start loop over equipments (eq_id)
471 for (int eqId=0; eqId<20; eqId++) {
473 // create analyzer for this eq
474 TString fileName = Form("%s/SPDcal_run_%d_eq_%d.root",saveDirRef,runNr,eqId);
475 analyzer = new AliITSOnlineSPDscanAnalyzer(fileName.Data(),handler);
477 // configure analyzer with tuning parameters etc:
478 for (UInt_t i=0; i<nrTuningParams; i++) {
479 analyzer->SetParam(((TString*)paramNames.At(i))->Data(),((TString*)paramVals.At(i))->Data());
482 UInt_t type = analyzer->GetType();
483 UInt_t dacId = analyzer->GetDacId();
484 UInt_t routerNr = analyzer->GetRouterNr();
487 printf("SPD scan calibrator Step2: eqId %d, type %d, dacId %d\n",eqId,type,dacId);
489 else printf("SPD scan calibrator Step2: eqId %d type %d\n",eqId,type);
494 // algorithms for the different types of scans:
500 else if (type==NOISE) {
501 // read previous noisy list
502 handler->SetFileLocation(saveDirNoisy);
503 handler->ReadFromFiles();
504 if (analyzer->ProcessNoisyPixels(/*saveDirNoisy*/)) {
506 handler->AddNoisyFrom(handlerPermNoisy);
508 // init dcs config text file
509 TString dcsConfigFileName = Form("%s/dcsConfig_run_%d_eq_%d.txt",saveDirDCSconfigToFXS,runNr,eqId);
511 dcsfile.open(dcsConfigFileName.Data());
512 dcsfile << "[SPD SCAN]\n";
513 dcsfile << "RunNumber=" << runNr << "\n";
514 dcsfile << "Type=" << type << "\n";
515 dcsfile << "Router=" << routerNr << "\n";
516 dcsfile << "ActualDetConfiguration=" << "0,-1,-1\n"; // dummy values for now
517 dcsfile << "[NOISY]\n";
518 nrDCSconfigFilesProduced++;
519 for (UInt_t iModule=0; iModule<12; iModule++) {
520 UInt_t module = AliITSRawStreamSPD::GetModuleNumber(eqId,iModule);
521 UInt_t nrNoisy = handler->GetNrNoisy(module);
522 if (analyzer->IsModuleScanned(module) || analyzer->IsOverWriteSet()) {
523 UInt_t headkey=20*10*6;
524 for (UInt_t ind=0; ind<nrNoisy; ind++) {
525 UInt_t nEqId = handler->GetNoisyEqIdAt(module,ind);
526 UInt_t nHs = handler->GetNoisyHSAt(module,ind);
527 UInt_t nChip = handler->GetNoisyChipAt(module,ind);
528 UInt_t newkey = nEqId*10*6 + nHs*10 + nChip;
529 if (newkey!=headkey) { // print eqId,hs,chip_header
531 dcsfile << "-" << nEqId << "," << nHs << "," << nChip << "\n";
533 dcsfile << handler->GetNoisyColAt(module,ind) << "," << handler->GetNoisyRowAt(module,ind) << "\n";
535 handler->SetFileLocation(saveDirNoisy);
536 handler->WriteNoisyToFile(module);
537 handler->SetFileLocation(saveDirNoisyToFXS);
538 handler->WriteNoisyToFile(module);
539 nrNoisyFilesProduced++;
546 else if (type==MINTH || (type==DAC && dacId==39)) {
547 // init dcs config text file
548 TString dcsConfigFileName = Form("%s/dcsConfig_run_%d_eq_%d.txt",saveDirDCSconfigToFXS,runNr,eqId);
550 dcsfile.open(dcsConfigFileName.Data());
551 dcsfile << "[SPD SCAN]\n";
552 dcsfile << "RunNumber=" << runNr << "\n";
553 dcsfile << "Type=" << type << "\n";
554 dcsfile << "Router=" << routerNr << "\n";
555 dcsfile << "ActualDetCoonfiguration=" << "0,-1,-1\n"; // dummy values for now
556 dcsfile << "[DACvalues]\n";
557 nrDCSconfigFilesProduced++;
558 // TString ofileName = Form("%s/minth_eq_%d.txt",saveDirParameters,eqId);
560 // ofile.open (ofileName.Data());
561 for (UInt_t hs=0; hs<6; hs++) {
562 for (UInt_t chipNr=0; chipNr<10; chipNr++) {
564 if (analyzer->GetOnlineScan()->GetChipPresent(hs,chipNr)) {
565 minTh = analyzer->GetMinTh(hs,chipNr);
567 dcsfile << "39," << eqId << "," << hs << "," << chipNr << "=" << minTh << "\n";
570 printf("MinTh failed for Eq %d , HS %d , Chip %d\n",eqId,hs,chipNr);
582 else if (type==DELAY) {
583 // init dcs config text file
584 TString dcsConfigFileName = Form("%s/dcsConfig_run_%d_eq_%d.txt",saveDirDCSconfigToFXS,runNr,eqId);
586 dcsfile.open(dcsConfigFileName.Data());
587 dcsfile << "[SPD SCAN]\n";
588 dcsfile << "RunNumber=" << runNr << "\n";
589 dcsfile << "Type=" << type << "\n";
590 dcsfile << "Router=" << routerNr << "\n";
591 dcsfile << "ActualDetCoonfiguration=" << "0,-1,-1\n"; // dummy values for now
592 dcsfile << "[DACvalues]\n";
593 nrDCSconfigFilesProduced++;
594 // TString ofileName = Form("%s/delay_eq_%d.txt",saveDirParameters,eqId);
596 // ofile.open (ofileName.Data());
597 for (UInt_t hs=0; hs<6; hs++) {
598 for (UInt_t chipNr=0; chipNr<10; chipNr++) {
599 Int_t clockCycle = -1;
600 Int_t delayCtrl = -1;
602 if (analyzer->GetOnlineScan()->GetChipPresent(hs,chipNr)) {
603 clockCycle = analyzer->GetDelay(hs,chipNr);
604 delayCtrl = clockCycle/2;
606 if (clockCycle!=-1) {
607 if (clockCycle%2==1) miscCtrl = 128;
608 dcsfile << "42," << eqId << "," << hs << "," << chipNr << "=" << delayCtrl << "\n";
609 dcsfile << "43," << eqId << "," << hs << "," << chipNr << "=" << miscCtrl << "\n";
612 printf("Delay failed for Eq %d , HS %d , Chip %d\n",eqId,hs,chipNr);
615 // ofile << delayCtrl << "/" << miscCtrl;
627 daqDA_progressReport((unsigned int)(50+(eqId+1)*2.5));
629 printf("progress: %d\n",(unsigned int)(50+(eqId+1)*2.5));
633 // *** *** *** end loop over equipments (eq_id)
636 if (handlerPermNoisy!=NULL) {
637 delete handlerPermNoisy;
643 // send noisy data to FXS
644 if (nrNoisyFilesProduced>0) {
645 // send a tared file of all new noisy maps
646 TString command = Form("cd %s; tar -cf noisy_scan.tar *",saveDirNoisyToFXS);
647 // printf("\n\n%s\n\n",command.Data());
648 system(command.Data());
650 TString fileName = Form("%s/noisy_scan.tar",saveDirNoisyToFXS);
651 TString id = "SPD_scan_noisy";
652 Int_t status = daqDA_FES_storeFile(fileName.Data(),id.Data());
654 printf("Failed to export file %s , status %d\n",fileName.Data(),status);
660 // send dcs config files to FXS
661 if (nrDCSconfigFilesProduced>0) {
662 // send a tared file of all the dcsConfig text files
663 TString command = Form("cd %s; tar -cf dcsConfig.tar *",saveDirDCSconfigToFXS);
664 // printf("\n\n%s\n\n",command.Data());
665 system(command.Data());
667 TString fileName = Form("%s/dcsConfig.tar",saveDirDCSconfigToFXS);
668 TString id = "SPD_dcsConfig";
669 Int_t status = daqDA_FES_storeFile(fileName.Data(),id.Data());
671 printf("Failed to export file %s , status %d\n",fileName.Data(),status);
677 // send reference data to FXS
679 for (UInt_t eqId=0; eqId<20; eqId++) {
680 if (bScanInit[eqId]) {
681 TString fileName = Form("%s/SPDcal_run_%d_eq_%d.root",saveDirRef,runNr,eqId);
682 TString id = Form("SPD_ref_scan_%d",eqId);
683 Int_t status = daqDA_FES_storeFile(fileName.Data(),id.Data());
685 printf("Failed to export file %s , status %d\n",fileName.Data(),status);