test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
PixelDACSettings.h
Go to the documentation of this file.
1 #ifndef PixelDACSettings_h
2 #define PixelDACSettings_h
3 
10 //
11 // This class provide a base class for the
12 // pixel ROC dac data for the pixel FEC configuration
13 // This is a pure interface (abstract class) that
14 // needs to have an implementation.
15 //
16 //
17 //
18 
19 #include <vector>
20 #include <string>
27 
28 
29 namespace pos{
62 
63  public:
64 
66  //Added by Umesh
67  PixelDACSettings(std::vector<std::vector<std::string> >& tableMat);
68  // modified by MR on 10-01-2008 14:47:47
70  // modified by MR on 24-01-2008 14:28:14
71  void addROC(PixelROCDACSettings &rocname);
72 
73  PixelROCDACSettings getDACSettings(int ROCId) const;
75 
76  unsigned int numROCs() {return dacsettings_.size();}
77 
78  //Generate the DAC settings
80  PixelNameTranslation* trans, PixelDetectorConfig* detconfig, bool HVon=true) const;
81  void setVcthrDisable(PixelFECConfigInterface* pixelFEC, PixelNameTranslation* trans) const;
82  void setVcthrEnable(PixelFECConfigInterface* pixelFEC, PixelNameTranslation* trans, PixelDetectorConfig* detconfig) const;
83 
84  void writeBinary(std::string filename) const;
85 
86  void writeASCII(std::string dir) const;
88  virtual void writeXMLHeader( pos::PixelConfigKey key,
89  int version,
91  std::ofstream *out,
92  std::ofstream *out1 = NULL,
93  std::ofstream *out2 = NULL
94  ) const ;
95  virtual void writeXML( std::ofstream *out,
96  std::ofstream *out1 = NULL ,
97  std::ofstream *out2 = NULL ) const ;
98  virtual void writeXMLTrailer( std::ofstream *out,
99  std::ofstream *out1 = NULL,
100  std::ofstream *out2 = NULL
101  ) const ;
102 
103  friend std::ostream& operator<<(std::ostream& s, const PixelDACSettings& mask);
104 
105  private:
106 
107  std::vector<PixelROCDACSettings> dacsettings_;
108 
109  bool rocIsDisabled(const PixelDetectorConfig* detconfig, const PixelROCName rocname) const;
110 
111  };
112 }
113 
114 /* @} */
115 #endif
PixelROCDACSettings getDACSettings(int ROCId) const
This class specifies which detector components are used in the configuration (and eventually should s...
void addROC(PixelROCDACSettings &rocname)
This file contains the base class for &quot;pixel configuration data&quot; management.
bool rocIsDisabled(const PixelDetectorConfig *detconfig, const PixelROCName rocname) const
unsigned int numROCs()
#define NULL
Definition: scimark2.h:8
This class provides a translation from the naming documents standard to specify the ROC to the corres...
This class provide the data structure for the ROC DAC parameters.
void writeBinary(std::string filename) const
This class is responsible for manipulating the DACsettings of a ROC.
This file contains the base class for &quot;pixel configuration data&quot; management.
This class intends to define an abstract interface for the commands to talk to the PixelFEC...
void writeASCII(std::string dir) const
This is the documentation about PixelDetectorConfig...
virtual void writeXMLHeader(pos::PixelConfigKey key, int version, std::string path, std::ofstream *out, std::ofstream *out1=NULL, std::ofstream *out2=NULL) const
std::vector< PixelROCDACSettings > dacsettings_
friend std::ostream & operator<<(std::ostream &s, const PixelDACSettings &mask)
string key
FastSim: produces sample of signal events, overlayed with premixed minbias events.
PixelDACSettings(std::string filename)
This class implements..
void writeXML(pos::PixelConfigKey key, int version, std::string path) const
This is the documentation about PixelNameTranslation...
This class implements..
Definition: PixelROCName.h:23
tuple filename
Definition: lut2db_cfg.py:20
void generateConfiguration(PixelFECConfigInterface *pixelFEC, PixelNameTranslation *trans, PixelDetectorConfig *detconfig, bool HVon=true) const
This class implements..
void setVcthrDisable(PixelFECConfigInterface *pixelFEC, PixelNameTranslation *trans) const
dbl *** dir
Definition: mlp_gen.cc:35
void setVcthrEnable(PixelFECConfigInterface *pixelFEC, PixelNameTranslation *trans, PixelDetectorConfig *detconfig) const
virtual void writeXMLTrailer(std::ofstream *out, std::ofstream *out1=NULL, std::ofstream *out2=NULL) const
This class stores the name and related hardware mappings for a ROC.