Index: trunk/Mars/resmc/hawcseye/ceres.rc
===================================================================
--- trunk/Mars/resmc/hawcseye/ceres.rc	(revision 19679)
+++ trunk/Mars/resmc/hawcseye/ceres.rc	(revision 19680)
@@ -94,5 +94,5 @@
 # For details see MSimPointingPos
 # -------------------------------------------------------------------------
-#MSimPointingPos.OffTargetDistance: 0.4
+MSimPointingPos.OffTargetDistance: 0.6
 #MSimPointingPos.OffTargetPhi: -1
 
@@ -103,4 +103,10 @@
 #Reflector.Constructor: MReflector();
 Reflector.Constructor: MFresnelLens();
+
+Reflector.Transmission.FileName: resmc/hawcseye/transmission-pmma-3mm.txt
+Reflector.Transmission.Thickness: 0.3
+Reflector.Transmission.FresnelCorrection: True
+Reflector.SurfaceRoughness: 0.001
+
 
 # For the file definition see MReflector::ReadFile
@@ -118,5 +124,5 @@
 # This value is based on a direct measurement of the mirrors. There
 # is no way it can be wrong. Only the ray-tracing algorithm could be wrong.
-Reflector.SetSigmaPSF: 5
+Reflector.SetSigmaPSF: 2
 
 # --- DWARF ---
@@ -127,5 +133,5 @@
 
 #MGeomCam.Constructor:   MGeomCamDwarf(189.8,  9.5,  4.8887);
-MGeomCam.Constructor:   MGeomCamFAMOUS(0.502);
+MGeomCam.Constructor:   MGeomCamFAMOUS(0.502,false);
 
 #MSimBundlePhotons.FileName: resmc/fact/dwarf-fact.txt
@@ -133,20 +139,46 @@
 # Set the APD type (1: 30x30 <default>, 2: 60x60, 3:60x60(ct=15%))
 MSimAPD.Type: 5
-MSimExcessNoise.ExcessNoise: 0.12
+
+#MSimAPD.Type:                   0
+#MSimAPD.NumCells:               60
+#MSimAPD.DeadTime:               3.0
+#MSimAPD.RecoveryTime:           8.75
+#MSimAPD.CrosstalkCoefficient:   0.1
+#MSimAPD.AfterpulseProb1:        0.14
+#MSimAPD.AfterpulseProb2:        0.11
+
+MSimExcessNoise.ExcessNoise: 0.096
 
 # -------------------------------------------------------------------------
 # Setup the absorption, conversion efficiency and angular acceptance
 # -------------------------------------------------------------------------
-MirrorReflectivity.FileName:           resmc/hawcseye/reflectivity.txt
+# Note that all four curves enter the calculation of the background rate
+# but not necessarily all are applied!
+
+#MirrorReflectivity.FileName:           /home/fact_opr/mc_configuration_files/setup/ceres/030/MirrorReflectivity_Lustermann_FACT_bearbeitet.txt
+#PhotonDetectionEfficiency.FileName:    /home/fact_opr/mc_configuration_files/setup/ceres/030/fact-pde-1.4V.txt
+#ConesAngularAcceptance.FileName:       /home/fact_opr/mc_configuration_files/setup/ceres/030/fact-cones-angular-acceptance.txt
+#ConesTransmission.FileName:            /home/fact_opr/mc_configuration_files/setup/ceres/030/Transmittance_1439Cones_FACT_bearbeitet.txt
+
+#FIXME: This should be 2.5mm
+MirrorReflectivity.FileName:           resmc/hawcseye/transmission-pmma-3mm.txt
+
+#FIXME: This should be Hamamatsu/SensL
 PhotonDetectionEfficiency.FileName:    resmc/hawcseye/pde.txt
+
+#FIXME: Calculate for our aluminium and PMMA cones (this is for FACT cones)
 ConesAngularAcceptance.FileName:       resmc/hawcseye/cones-angular-acceptance.txt
+
+#FIXME: Calculate for out cones
 ConesTransmission.FileName:            resmc/fact/Transmittance_1439Cones_FACT_bearbeitet.txt
 
 # Skipped otherwise due to CEFFIC option
+# We use CEFFIC only for the atmosphere!
 SimPhotonDetectionEfficiency.Force: Yes
 SimMirrorReflectivity.Force: Yes
-
-
-# A backward motivated overall PDE adjustment. Introduced by Fabian T. to produce the ICRC2015 Crab spectrum. Fabian, please comment a bit more on this. In case this is only about the additional shielding of our camera support structure, then we schould actually name it like this.
+SimConesTransmission.Force: Yes
+
+# A backward motivated overall PDE adjustment. 
+# Introduced by Fabian T. to produce the ICRC2015 Crab spectrum. 
 
 AdditionalPhotonAcceptance.Function.Name:  0.8
@@ -173,4 +205,7 @@
 #MSimRandomPhotons.FrequencyNSB:   0.025
 
+MSimRandomPhotons.FileNameNSB: resmc/night-sky-la-palma.txt
+MSimRandomPhotons.FrequencyNSB: 0.0
+
 # FIXME: With a class describing the cones we could give NSB as
 # per sr and cm^2
@@ -187,5 +222,11 @@
 
 # DiscriminatorThreshold is 9*offset(-1850)+21*gain(22.375)=16180.125
-MSimTrigger.DiscriminatorThreshold: -16180.125
+#MSimTrigger.DiscriminatorThreshold: -16180.125
+MSimTrigger.DiscriminatorThreshold: -192.387
+# Note that this is in SAMPLES! I have taken the values from the SW trigger
+MSimTrigger.CableDelay: 21 
+MSimTrigger.CableDamping: -0.96
+MSimTrigger.CoincidenceTime: 0.5
+
 
 # Every Pixel(!) should see the same signal independant of its size
@@ -193,6 +234,6 @@
 MSimCalibrationSignal.NumEvents:  1000
 
+# This is an unfortunate naming convention. A better name would be "IntendedTriggerPos"
 # This is in nano-seconds (Mars-new) to be independent of the sampling frequency
-# This is in samples      (Mars-new2) to be independent of the sampling frequency
 IntendedPulsePos.Val: 150
 
@@ -220,7 +261,8 @@
 MSimCamera.DefaultOffset: -1850.0
 MSimCamera.DefaultNoise:    2.8125
-MSimCamera.DefaultGain:    22.375
+MSimCamera.DefaultGain:    22.553
 
 # Value for the fudgefactor in the calculation of the accoupling:
+# FIXME: If I am not mistaken, the time constant is in us ... to be checked
 MSimCamera.ACFudgeFactor: 0.3367
 MSimCamera.ACTimeConstant: 20
@@ -234,8 +276,12 @@
 # Attention: x in the function is given in slices, so if you change the sampling
 # frequency you have to change also this function
-PulseShape.Function.Name:  (1.626*(1-exp(-0.3803*0.5*x))*exp(-0.0649*0.5*x))
-PulseShape.Function.Npx:   900
-PulseShape.Function.Xmin:   0
-PulseShape.Function.Xmax:   300
+PulseShape.Function.Name:  (1.239*(1-1/(1+exp((0.5*x-2.851)/1.063)))*exp(-(0.5*x-2.851)/19.173))
+PulseShape.Function.Npx:   310
+PulseShape.Function.Xmin:  -10
+PulseShape.Function.Xmax:  300
+#PulseShape.Function.Name:  (1.626*(1-exp(-0.3803*0.5*x))*exp(-0.0649*0.5*x))
+#PulseShape.Function.Npx:   900
+#PulseShape.Function.Xmin:   0
+#PulseShape.Function.Xmax:   300
 
 # -------------------------------------------------------------------------
@@ -263,5 +309,5 @@
 
 ResidualTimeSpread.Val: 0.0
-GapdTimeJitter.Val: 0.0
+GapdTimeJitter.Val: 1.5
 
 # last line comment
