Index: trunk/MagicSoft/Mars/Changelog
===================================================================
--- trunk/MagicSoft/Mars/Changelog	(revision 6465)
+++ trunk/MagicSoft/Mars/Changelog	(revision 6466)
@@ -27,4 +27,6 @@
      - added some more information to '--help' output
      - replaced MSequences by MDataSet
+     - implemented new debugging options (maybe not perfect yet)
+       --print-files and --print-found
 
    * mjobs/MJCut.[h,cc]: 
@@ -32,4 +34,6 @@
      - write MEnergyEst
      - recalculate MHillasSrc
+     - made sure both MWriteRootFile have different names
+     - don't use "same" option if no off-data
 
    * mjobs/MSequences.[h,cc]: 
@@ -60,4 +64,5 @@
      - the same for the calibration factor - with the same argument
      - adapted to change in MWriteRootFile
+     - use MReadMarsFile for Monte Carlo flag set
 
    * mhist/MHCamera.cc:
@@ -92,7 +97,10 @@
      - added a pattern independant trigger algorithm
 
-   * mjobs/MJCut.cc:
-     - made sure both MWriteRootFile have different names
-     - don't use "same" option if no off-data
+   * mbase/MDirIter.cc:
+     - implemented option 'dbg' in Print()
+
+   * mjobs/MJCalib.h:
+     - added a getter for data-flag (should be renamed
+       to 'datatype' soon)
 
 
Index: trunk/MagicSoft/Mars/callisto.cc
===================================================================
--- trunk/MagicSoft/Mars/callisto.cc	(revision 6465)
+++ trunk/MagicSoft/Mars/callisto.cc	(revision 6466)
@@ -76,5 +76,5 @@
     gLog << "   --print-seq               Print Sequence information" << endl;
     gLog << "   --print-files             Print Files taken from Sequence" << endl;
-    gLog << "   --print-only              Do not execute anything except print" << endl;
+    gLog << "   --print-found             Print Files found from Sequence" << endl;
     gLog << "   --use-test                Apply calibration constants to same calibration" << endl;
     gLog << "                             file (for testing, calibration mode only)" << endl;
@@ -103,4 +103,25 @@
 }
 
+static void PrintFiles(const MSequence &seq, const TString &kInpathD, Bool_t raw, Bool_t all)
+{
+    const char *prep = all ? "Found" : "Scheduled";
+
+    MDirIter Next1, Next2, Next3;
+    seq.SetupPedRuns(Next1, kInpathD, "P", raw);
+    seq.SetupCalRuns(Next2, kInpathD, "C", raw);
+    seq.SetupDatRuns(Next3, kInpathD, "D", raw);
+
+    gLog << all;
+    gLog.Separator(Form("%s Pedestal Files", prep));
+    Next1.Print(all?"all":"");
+    gLog << endl;
+    gLog.Separator(Form("%s Calibration Files", prep));
+    Next2.Print(all?"all":"");
+    gLog << endl;
+    gLog.Separator(Form("%s Data Files", prep));
+    Next3.Print(all?"all":"");
+    gLog << endl;
+}
+
 int main(int argc, char **argv)
 {
@@ -126,6 +147,6 @@
 
     const Bool_t  kPrintSeq   = arg.HasOnlyAndRemove("--print-seq");
-    //const Bool_t  kPrintFiles = arg.HasOnlyAndRemove("--print-files");
-    //const Bool_t  kPrintOnly  = arg.HasOnlyAndRemove("--print-only");
+    const Bool_t  kPrintFiles = arg.HasOnlyAndRemove("--print-files");
+    const Bool_t  kPrintFound = arg.HasOnlyAndRemove("--print-found");
     const Bool_t  kUseTest    = arg.HasOnlyAndRemove("--use-test");
     const Bool_t  kDebugEnv   = arg.HasOnlyAndRemove("--debug-env");
@@ -236,27 +257,13 @@
         return -1;
     }
+
+    //
+    // Process print options
+    //
+    if (kPrintFiles)
+        PrintFiles(seq, kInpathD, kDataType==MJCalib::kIsUseRawData, kFALSE);
+    if (kPrintFound)
+        PrintFiles(seq, kInpathD, kDataType==MJCalib::kIsUseRawData, kTRUE);
 /*
-    //
-    // Process print options
-    //
-    if (kPrintFiles)
-    {
-        MDirIter Next1, Next2, Next3;
-        seq.SetupPedRuns(Next1, kInpathD);
-        seq.SetupCalRuns(Next2, kInpathD);
-        seq.SetupDatRuns(Next3, kInpathD);
-
-        gLog << all;
-        gLog.Separator("Pedestal Files");
-        Next1.Print("all");
-        gLog << endl;
-        gLog.Separator("Calibration Files");
-        Next2.Print("all");
-        gLog << endl;
-        gLog.Separator("Data Files");
-        Next3.Print("all");
-        gLog << endl;
-    }
-
     //
     // Check for existance of all files
Index: trunk/MagicSoft/Mars/mbase/MDirIter.cc
===================================================================
--- trunk/MagicSoft/Mars/mbase/MDirIter.cc	(revision 6465)
+++ trunk/MagicSoft/Mars/mbase/MDirIter.cc	(revision 6466)
@@ -351,4 +351,7 @@
 {
     TString s(o);
+    if (s.Contains("dbg", TString::kIgnoreCase))
+        fList.Print();
+
     if (!s.Contains("all", TString::kIgnoreCase))
     {
Index: trunk/MagicSoft/Mars/mjobs/MJCalib.h
===================================================================
--- trunk/MagicSoft/Mars/mjobs/MJCalib.h	(revision 6465)
+++ trunk/MagicSoft/Mars/mjobs/MJCalib.h	(revision 6466)
@@ -31,4 +31,6 @@
     void SetInput(MRunIter *iter) { fRuns = iter; }
 
+    Byte_t GetDataFlag() const { return fDataFlag; }
+
     Bool_t IsUseRawData()  const { return fDataFlag==kIsUseRawData;  }
     Bool_t IsUseRootData() const { return fDataFlag==kIsUseRootData; }
Index: trunk/MagicSoft/Mars/mjobs/MJCalibrateSignal.cc
===================================================================
--- trunk/MagicSoft/Mars/mjobs/MJCalibrateSignal.cc	(revision 6465)
+++ trunk/MagicSoft/Mars/mjobs/MJCalibrateSignal.cc	(revision 6466)
@@ -352,11 +352,21 @@
     readreal.AddTree("Currents");
 
-    //MReadMarsFile read("Events");
-    //read.DisableAutoScheme();
+    MReadMarsFile readmc("Events");
+    readmc.DisableAutoScheme();
+
     MRawFileRead rawread(NULL);
-    if (IsUseRawData())
+
+    switch (GetDataFlag())
+    {
+    case kIsUseRawData:
         rawread.AddFiles(fSequence.IsValid() ? iter : *fRuns);
-    else
+        break;
+    case kIsUseMC:
+        readmc.AddFiles(fSequence.IsValid() ? iter : *fRuns);
+        break;
+    case kIsUseRootData:
         readreal.AddFiles(fSequence.IsValid() ? iter : *fRuns);
+        break;
+    }
 
     MPointingPosInterpolate pextr;
@@ -672,5 +682,17 @@
 
     // Now setup main tasklist
-    tlist.AddToList(IsUseRawData() ? (MTask*)&rawread : (MTask*)&readreal);
+    switch (GetDataFlag())
+    {
+    case kIsUseRawData:
+        tlist.AddToList(&rawread);
+        break;
+    case kIsUseMC:
+        tlist.AddToList(&readmc);
+        break;
+    case kIsUseRootData:
+        tlist.AddToList(&readreal);
+        break;
+    }
+    //tlist.AddToList(IsUseRawData() ? (MTask*)&rawread : (MTask*)&readreal);
     if (IsUseRootData())
       tlist2.AddToList(&pextr);
Index: trunk/MagicSoft/Mars/star.cc
===================================================================
--- trunk/MagicSoft/Mars/star.cc	(revision 6465)
+++ trunk/MagicSoft/Mars/star.cc	(revision 6466)
@@ -64,5 +64,5 @@
     gLog << "   --print-seq               Print Sequence information" << endl;
     gLog << "   --print-files             Print Files taken from Sequence" << endl;
-    gLog << "   --print-only              Do not excute anything except print" << endl;
+    gLog << "   --print-found             Print Files found from Sequence" << endl;
     gLog << "   --config=star.rc          Resource file [default=star.rc]" << endl;
     gLog << endl;
@@ -71,4 +71,17 @@
 }
 
+static void PrintFiles(const MSequence &seq, const TString &kInpathD, Bool_t allopt)
+{
+    const char *prep = allopt ? "Found" : "Scheduled";
+
+    MDirIter Next;
+    seq.SetupDatRuns(Next, kInpathD, "Y");
+
+    gLog << all;
+    gLog.Separator(Form("%s Data Files", prep));
+    Next.Print(allopt?"all":"");
+    gLog << endl;
+}
+
 int main(int argc, char **argv)
 {
@@ -94,6 +107,6 @@
 
     const Bool_t  kPrintSeq   = arg.HasOnlyAndRemove("--print-seq");
-    //const Bool_t  kPrintFiles = arg.HasOnlyAndRemove("--print-files");
-    //const Bool_t  kPrintOnly  = arg.HasOnlyAndRemove("--print-only");
+    const Bool_t  kPrintFiles = arg.HasOnlyAndRemove("--print-files");
+    const Bool_t  kPrintFound = arg.HasOnlyAndRemove("--print-found");
     const Bool_t  kDebugEnv   = arg.HasOnlyAndRemove("--debug-env");
     const Bool_t  kDebugMem   = arg.HasOnlyAndRemove("--debug-mem");
@@ -156,36 +169,8 @@
     // Process print options
     //
-    /*
-    MDirIter iter;
-
-    const Int_t n0 = seq.SetupDatRuns(iter, kInpath);
-    const Int_t n1 = seq.GetNumDatRuns();
-
     if (kPrintFiles)
-    {
-        gLog << all;
-        gLog.Separator("Data Files");
-        iter.Print("all");
-        gLog << endl;
-    }
-
-    //
-    // Check for existance of all files
-    //
-    if (n0 != n1)
-    {
-        if (kForceExec)
-            gLog << warn << "WARNING";
-        else
-            gLog << err << "ERROR";
-        gLog << " - " << n1 << " files in sequence defined, but " << n0 << " found in ";
-        gLog << (kInpath.IsNull() ? "<defaultpath>" : kInpath.Data()) << endl;
-        if (!kForceExec)
-            return -1;
-    }
-
-    if (kPrintOnly)
-        return 0;
-        */
+        PrintFiles(seq, kInpath, kFALSE);
+    if (kPrintFound)
+        PrintFiles(seq, kInpath, kTRUE);
 
     //
