Index: trunk/MagicSoft/Mars/Changelog
===================================================================
--- trunk/MagicSoft/Mars/Changelog	(revision 5530)
+++ trunk/MagicSoft/Mars/Changelog	(revision 5531)
@@ -39,4 +39,7 @@
      - updated to new version of MPedCalcPedRun (only important for 
        intensity calibration)
+     - installed the new possible handling of two MPedestalCam's - one 
+       for the signal extractor and another one (with the extractor 
+       resolution) for MCalibrationChargeCalc.
       
    * msignal/MExtractTimeAndCharge.cc
Index: trunk/MagicSoft/Mars/macros/getExtractor.C
===================================================================
--- trunk/MagicSoft/Mars/macros/getExtractor.C	(revision 5530)
+++ trunk/MagicSoft/Mars/macros/getExtractor.C	(revision 5531)
@@ -107,5 +107,4 @@
 
   MExtractor *extractor   = NULL;
-  Bool_t useTimeAndCharge = kFALSE;
   
   //
@@ -148,5 +147,5 @@
       // ATTENTION: If an extractor deriving from MExtractTimeAndCharge is
       //            used, you may want to use the timing calculated directly
-      //            from there. Use the flag: "useTimeAndCharge" in this case
+      //            from there. 
       //
       // MExtractTimeHighestIntegral 
@@ -155,6 +154,4 @@
       //
       // COMBINED TIME AND CHARGE EXTRACTORS:
-      // (You have to set the variable "useTimeAndCharge" in order to use the 
-      //  time calculated by this extractor!)
       // MExtractTimeAndChargeDigitalFilter 
       // MExtractTimeAndChargeSpline        
@@ -169,5 +166,4 @@
       extractor = new MExtractTimeAndChargeSlidingWindow();
       extractor->SetRange(0,18,2,14);
-      useTimeAndCharge = kTRUE;
       break;
     case 23:
@@ -179,5 +175,4 @@
       ((MExtractTimeAndChargeSpline*)extractor)->SetChargeType(MExtractTimeAndChargeSpline::kIntegral);      
       extractor->SetRange(0,18,2,14);
-      useTimeAndCharge = kTRUE;
       break;
     case 28:
@@ -189,5 +184,4 @@
       extractor = new MExtractTimeAndChargeDigitalFilter;
       extractor->SetRange(0,18,2,14);
-      useTimeAndCharge = kTRUE;
       break;
     default:
Index: trunk/MagicSoft/Mars/mjobs/MJCalibration.cc
===================================================================
--- trunk/MagicSoft/Mars/mjobs/MJCalibration.cc	(revision 5530)
+++ trunk/MagicSoft/Mars/mjobs/MJCalibration.cc	(revision 5531)
@@ -1685,4 +1685,20 @@
       fTimeExtractor = &timespline;
 
+    //
+    // Look if the extractor is a pure charge or also a time extractor
+    //
+    if (fExtractor->InheritsFrom("MExtractTimeAndCharge"))
+      {
+        SetTimeAndCharge();
+        if (fExtractorCam.GetSize() == pedcam.GetSize())
+          {
+            plist.AddToList(&fExtractorCam);
+            calcalc.SetNamePedestalCam(fExtractorCam.GetName());
+          }
+        else
+          *fLog << warn << "Used Extractor derives from MExtractTimeAndCharge, " 
+                << "but no MExtractorCam has been handed over! " << endl;
+      }
+    
     MTaskEnv taskenv("ExtractSignal");
     taskenv.SetDefault(fExtractor);
Index: trunk/MagicSoft/Mars/mjobs/MJCalibration.h
===================================================================
--- trunk/MagicSoft/Mars/mjobs/MJCalibration.h	(revision 5530)
+++ trunk/MagicSoft/Mars/mjobs/MJCalibration.h	(revision 5531)
@@ -37,4 +37,7 @@
 #ifndef MARS_MBadPixelsCam
 #include "MBadPixelsCam.h"
+#endif
+#ifndef MARS_MPedestalCam
+#include "MPedestalCam.h"
 #endif
 
@@ -98,4 +101,6 @@
   MCalibrationRelTimeCam          fRelTimeCam;          // Calibration constants rel. times
   
+  MPedestalCam                    fExtractorCam;        // Pedestal Cam with extractor resolution
+
   MCalibrationCam::PulserColor_t fColor;                // Colour of the pulsed LEDs
   
@@ -143,5 +148,9 @@
   Bool_t IsHistsStorage () const { return TESTBIT(fStorage,kHistsStorage); }
 
-  void DrawTab(MParList &plist, const char *cont, const char *name, Option_t *opt);
+  void   SetTimeAndCharge( const Bool_t b=kTRUE ) { b 
+                                                      ? SETBIT(fFlags,kTimeAndCharge) 
+                                                      : CLRBIT(fFlags,kTimeAndCharge); }  
+
+  void   DrawTab(MParList &plist, const char *cont, const char *name, Option_t *opt);
   
   void   DisplayResult        ( MParList &plist );
@@ -177,10 +186,12 @@
   MBadPixelsCam                   &GetBadPixels()            { return fBadPixels;        }
   
-  void SetBadPixels(const MBadPixelsCam &bad)               { bad.Copy(fBadPixels); }
-  void SetExtractor(MExtractor* ext)                        { fExtractor = ext;     }
-  void SetTimeExtractor(MExtractTime* ext)                  { fTimeExtractor = ext; }
-  void SetQECam(const MCalibrationQECam &qe)                { qe.Copy(fQECam);      }
-  void SetColor(const MCalibrationCam::PulserColor_t color) { fColor = color;       }
-  void SetInput(MRunIter *iter)                             { fRuns = iter;         }
+  // Containers and pointers
+  void SetBadPixels    ( const MBadPixelsCam &bad)                   { bad.Copy(fBadPixels); }
+  void SetColor        ( const MCalibrationCam::PulserColor_t color) { fColor = color;       }
+  void SetExtractor    ( MExtractor* ext)                            { fExtractor = ext;     }
+  void SetExtractorCam ( const MPedestalCam  &ped)                   { ped.Copy(fExtractorCam); }  
+  void SetInput        ( MRunIter *iter)                             { fRuns = iter;         }
+  void SetQECam        ( const MCalibrationQECam &qe)                { qe.Copy(fQECam);      }
+  void SetTimeExtractor( MExtractTime* ext)                          { fTimeExtractor = ext; }
     
   // Displays
@@ -198,5 +209,4 @@
   void SetDebug             ( const Bool_t b=kTRUE ) { b ? SETBIT(fFlags,kDebug)     : CLRBIT(fFlags,kDebug); }
   void SetIntensity         ( const Bool_t b=kTRUE ) { b ? SETBIT(fFlags,kIntensity) : CLRBIT(fFlags,kIntensity); }
-  void SetTimeAndCharge      ( const Bool_t b=kTRUE ) { b ? SETBIT(fFlags,kTimeAndCharge) : CLRBIT(fFlags,kTimeAndCharge); }  
   
   // Devices
