Index: trunk/MagicSoft/Simulation/Detector/Camera/creadparam.cxx
===================================================================
--- trunk/MagicSoft/Simulation/Detector/Camera/creadparam.cxx	(revision 390)
+++ trunk/MagicSoft/Simulation/Detector/Camera/creadparam.cxx	(revision 409)
@@ -19,7 +19,7 @@
 //=
 //= $RCSfile: creadparam.cxx,v $
-//= $Revision: 1.4 $
-//= $Author: blanch $ 
-//= $Date: 2000-05-11 14:22:33 $
+//= $Revision: 1.5 $
+//= $Author: MagicSol $ 
+//= $Date: 2000-07-04 14:13:02 $
 //=
 //=//////////////////////////////////////////////////////////////////////
@@ -71,6 +71,6 @@
 static char Starfield_filename[PATH_MAX_LENGTH]; //@< starfield input filename
 static char Data_filename[PATH_MAX_LENGTH];   //@< data filename
-static char DIAG_filename[PATH_MAX_LENGTH];  //@< data filename
 static char ROOT_filename[PATH_MAX_LENGTH];   //@< data filename
+static char Loop_filename[PATH_MAX_LENGTH];   //@< special data filename
 static char CT_filename[PATH_MAX_LENGTH];     //@< name of the CT def. file
 static int simulateNSB = TRUE;                //@< Will we simulate NSB?
@@ -89,5 +89,5 @@
 static int Write_All_Images = FALSE;
 static int Write_McEvt  = TRUE;
-static int Write_McTrig = FALSE;
+static int Write_McTrig = TRUE;
 static int Write_RawEvt = FALSE;
 static int Write_All_Data = FALSE;
@@ -102,4 +102,10 @@
 static int FADC_Scan = FALSE;
 static int Trigger_Loop = FALSE;
+static float Trigger_gate_length = 3.0;
+static float Trigger_response_ampl = 1.0;
+static float Trigger_response_fwhm = 2.0;
+static float Trigger_threshold = 7.0;
+static int Trigger_multiplicity = 4;
+static int Trigger_topology = 2;
 static int Trigger_loop_lthres = 0;
 static int Trigger_loop_uthres = 10;
@@ -206,12 +212,4 @@
       break;
 
-    case diag_file:          //@< name of the DIAG file
-          
-      // get the name of the data_file from the line
-      sscanf(line, "%s %s", token, DIAG_filename);
-      cout << '[' << DIAG_filename << ']' << endl << flush;
-
-      break;
-
     case root_file:          //@< name of the ROOT file
           
@@ -355,11 +353,4 @@
       break;
 
-    case write_RawEvt:    //@< to write the RawEvt data
-          
-      // change boolean value
-      Write_RawEvt = TRUE;
-
-      break;
-
     case write_all_data:      //@< to write single pixel data
           
@@ -406,4 +397,11 @@
 
       break;
+    case trigger_prop:
+
+      //  Get parameters for the diskriminator and the electronic
+      //  response for one phe
+      sscanf(line, "%s %f %f %f", token, &Trigger_gate_length, &Trigger_response_ampl,&Trigger_response_fwhm);
+
+      break;
 
     case trigger_loop:
@@ -417,4 +415,25 @@
       break;
 
+    case trigger_single:
+
+      //  Get trigger conditions
+      sscanf(line, "%s %f %d %d", token, &Trigger_threshold, &Trigger_multiplicity, &Trigger_topology);
+
+      // change boolean value
+      Trigger_Loop = FALSE;
+
+      break;
+
+    case Trigger_Loop_Output_Only_Specialists:
+
+      // get the name of the data_file from the line
+      sscanf(line, "%s %s", token, Loop_filename);
+      cout << '[' << Loop_filename << ']' << endl << flush;
+          
+      // change boolean value
+      Write_RawEvt = TRUE;
+      
+      break;
+
     case end_file:            //@< end of the parameters file
 
@@ -495,24 +514,4 @@
 
 //!-----------------------------------------------------------
-// @name get_diag_filename
-//                                                
-// @desc get name of the diagnostic output file
-//
-// @return   Name of the DIAG file
-//
-// @date Mon Sep 14 13:27:56 MET DST 1998
-//------------------------------------------------------------
-// @function 
-
-//!@{
-char *
-get_diag_filename(void)
-{
-  return (DIAG_filename);
-}
-//!@}
-
-
-//!-----------------------------------------------------------
 // @name get_root_filename
 //                                                
@@ -532,6 +531,22 @@
 }
 //!@}
-
-
+//!-----------------------------------------------------------
+// @name get_loop_filename
+//                                                
+// @desc get name of the special ROOT file
+//
+// @return   Name of the special ROOT file
+//
+// @date Fri Jun 23 17:34:19 CEST 2000
+//------------------------------------------------------------
+// @function 
+
+//!@{
+
+char *
+get_loop_filename(void)
+{
+  return (Loop_filename);
+}
 
 //!-----------------------------------------------------------
@@ -973,4 +988,22 @@
 {
   return ( Trigger_Scan );
+}
+//!@}
+
+//!-----------------------------------------------------------
+// @name Trigger_Propeties
+//                                                
+// @desc fix properties of the diskriminator and amplifier for Trigger 
+//
+//------------------------------------------------------------
+// @function 
+
+//!@{
+void
+get_Trigger_properties(float *gl, float *ra, float *rf)
+{
+  *gl=Trigger_gate_length;
+  *ra=Trigger_response_ampl;
+  *rf=Trigger_response_fwhm;
 }
 //!@}
@@ -1000,4 +1033,22 @@
 //!@}
 
+//!-----------------------------------------------------------
+// @name Trigger_Single
+//                                                
+// @desc fix Trigger conditions 
+//
+//------------------------------------------------------------
+// @function 
+
+//!@{
+void
+get_Trigger_Single(float *t, int *m, int *g)
+{
+  *t=Trigger_threshold;
+  *m=Trigger_multiplicity;
+  *g=Trigger_topology;
+
+}
+//!@}
 
 //=------------------------------------------------------------
@@ -1007,4 +1058,9 @@
 //
 // $Log: not supported by cvs2svn $
+// Revision 1.4  2000/05/11 14:22:33  blanch
+// New input card option has been introduced:
+// 	trigger_loop lt ut lm um lg ug
+// It forces the camera program to study several condition trigger implementations. Integers after key word fix limits of loop over thershold, multiplicity and topology.
+//
 // Revision 1.3  2000/03/24 18:14:05  blanch
 // Parameters that tell as if we are going to see the diskriminator and/or FADC signal have been included.
