Changeset 9010 for trunk


Ignore:
Timestamp:
07/17/08 19:15:35 (16 years ago)
Author:
tbretz
Message:
*** empty log message ***
Location:
trunk/MagicSoft/Mars
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/MagicSoft/Mars/datacenter/macros/writesequencefile.C

    r9005 r9010  
    4848/////////////////////////////////////////////////////////////////////////////
    4949#include "MSequence.h"
     50#include "MSQLMagic.h"
    5051
    5152using namespace std;
    5253
    53 int writeseq(Int_t sequno, Int_t tel, TString sequpath="")
     54int writesequencefile(Int_t sequno, Int_t tel, TString sequpath="")
    5455{
    5556    MSQLMagic serv("sql.rc");
  • trunk/MagicSoft/Mars/mcamera/MCameraDC.cc

    r2893 r9010  
    1818!   Author(s): Thomas Bretz, 5/2003 <mailto:tbretz@astro.uni-wuerzburg.de>
    1919!
    20 !   Copyright: MAGIC Software Development, 2000-2003
     20!   Copyright: MAGIC Software Development, 2000-2008
    2121!
    2222!
     
    2626//
    2727// MCameraDC (PRELIMINARY)
     28//
     29//
     30// Version 2:
     31// ----------
     32//   + fStatus
     33//
    2834//
    2935/////////////////////////////////////////////////////////////////////////////
     
    4450//
    4551MCameraDC::MCameraDC(Int_t size, const char *name, const char *title)
    46     : fArray(size)
     52    : fStatus(0), fArray(size)
    4753{
    4854    fName  = name  ? name  : "MCameraDC";
    4955    fTitle = title ? title : "Storage container for the pixel currents";
     56}
     57
     58// --------------------------------------------------------------------------
     59//
     60// Interprete a DC report context
     61//
     62Int_t MCameraDC::Interprete(TString &str, Int_t len)
     63{
     64    const char *pos = str.Data()+len;
     65    const char *end = pos+577*4;
     66
     67    Int_t i=0;
     68    while (pos<end)
     69    {
     70        Int_t c;
     71        const Char_t hex[5] = { pos[0], pos[1], pos[2], pos[3], 0 };
     72        pos += 4;
     73
     74        const Int_t nn=sscanf(hex, "%4x", &c);
     75        if (nn!=1)
     76        {
     77            *fLog << warn << "WARNING - Reading hexadecimal DC information." << endl;
     78            return kCONTINUE;
     79        }
     80
     81        fArray[i++] = 0.001*c;
     82    }
     83
     84    str.Remove(0, pos-str.Data()); // Remove DC currents
     85    str=str.Strip(TString::kLeading);
     86
     87    return str.IsNull() ? kTRUE : kCONTINUE;
    5088}
    5189
  • trunk/MagicSoft/Mars/mjobs/MSequenceSQL.cc

    r9002 r9010  
    179179    // Now prepare queries to request the runs from the database
    180180    TString where(Form(" FROM RunData WHERE"
    181                        " fTelescopeTelescope=%d AND fSequenceFirst=%d AND"
     181                       " fTelescope=%d AND fSequenceFirst=%d AND"
    182182                       " fExcludedFDAKEY=1 AND fRunTypeKEY%%s",
    183183                       fTelescope, fSequence));
Note: See TracChangeset for help on using the changeset viewer.