Changeset 14931


Ignore:
Timestamp:
02/15/13 21:02:04 (12 years ago)
Author:
tbretz
Message:
Write file numbers instead of run-numbers as it is in the real files -- still the NIGHT keyword is wrong.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Mars/mdrs/MHDrsCalibration.cc

    r14922 r14931  
    286286        // Scale ADC data from 12bit to 2000mV
    287287        fData.GetSampleStats(fBuffer.data()+4, 2000./4096);
    288         reinterpret_cast<uint32_t*>(fBuffer.data())[1] = fRun->GetRunNumber();
     288        reinterpret_cast<uint32_t*>(fBuffer.data())[1] = fRun->GetFileNumber();
    289289    }
    290290
     
    308308        // Scale ADC data from 12bit to 2000mV
    309309        fData.GetSampleStats(fBuffer.data()+1024*1440*2+4, 2000./4096/fResult->fNumOffset);//0.5);
    310         reinterpret_cast<uint32_t*>(fBuffer.data())[2] = fRun->GetRunNumber();
     310        reinterpret_cast<uint32_t*>(fBuffer.data())[2] = fRun->GetFileNumber();
    311311    }
    312312
     
    315315    {
    316316        fResult->fNumTrgOff = fData.GetNumEntries();//*fResult->fNumCellOffset;
     317
     318        const vector<int64_t> &sum = fData.GetSum();
    317319        if (!CopyData(fResult->fTrgOff))
    318320            return kFALSE;
     
    322324        fData.GetSampleStats(fBuffer.data()+1024*1440*4+4, 2000./4096/fResult->fNumOffset);//0.5);
    323325        reinterpret_cast<uint32_t*>(fBuffer.data())[0] = fNumSamples;
    324         reinterpret_cast<uint32_t*>(fBuffer.data())[3] = fRun->GetRunNumber();
     326        reinterpret_cast<uint32_t*>(fBuffer.data())[3] = fRun->GetFileNumber();
    325327    }
    326328
     
    333335
    334336    const std::string fname(Form("%s/%d_%03d.drs.fits", fOutputPath.Data(),
    335                                  fRun->GetRunStart().GetNightAsInt(), fRun->GetFileNumber()));
     337                                 fRun->GetRunNumber(), fRun->GetFileNumber()));
    336338
    337339    const Bool_t exists = !gSystem->AccessPathName(fname.c_str(), kFileExists);
     
    342344    }
    343345
    344     std::string msg = fResult->WriteFitsImp(fname, fBuffer);
     346    const std::string msg = fResult->WriteFitsImp(fname, fBuffer);
    345347
    346348    if (msg.empty())
Note: See TracChangeset for help on using the changeset viewer.