psddl_psana/include/timetool.ddl.h

Go to the documentation of this file.
00001 #ifndef PSANA_TIMETOOL_DDL_H
00002 #define PSANA_TIMETOOL_DDL_H 1
00003 
00004 // *** Do not edit this file, it is auto-generated ***
00005 
00006 #include <vector>
00007 #include <iosfwd>
00008 #include <cstring>
00009 #include "ndarray/ndarray.h"
00010 #include "pdsdata/xtc/TypeId.hh"
00011 #include "psddl_psana/camera.ddl.h"
00012 #include "pdsdata/xtc/Src.hh"
00013 namespace Psana {
00014 namespace TimeTool {
00015 
00016 /** @class EventLogic
00017 
00018   
00019 */
00020 
00021 
00022 class EventLogic {
00023 public:
00024   enum LogicOp {
00025     L_OR = 0,
00026     L_AND = 1,
00027     L_OR_NOT = 2,
00028     L_AND_NOT = 3,
00029   };
00030   EventLogic(uint8_t arg__event_code, TimeTool::EventLogic::LogicOp arg__logic_op)
00031     : _Code(((arg__event_code) & 0xff)|(((arg__logic_op) & 0x3)<<8))
00032   {
00033   }
00034   EventLogic() {}
00035   /** Event Code */
00036   uint8_t event_code() const { return uint8_t(this->_Code & 0xff); }
00037   /** Logic Operation */
00038   TimeTool::EventLogic::LogicOp logic_op() const { return LogicOp((this->_Code>>8) & 0x3); }
00039   static uint32_t _sizeof() { return 4; }
00040 private:
00041   uint32_t      _Code;
00042 };
00043 std::ostream& operator<<(std::ostream& str, TimeTool::EventLogic::LogicOp enval);
00044 
00045 /** @class ConfigV1
00046 
00047   
00048 */
00049 
00050 
00051 class ConfigV1 {
00052 public:
00053   enum { TypeId = Pds::TypeId::Id_TimeToolConfig /**< XTC type ID value (from Pds::TypeId class) */ };
00054   enum { Version = 1 /**< XTC type version number */ };
00055   enum Axis {
00056     X = 0,
00057     Y = 1,
00058   };
00059   virtual ~ConfigV1();
00060   /** Time Axis of Image */
00061   virtual TimeTool::ConfigV1::Axis project_axis() const = 0;
00062   /** Record Raw Image into Event */
00063   virtual uint8_t write_image() const = 0;
00064   /** Record Time Axis Projections into Event */
00065   virtual uint8_t write_projections() const = 0;
00066   /** Subtract Sideband Region */
00067   virtual uint8_t subtract_sideband() const = 0;
00068   /** Number of Digital Filter Weights */
00069   virtual uint16_t number_of_weights() const = 0;
00070   /** Pixel to Time Calibration Polynomial Dimension */
00071   virtual uint8_t calib_poly_dim() const = 0;
00072   /** Length of EPICS PV base name */
00073   virtual uint8_t base_name_length() const = 0;
00074   /** Number of Beam Logic Event Codes */
00075   virtual uint16_t number_of_beam_event_codes() const = 0;
00076   /** Number of Laser Logic Event Codes */
00077   virtual uint16_t number_of_laser_event_codes() const = 0;
00078   /** Projection Minimum Value for Validation */
00079   virtual uint32_t signal_cut() const = 0;
00080   /** Signal Region Coordinates Start */
00081   virtual const Camera::FrameCoord& sig_roi_lo() const = 0;
00082   /** Signal Region Coordinates End */
00083   virtual const Camera::FrameCoord& sig_roi_hi() const = 0;
00084   /** Sideband Region Coordinates Start */
00085   virtual const Camera::FrameCoord& sb_roi_lo() const = 0;
00086   /** Sideband Region Coordinates End */
00087   virtual const Camera::FrameCoord& sb_roi_hi() const = 0;
00088   /** Sideband Rolling Average Factor (1/NFrames) */
00089   virtual double sb_convergence() const = 0;
00090   /** Reference Rolling Average Factor (1/NFrames) */
00091   virtual double ref_convergence() const = 0;
00092   /** Beam Logic Event Codes */
00093   virtual ndarray<const TimeTool::EventLogic, 1> beam_logic() const = 0;
00094   /** Laser Logic Event Codes */
00095   virtual ndarray<const TimeTool::EventLogic, 1> laser_logic() const = 0;
00096   /** Digital Filter Weights */
00097   virtual ndarray<const double, 1> weights() const = 0;
00098   /** Pixel to Time Calibration Polynomial */
00099   virtual ndarray<const double, 1> calib_poly() const = 0;
00100   /** EPICS PV base name */
00101   virtual const char* base_name() const = 0;
00102   /** Size of projections */
00103   virtual uint32_t signal_projection_size() const = 0;
00104   virtual uint32_t sideband_projection_size() const = 0;
00105   /** Method which returns the shape (dimensions) of the data returned by base_name() method. */
00106   virtual std::vector<int> base_name_shape() const = 0;
00107 };
00108 std::ostream& operator<<(std::ostream& str, TimeTool::ConfigV1::Axis enval);
00109 
00110 /** @class ConfigV2
00111 
00112   
00113 */
00114 
00115 
00116 class ConfigV2 {
00117 public:
00118   enum { TypeId = Pds::TypeId::Id_TimeToolConfig /**< XTC type ID value (from Pds::TypeId class) */ };
00119   enum { Version = 2 /**< XTC type version number */ };
00120   enum Axis {
00121     X = 0,
00122     Y = 1,
00123   };
00124   virtual ~ConfigV2();
00125   /** Time Axis of Image */
00126   virtual TimeTool::ConfigV2::Axis project_axis() const = 0;
00127   /** Record Raw Image into Event */
00128   virtual uint8_t write_image() const = 0;
00129   /** Record Time Axis Projections into Event */
00130   virtual uint8_t write_projections() const = 0;
00131   /** Subtract Sideband Region */
00132   virtual uint8_t subtract_sideband() const = 0;
00133   /** Use Separate Reference Region */
00134   virtual uint8_t use_reference_roi() const = 0;
00135   /** Number of Digital Filter Weights */
00136   virtual uint16_t number_of_weights() const = 0;
00137   /** Pixel to Time Calibration Polynomial Dimension */
00138   virtual uint8_t calib_poly_dim() const = 0;
00139   /** Length of EPICS PV base name */
00140   virtual uint8_t base_name_length() const = 0;
00141   /** Number of Beam Logic Event Codes */
00142   virtual uint16_t number_of_beam_event_codes() const = 0;
00143   /** Number of Laser Logic Event Codes */
00144   virtual uint16_t number_of_laser_event_codes() const = 0;
00145   /** Projection Minimum Value for Validation */
00146   virtual uint32_t signal_cut() const = 0;
00147   /** Signal Region Coordinates Start */
00148   virtual const Camera::FrameCoord& sig_roi_lo() const = 0;
00149   /** Signal Region Coordinates End */
00150   virtual const Camera::FrameCoord& sig_roi_hi() const = 0;
00151   /** Sideband Region Coordinates Start */
00152   virtual const Camera::FrameCoord& sb_roi_lo() const = 0;
00153   /** Sideband Region Coordinates End */
00154   virtual const Camera::FrameCoord& sb_roi_hi() const = 0;
00155   /** Sideband Rolling Average Factor (1/NFrames) */
00156   virtual double sb_convergence() const = 0;
00157   /** Reference Region Coordinates Start */
00158   virtual const Camera::FrameCoord& ref_roi_lo() const = 0;
00159   /** Sideband Region Coordinates End */
00160   virtual const Camera::FrameCoord& ref_roi_hi() const = 0;
00161   /** Reference Rolling Average Factor (1/NFrames) */
00162   virtual double ref_convergence() const = 0;
00163   /** Beam Logic Event Codes */
00164   virtual ndarray<const TimeTool::EventLogic, 1> beam_logic() const = 0;
00165   /** Laser Logic Event Codes */
00166   virtual ndarray<const TimeTool::EventLogic, 1> laser_logic() const = 0;
00167   /** Digital Filter Weights */
00168   virtual ndarray<const double, 1> weights() const = 0;
00169   /** Pixel to Time Calibration Polynomial */
00170   virtual ndarray<const double, 1> calib_poly() const = 0;
00171   /** EPICS PV base name */
00172   virtual const char* base_name() const = 0;
00173   /** Size of projections */
00174   virtual uint32_t signal_projection_size() const = 0;
00175   virtual uint32_t sideband_projection_size() const = 0;
00176   virtual uint32_t reference_projection_size() const = 0;
00177   /** Method which returns the shape (dimensions) of the data returned by base_name() method. */
00178   virtual std::vector<int> base_name_shape() const = 0;
00179 };
00180 std::ostream& operator<<(std::ostream& str, TimeTool::ConfigV2::Axis enval);
00181 
00182 /** @class DataV1
00183 
00184   
00185 */
00186 
00187 class ConfigV1;
00188 
00189 class DataV1 {
00190 public:
00191   enum { TypeId = Pds::TypeId::Id_TimeToolData /**< XTC type ID value (from Pds::TypeId class) */ };
00192   enum { Version = 1 /**< XTC type version number */ };
00193   enum EventType {
00194     Dark, /**< No Laser */
00195     Reference, /**< No Beam */
00196     Signal, /**< Laser and Beam */
00197   };
00198   virtual ~DataV1();
00199   /** Event designation */
00200   virtual TimeTool::DataV1::EventType event_type() const = 0;
00201   /** Amplitude of the edge */
00202   virtual double amplitude() const = 0;
00203   /** Filtered pixel position of the edge */
00204   virtual double position_pixel() const = 0;
00205   /** Filtered time position of the edge */
00206   virtual double position_time() const = 0;
00207   /** Full-width half maximum of filtered edge (in pixels) */
00208   virtual double position_fwhm() const = 0;
00209   /** Amplitude of reference at the edge */
00210   virtual double ref_amplitude() const = 0;
00211   /** Amplitude of the next largest edge */
00212   virtual double nxt_amplitude() const = 0;
00213   /** Projected signal */
00214   virtual ndarray<const int32_t, 1> projected_signal() const = 0;
00215   /** Projected reference */
00216   virtual ndarray<const int32_t, 1> projected_sideband() const = 0;
00217 };
00218 std::ostream& operator<<(std::ostream& str, TimeTool::DataV1::EventType enval);
00219 
00220 /** @class DataV2
00221 
00222   
00223 */
00224 
00225 class ConfigV2;
00226 
00227 class DataV2 {
00228 public:
00229   enum { TypeId = Pds::TypeId::Id_TimeToolData /**< XTC type ID value (from Pds::TypeId class) */ };
00230   enum { Version = 2 /**< XTC type version number */ };
00231   enum EventType {
00232     Dark, /**< No Laser */
00233     Reference, /**< No Beam */
00234     Signal, /**< Laser and Beam */
00235   };
00236   virtual ~DataV2();
00237   /** Event designation */
00238   virtual TimeTool::DataV2::EventType event_type() const = 0;
00239   /** Amplitude of the edge */
00240   virtual double amplitude() const = 0;
00241   /** Filtered pixel position of the edge */
00242   virtual double position_pixel() const = 0;
00243   /** Filtered time position of the edge */
00244   virtual double position_time() const = 0;
00245   /** Full-width half maximum of filtered edge (in pixels) */
00246   virtual double position_fwhm() const = 0;
00247   /** Amplitude of reference at the edge */
00248   virtual double ref_amplitude() const = 0;
00249   /** Amplitude of the next largest edge */
00250   virtual double nxt_amplitude() const = 0;
00251   /** Projected signal */
00252   virtual ndarray<const int32_t, 1> projected_signal() const = 0;
00253   /** Projected sideband */
00254   virtual ndarray<const int32_t, 1> projected_sideband() const = 0;
00255   /** Projected reference */
00256   virtual ndarray<const int32_t, 1> projected_reference() const = 0;
00257 };
00258 std::ostream& operator<<(std::ostream& str, TimeTool::DataV2::EventType enval);
00259 } // namespace TimeTool
00260 } // namespace Psana
00261 #endif // PSANA_TIMETOOL_DDL_H

Generated on 19 Dec 2016 for PSANAclasses by  doxygen 1.4.7