Changeset 8999 for trunk


Ignore:
Timestamp:
07/14/08 20:59:13 (16 years ago)
Author:
tbretz
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
27 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/Changelog

    r8997 r8999  
    1818
    1919                                                 -*-*- END OF LINE -*-*-
     20
     21 2008/07/14 Thomas Bretz
     22
     23   * datacenter/macros/fillsignal.C:
     24     - moved sql.rc to constructor of MSQLMagic
     25
     26   * datacenter/macros/plotstat.C:
     27     - improved beauty of the SQL queries
     28     - join by telescope number, run number and file number
     29
     30   * mbase/MString.[h,cc]:
     31     - removed everything except Format which is then identical to
     32       newwer root versions TString::Format
     33
     34   * mastro/MAstro.cc, mastro/MAstroCatalog.cc:
     35     - replaced MString::Print by MString::Format
     36
     37   * mbase/MTime.cc:
     38     - In SetSqlDateTime allow also to set dates without time
     39
     40   * mbase/Makefile, mbase/BaseLinkDef.h:
     41     - removed MRunIter
     42
     43   * mfileio/MWriteRootFile.cc:
     44     - sow in status line if a tree has been finally copied
     45
     46   * mhist/MHEvent.cc:
     47     - replaced GetRunNumber by GetStringID
     48
     49   * mjobs/MJCalibrateSignal.cc:
     50     - Replaced RunNumber by FileId in trogger pattern display
     51     - do not allow to divide by 0
     52
     53   * mjobs/MJExtractSignal.cc, mjobs/MJCalibTest.cc:
     54     - removed obsolete include of MDirIter
     55
     56   * mjobs/MJPedestal.cc, mjobs/MJCalibration.cc:
     57     - replaced MRunIter by MDirIter
     58
     59   * mjobs/MSequence.[h,cc]:
     60     - moved code to compile (inflate) a run filename or a its path
     61       to new static function such that they can be accessed from the outside
     62
     63   * star.cc, callisto.cc, mjobs/MSequence.[h,cc], mmain/MEventDisplay.cc
     64     - renamed InflatePath to InflateSeq
     65
     66   * mpedestal/MPedCalcPedRun.cc:
     67     - when checking the runnumber check also for the telescope number
     68
     69   * mraw/MRawRunHeader.[h,cc]:
     70     - added new function GetStringID
     71
     72   * mraw/RawLinkDef.h, mraw/Makefile:
     73     - removed MRawSocketRead
     74
     75
    2076
    2177 2008/07/08 Daniel Hoehne
  • trunk/MagicSoft/Mars/callisto.cc

    r8988 r8999  
    281281    TString kSequence = arg.GetArgumentStr(0);
    282282
    283     if (!MSequence::InflatePath(kSequence, kIsMC))
     283    if (!MSequence::InflateSeq(kSequence, kIsMC))
    284284        return 3;
    285285
     
    345345    MArray::Class()->IgnoreTObjectStreamer();
    346346    MParContainer::Class()->IgnoreTObjectStreamer();
     347
     348    // FIXME: Remove all non-root arguments and options from argc, argv
    347349
    348350    TApplication app("callisto", &argc, argv);
  • trunk/MagicSoft/Mars/datacenter/macros/fillsignal.C

    r8952 r8999  
    5959#include <iomanip>
    6060
    61 #include <TEnv.h>
    6261#include <TRegexp.h>
    6362
     
    381380int fillsignal(TString fname, Bool_t dummy=kTRUE)
    382381{
    383     TEnv env("sql.rc");
    384 
    385     MSQLMagic serv(env);
     382    MSQLMagic serv("sql.rc");
    386383    if (!serv.IsConnected())
    387384    {
  • trunk/MagicSoft/Mars/datacenter/macros/plotstat.C

    r8996 r8999  
    11/* ======================================================================== *\
    2 ! $Name: not supported by cvs2svn $:$Id: plotstat.C,v 1.7 2008-07-05 19:01:42 tbretz Exp $
     2! $Name: not supported by cvs2svn $:$Id: plotstat.C,v 1.8 2008-07-14 19:59:06 tbretz Exp $
    33! --------------------------------------------------------------------------
    44!
     
    319319
    320320    // 0: All data for which are files available
    321     query[0]  = "select SUM(TIME_TO_SEC(TIMEDIFF(fRunStop, fRunStart)))/3600 ";
    322     query[0] += "from RunData left join RunProcessStatus on RunData.fRunNumber=RunProcessStatus.fRunNumber ";
    323     query[0] += "where fRunTypeKey=2 and not ISNULL(fRawFileAvail)";
     321    query[0]  = "SELECT SUM(TIME_TO_SEC(TIMEDIFF(fRunStop, fRunStart)))/3600 ";
     322    query[0] += "FROM RunData ";
     323    query[0] += "LEFT JOIN RunProcessStatus USING (fTelescopeNumber, fRunNumber, fFileNumber) ";
     324    query[0] += "WHERE fRunTypeKey=2 AND NOT ISNULL(fRawFileAvail)";
     325    /*
     326    if (tel>0)
     327    {
     328        query[0] += " AND fTelescopeNumber=";
     329        query[0] += tel;
     330    }
     331    */
    324332
    325333    // 1: All data
    326     query[1]  = "select SUM(TIME_TO_SEC(TIMEDIFF(fRunStop,fRunStart)))/3600 ";
    327     query[1] += "from RunData where fRunTypeKEY=2";
     334    query[1]  = "SELECTT SUM(TIME_TO_SEC(TIMEDIFF(fRunStop,fRunStart)))/3600 ";
     335    query[1] += "FROM RunData WHERE fRunTypeKEY=2";
    328336
    329337    // 2: All data which is not excluded
    330     query[2]  = "select SUM(TIME_TO_SEC(TIMEDIFF(fRunStop,fRunStart)))/3600 ";
    331     query[2] += "from RunData where fRunTypeKEY=2 and fExcludedFDAKEY=1";
     338    query[2]  = "SELECT SUM(TIME_TO_SEC(TIMEDIFF(fRunStop,fRunStart)))/3600 ";
     339    query[2] += "FROM RunData WHERE fRunTypeKEY=2 AND fExcludedFDAKEY=1";
    332340
    333341    // 3: All sequences
    334     query[3]  = "select SUM(fRunTime)/3600 from Sequences";
     342    query[3]  = "SELECT SUM(fRunTime)/3600 FROM Sequences";
    335343
    336344    // 4: All sequences with callisto failed
    337     query[4]  = "select SUM(fRunTime)/3600 from Sequences left join SequenceProcessStatus on ";
    338     query[4] += "Sequences.fSequenceFirst=SequenceProcessStatus.fSequenceFirst where ";
    339     query[4] += "ISNULL(fCallisto) and not ISNULL(fFailedTime) and not ISNULL(fAllFilesAvail)";
     345    query[4]  = "SELECT SUM(fRunTime)/3600 FROM Sequences ";
     346    query[4] += "LEFT JOIN SequenceProcessStatus USING (fSequenceFirst) ";
     347    query[4] += "WHERE ISNULL(fCallisto) AND NOT ISNULL(fFailedTime) AND NOT ISNULL(fAllFilesAvail)";
    340348
    341349    // 5: All sequences with callisto=OK
    342     query[5]  = "select SUM(fRunTime)/3600 from Sequences left join SequenceProcessStatus on ";
    343     query[5] += "Sequences.fSequenceFirst=SequenceProcessStatus.fSequenceFirst where not ISNULL(fCallisto)";
     350    query[5]  = "SELECT SUM(fRunTime)/3600 FROM Sequences ";
     351    query[5] += "LEFT JOIN SequenceProcessStatus USING (fSequenceFirst) ";
     352    query[5] += "WHERE NOT ISNULL(fCallisto)";
    344353
    345354    // 6: All sequences with star failed
    346     query[6]  = "select SUM(fRunTime)/3600 from Sequences left join SequenceProcessStatus on ";
    347     query[6] += "Sequences.fSequenceFirst=SequenceProcessStatus.fSequenceFirst where ";
    348     query[6] += "ISNULL(fStar) and not ISNULL(fFailedTime) and not ISNULL(fCallisto)";
     355    query[6]  = "SELECT SUM(fRunTime)/3600 FROM Sequences ";
     356    query[6] += "LEFT JOIN SequenceProcessStatus USING (fSequenceFirst) ";
     357    query[6] += "WHERE ISNULL(fStar) AND NOT ISNULL(fFailedTime) AND NOT ISNULL(fCallisto)";
    349358
    350359    // 7: All sequences with star=OK
    351     query[7]  = "select SUM(fRunTime)/3600 from Sequences left join SequenceProcessStatus on ";
    352     query[7] += "Sequences.fSequenceFirst=SequenceProcessStatus.fSequenceFirst where not ISNULL(fStar)";
     360    query[7]  = "SELECT SUM(fRunTime)/3600 FROM Sequences ";
     361    query[7] += "LEFT JOIN SequenceProcessStatus USING (fSequenceFirst) ";
     362    query[7] += "WHERE NOT ISNULL(fStar)";
    353363
    354364    // 0: All data
  • trunk/MagicSoft/Mars/mastro/MAstro.cc

    r8954 r8999  
    213213    Deg2Dms(deg, sgn, d, m, s);
    214214
    215     MString str;
    216     str.Print(fmt, sgn, d, m ,s);
    217     return str;
     215    return MString::Format(fmt, sgn, d, m ,s);
    218216}
    219217
     
    224222    Hor2Hms(deg, sgn, h, m, s);
    225223
    226     MString str;
    227     str.Print(fmt, sgn, h, m ,s);
    228     return str;
     224    return MString::Format(fmt, sgn, h, m ,s);
    229225}
    230226
  • trunk/MagicSoft/Mars/mastro/MAstroCatalog.cc

    r8907 r8999  
    11/* ======================================================================== *\
    2 ! $Name: not supported by cvs2svn $:$Id: MAstroCatalog.cc,v 1.30 2008-06-02 08:46:39 tbretz Exp $
     2! $Name: not supported by cvs2svn $:$Id: MAstroCatalog.cc,v 1.31 2008-07-14 19:59:08 tbretz Exp $
    33! --------------------------------------------------------------------------
    44!
     
    959959    const TVector2 deg = va*TMath::RadToDeg();
    960960
    961     MString txt;
    962     if (type==1)
    963         txt.Print("Ra=%.2fh  Dec=%.1fd", fmod(deg.X()/15+48, 24),  fmod(90-deg.Y()+270,180)-90);
    964     else
    965         txt.Print("Zd=%.1fd  Az=%.1fd",  fmod(deg.Y()+270,180)-90, fmod(deg.X()+720, 360));
     961    const TString txt = type==1 ?
     962        MString::Format("Ra=%.2fh  Dec=%.1fd", fmod(deg.X()/15+48, 24),  fmod(90-deg.Y()+270,180)-90) :
     963        MString::Format("Zd=%.1fd  Az=%.1fd",  fmod(deg.Y()+270,180)-90, fmod(deg.X()+720, 360));
    966964
    967965    TMarker *tip=new TMarker(v0.X(), v0.Y(), kDot);
  • trunk/MagicSoft/Mars/mbase/BaseLinkDef.h

    r8958 r8999  
    3232#pragma link C++ class MIter+;
    3333#pragma link C++ class MDirIter+;
    34 #pragma link C++ class MRunIter+;
     34//#pragma link C++ class MRunIter+;
    3535#pragma link C++ class MThread+;
    3636
  • trunk/MagicSoft/Mars/mbase/MString.cc

    r7887 r8999  
    1818!   Author(s): Thomas Bretz, 3/2004 <mailto:tbretz@astro.uni-wuerzburg.de>
    1919!
    20 !   Copyright: MAGIC Software Development, 2000-2004
     20!   Copyright: MAGIC Software Development, 2000-2008
    2121!
    2222!
     
    4444/////////////////////////////////////////////////////////////////////////////
    4545#include "MString.h"
     46
     47#include <stdarg.h>
    4648
    4749ClassImp(MString);
     
    9799//  string.Print("  MyString has %d bytes  ", 128).Strip(TString::kBoth);
    98100//
     101/*
    99102MString &MString::Print(const char *fmt, ...)
    100103{
     
    104107    return Print(fmt, ap);
    105108}
     109*/
    106110
    107111// --------------------------------------------------------------------------
     
    120124// M/TString.
    121125//
    122 MString MString::Format(const char *fmt, ...)
     126#if ROOT_VERSION_CODE<ROOT_VERSION(5,18,00)
     127TString MString::Format(const char *fmt, ...)
    123128{
    124129    va_list ap;
     
    129134    return ret;
    130135}
     136#endif
    131137
    132138// --------------------------------------------------------------------------
     
    135141// TString::Form didn't exist.
    136142//
     143/*
    137144void MString::Form(const char *fmt, ...)
    138145{
     
    142149    Print(fmt, ap);
    143150}
     151*/
  • trunk/MagicSoft/Mars/mbase/MString.h

    r7889 r8999  
    66#endif
    77
    8 #include <stdio.h>
    9 #include <stdarg.h>
    10 
    118class MString : public TString
    129{
     10private:
     11    MString &Print(const char *fmt, va_list &ap);
     12//    MString &Print(const char *fmt, ...);
     13
    1314public:
    1415    MString(const char *txt=0)  : TString(txt) { }
    15     MString(const MString &txt) : TString(txt) { }
    16 
    17     MString &Print(const char *fmt, va_list &ap);
    18     MString &Print(const char *fmt, ...);
     16    MString(const TString &txt) : TString(txt) { }
    1917
    2018#ifndef __CINT__
    21     static MString Format(const char *fmt, ...);
     19#if ROOT_VERSION_CODE<ROOT_VERSION(5,18,00)
     20    static TString Format(const char *fmt, ...);
     21#endif
    2222#endif
    2323
    24     void Form(const char *fmt, ...);
     24    //void Form(const char *fmt, ...);
    2525
    26     ClassDef(MString, 1) // Tool to make Form() thread safe against other TStrings
     26    ClassDef(MString, 1) // Tool to make Form() thread safe against other TStrings for root prior 5.18.00
    2727};
    2828
  • trunk/MagicSoft/Mars/mbase/MTime.cc

    r8996 r8999  
    403403        return kFALSE;
    404404
    405     UInt_t y, mon, d, h, m, s;
    406     const Int_t n = sscanf(str, "%04u-%02u-%02u %02u:%02u:%02u",
    407                            &y, &mon, &d, &h, &m, &s);
    408 
    409     return n==6 ? Set(y, mon, d, h, m, s) : kFALSE;
     405    UInt_t  y, mon, d, h, m, s;
     406    if (6==sscanf(str, "%04u-%02u-%02u %02u:%02u:%02u", &y, &mon, &d, &h, &m, &s))
     407        return Set(y, mon, d, h, m, s);
     408
     409    if (3==sscanf(str, "%04u-%02u-%02u", &y, &mon, &d))
     410        return Set(y, mon, d);
     411
     412    return kFALSE;
    410413}
    411414
  • trunk/MagicSoft/Mars/mbase/Makefile

    r8892 r8999  
    4343           MIter.cc \
    4444           MDirIter.cc \
    45            MRunIter.cc \
    4645           MReadSocket.cc \
    4746           MGGroupFrame.cc \
  • trunk/MagicSoft/Mars/mfileio/MWriteRootFile.cc

    r8674 r8999  
    925925
    926926    *fLog << "done." << endl;
     927
     928    if (fDisplay)
     929    {
     930        out += " done.";
     931        fDisplay->SetStatusLine2(out);
     932    }
    927933}
    928934
  • trunk/MagicSoft/Mars/mhist/MHEvent.cc

    r8940 r8999  
    271271    if (fRawRunHeader)
    272272    {
    273         s += "Run #";
    274         s += fRawRunHeader->GetRunNumber();
     273        s += "M";
     274        s += fRawRunHeader->GetStringID();
    275275    }
    276276    if (fTime)
  • trunk/MagicSoft/Mars/mjobs/MJCalibTest.cc

    r8498 r8999  
    4242#include "MLogManip.h"
    4343
    44 #include "MRunIter.h"
    4544#include "MParList.h"
    4645#include "MTaskList.h"
  • trunk/MagicSoft/Mars/mjobs/MJCalibrateSignal.cc

    r8988 r8999  
    410410    MTriggerPatternDecode     decode;
    411411
    412     MH3 hpat("MRawRunHeader.fRunNumber", "MTriggerPattern.GetUnprescaled");
    413     hpat.SetWeight("1./MRawRunHeader.GetRunLength");
     412    MH3 hpat("MRawRunHeader.GetFileID", "MTriggerPattern.GetUnprescaled");
     413    hpat.SetWeight("1./TMath::Max(MRawRunHeader.GetRunLength,1)");
    414414    hpat.SetName("TrigPat");
    415     hpat.SetTitle("Rate of the trigger pattern [Hz];Run Number;Trigger Pattern;Rate [Hz]");
     415    hpat.SetTitle("Rate of the trigger pattern [Hz];File Id;Trigger Pattern;Rate [Hz]");
    416416    hpat.InitLabels(MH3::kLabelsXY);
    417417    //hpat.DefineLabelsY("1=Lvl1;2=Cal;3=Cal;4=Lvl2;5=Cal;7=Cal;8=Ped;9=Ped+Trig;13=Ped+Trig;16=Pin;32=Sum");
  • trunk/MagicSoft/Mars/mjobs/MJCalibration.cc

    r8990 r8999  
    105105
    106106#include "MEnv.h"
    107 #include "MRunIter.h"
     107#include "MDirIter.h"
    108108#include "MSequence.h"
    109109#include "MParList.h"
  • trunk/MagicSoft/Mars/mjobs/MJExtractSignal.cc

    r4773 r8999  
    3838#include "MLogManip.h"
    3939
    40 #include "MRunIter.h"
    4140#include "MParList.h"
    4241#include "MTaskList.h"
  • trunk/MagicSoft/Mars/mjobs/MJPedestal.cc

    r8990 r8999  
    5252#include "MLogManip.h"
    5353
     54#include "MDirIter.h"
    5455#include "MTaskEnv.h"
    5556#include "MSequence.h"
    56 #include "MRunIter.h"
    5757#include "MParList.h"
    5858#include "MTaskList.h"
  • trunk/MagicSoft/Mars/mjobs/MSequence.cc

    r8996 r8999  
    379379}
    380380
     381TString MSequence::InflateRunPath(const MTime &night, Bool_t mc)
     382{
     383    TString rc = GetStandardPath(mc);
     384    rc += "rawfiles/";
     385    rc += night.GetStringFmt("%Y/%m/%d/");
     386    return rc;
     387}
     388
     389TString MSequence::InflateRunPath(const MTime &night, UShort_t tel, Int_t run, Int_t file, Int_t type)
     390{
     391    return InflateRunPath(night)+InflateRunName(night, tel, run, file, type);
     392}
     393
    381394// --------------------------------------------------------------------------
    382395//
     
    421434}
    422435
    423 // --------------------------------------------------------------------------
    424 //
    425 // Return the expression describing the file-name for the file defined
    426 // by i-th entry of the the given arrays. The file type identifier is
    427 // defined by type. The source name is replaced by a wildcard and
    428 // the extension is defined by the type as well.
    429 //
    430 TString MSequence::GetFileName(UInt_t i, const TArrayI &arr, const TArrayI &sub, FileType_t type) const
     436TString MSequence::InflateRunName(const MTime &night, UShort_t tel, Int_t run, Int_t file, Int_t type)
    431437{
    432438    const char *id="_";
     
    458464
    459465    // ------------- Create file name --------------
    460     TString n = fNight.GetStringFmt("%Y%m%d_");
    461 
    462     if (arr[i]>999999)
    463         n += "M1_";
    464 
    465     // R. DeLosReyes and T. Bretz
    466     // Changes to read the DAQ numbering format. Changes takes place
    467     // between runs 35487 and 00035488 (2004_08_30)
    468     n += Form(arr[i]>35487 || fMonteCarlo ? "%08d" : "%05d", arr[i]);
    469 
    470     if (arr[i]>999999 && sub.GetSize()>0)
    471         n += Form(".%05d", sub[i]);
     466    TString n = night.GetStringFmt("%Y%m%d_");
     467
     468    // This is for MCs (FIXME!!!!)
     469    if (run<0)
     470        n += Form("%08d", -run);
     471    else
     472    {
     473        if (tel>0)
     474            n += Form("M%d_", tel);
     475
     476        // R. DeLosReyes and T. Bretz
     477        // Changes to read the DAQ numbering format. Changes takes place
     478        // between runs 35487 and 00035488 (2004_08_30)
     479        n += Form(run>35487 ? "%08d" : "%05d", run);
     480
     481        if (tel>0)
     482            n += Form(".%05d", file);
     483    }
    472484
    473485    n += "_";
     
    475487    n += "_*";
    476488
    477     if (arr[i]<1000000)
     489    if (tel==0)
    478490        n += "_E";
    479491
     
    484496    case kRawCal:
    485497    case kRawAll:
    486         n += ".raw.?g?z?";
     498        n += ".raw.?g?z?";  // TPRegexp: (\.gz)?
    487499        break;
    488500    default:
     
    491503
    492504    return n;
     505}
     506
     507// --------------------------------------------------------------------------
     508//
     509// Return the expression describing the file-name for the file defined
     510// by i-th entry of the the given arrays. The file type identifier is
     511// defined by type. The source name is replaced by a wildcard and
     512// the extension is defined by the type as well.
     513//
     514TString MSequence::GetFileName(UInt_t i, const TArrayI &arr, const TArrayI &sub, FileType_t type) const
     515{
     516    const Int_t tel = 1;
     517    return InflateRunName(fNight, arr[i]>999999?tel:0, fMonteCarlo?-arr[i]:arr[i], sub.GetSize()>0?sub[i]:0, type);
    493518}
    494519
     
    11831208// Returns if file accessible or not.
    11841209//
    1185 Bool_t MSequence::InflatePath(TString &seq, Bool_t ismc)
     1210Bool_t MSequence::InflateSeq(TString &seq, Bool_t ismc)
    11861211{
    11871212    if (seq.IsDigit())
  • trunk/MagicSoft/Mars/mjobs/MSequence.h

    r8996 r8999  
    2727
    2828    UInt_t fSequence;          // Sequence number
     29
     30    // FIXME: UShort_t fTelescopeNumber ???
    2931
    3032    MTime  fStart;             // Start time of sequence
     
    170172    const TString &GetDataPath() const { return fDataPath; }
    171173
    172     const TString GetStandardPath() const { return fMonteCarlo?"/magic/montecarlo/":"/magic/data/"; }
     174    const TString  GetStandardPath() const { return GetStandardPath(fMonteCarlo); }
    173175
    174     static Bool_t InflatePath(TString &seq, Bool_t ismc=kFALSE);
     176    // Static function for external access
     177    static TString GetStandardPath(Bool_t mc) { return mc?"/magic/montecarlo/":"/magic/data/"; }
     178    static Bool_t  InflateSeq(TString &seq, /*FIXME: TELNUM*/ Bool_t ismc=kFALSE);
     179
     180    static TString InflateRunName(const MTime &night, UShort_t tel, Int_t run, Int_t file, Int_t type=kRawAll);
     181    static TString InflateRunName(const MTime &night, Int_t run, Int_t type=kRawAll) { return InflateRunName(night, 1, run, 0, type); }
     182
     183    static TString InflateRunPath(const MTime &night, UShort_t tel, Int_t run, Int_t file=0, Int_t type=kRawAll);
     184    static TString InflateRunPath(const MTime &night, Int_t run, Int_t type=kRawAll) { return InflateRunPath(night, 1, run, 0, type); }
     185
     186    static TString InflateRunPath(const MTime &night, Bool_t mc=kFALSE);
    175187
    176188    ClassDef(MSequence, 5) // Describes a sequences, reads and writes sequence files
  • trunk/MagicSoft/Mars/mmain/MEventDisplay.cc

    r8941 r8999  
    11/* ======================================================================== *\
    2 ! $Name: not supported by cvs2svn $:$Id: MEventDisplay.cc,v 1.63 2008-06-12 14:40:21 tbretz Exp $
     2! $Name: not supported by cvs2svn $:$Id: MEventDisplay.cc,v 1.64 2008-07-14 19:59:11 tbretz Exp $
    33! --------------------------------------------------------------------------
    44!
     
    200200    }
    201201
    202     if (type==0 && !MSequence::InflatePath(fname))
     202    if (type==0 && !MSequence::InflateSeq(fname))
    203203        return;
    204204
  • trunk/MagicSoft/Mars/mpedestal/MPedCalcPedRun.cc

    r8788 r8999  
    11/* ======================================================================== *\
    2 ! $Name: not supported by cvs2svn $:$Id: MPedCalcPedRun.cc,v 1.52 2007-12-14 09:56:03 tbretz Exp $
     2! $Name: not supported by cvs2svn $:$Id: MPedCalcPedRun.cc,v 1.53 2008-07-14 19:59:12 tbretz Exp $
    33! --------------------------------------------------------------------------
    44!
     
    323323Bool_t MPedCalcPedRun::IsPedBitSet()
    324324{
    325     if (fRunHeader->GetRunNumber()<gkFirstRunWithFinalBits)
     325    if (fRunHeader->GetTelescopeNumber()==1 && fRunHeader->GetRunNumber()<gkFirstRunWithFinalBits)
    326326        return kFALSE;
    327327
  • trunk/MagicSoft/Mars/mraw/MRawRunHeader.cc

    r8979 r8999  
    156156
    157157#include "MArrayS.h"
     158#include "MString.h"
    158159
    159160ClassImp(MRawRunHeader);
     
    268269// --------------------------------------------------------------------------
    269270//
     271// Return Telescope number, runnumber and filenumber on the form:
     272//      run
     273// as string for runnumber<1000000 and
     274//      telescope:run/file
     275// otherwise.
     276//
     277TString  MRawRunHeader::GetStringID() const
     278{
     279    return fRunNumber<1000000?MString::Format("%d", fRunNumber):MString::Format("%d:%d/%d", fTelescopeNumber, fRunNumber, fFileNumber);
     280}
     281
     282// --------------------------------------------------------------------------
     283//
    270284// Consistency checks. See code for detils.
    271285//
  • trunk/MagicSoft/Mars/mraw/MRawRunHeader.h

    r8970 r8999  
    108108    UInt_t   GetTypeID() const            { return (fRunNumber/1000000)%100; }
    109109    UInt_t   GetFileID() const            { return fRunNumber>1000000?(fRunNumber%1000000)*1000+(fFileNumber%1000):fRunNumber; }
     110    TString  GetStringID() const;
    110111    UShort_t GetTelescopeNumber() const   { return fRunType; }
    111112    UShort_t GetRunType() const           { return fRunType; }
  • trunk/MagicSoft/Mars/mraw/Makefile

    r8961 r8999  
    2929           MRawCrateData.cc \
    3030           MRawRead.cc \
    31            MRawFileRead.cc \
    32            MRawSocketRead.cc
     31           MRawFileRead.cc
    3332
    3433############################################################
  • trunk/MagicSoft/Mars/mraw/RawLinkDef.h

    r8961 r8999  
    1515
    1616#pragma link C++ class MRawRead+;
    17 #pragma link C++ class MRawSocketRead+;
    1817#pragma link C++ class MRawFileRead+;
     18//#pragma link C++ class MRawSocketRead+;
    1919//#pragma link C++ class MRawFileWrite+;
    2020
  • trunk/MagicSoft/Mars/star.cc

    r8986 r8999  
    180180    // Something special for datacenter access
    181181    //
    182     if (!MSequence::InflatePath(kSequence, kIsMC))
     182    if (!MSequence::InflateSeq(kSequence, kIsMC))
    183183        return 2;
    184184
Note: See TracChangeset for help on using the changeset viewer.