CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
SiStripEventSummary.h
Go to the documentation of this file.
1 
2 #ifndef DataFormats_SiStripEventSummary_SiStripEventSummary_H
3 #define DataFormats_SiStripEventSummary_SiStripEventSummary_H
4 
6 #include <sstream>
7 #include <vector>
8 
10 
12 std::ostream& operator<<(std::ostream&, const SiStripEventSummary&);
13 
23 public:
24  // ---------- Constructors, destructors ----------
25 
28 
31 
32  // ---------- General information ----------
33 
36  inline bool valid() const;
37 
39  inline uint16_t triggerFed() const;
40 
42  inline bool isSet() const;
43 
44  // ---------- Run and event-related info ----------
45 
47  inline const sistrip::RunType& runType() const;
48 
50  inline const uint32_t& event() const;
51 
53  inline const uint32_t& bx() const;
54 
55  // ---------- Hardware-related info ----------
56 
58  inline const sistrip::FedReadoutMode& fedReadoutMode() const;
59 
61  inline const sistrip::ApvReadoutMode& apvReadoutMode() const;
62 
64  inline const uint16_t& apveAddress() const;
65 
67  inline const uint32_t& nApvsInSync() const;
68 
70  inline const uint32_t& nApvsOutOfSync() const;
71 
73  inline const uint32_t& nApvsErrors() const;
74 
75  // ---------- Commissioning info ----------
76 
78  inline bool nullParams() const;
79 
81  inline const std::vector<uint32_t>& params() const;
82 
84  inline const uint32_t& binNumber() const;
85 
87  inline const uint32_t& pllCoarse() const;
88 
90  inline const uint32_t& pllFine() const;
91 
93  inline const uint32_t& latency() const;
94 
96  inline const uint32_t& calChan() const;
97 
99  inline const uint32_t& calSel() const;
100 
102  inline const uint32_t& isha() const;
103 
105  inline const uint32_t& vfs() const;
106 
108  inline const uint32_t& ttcrx() const;
109 
111  inline const uint32_t& vpsp() const;
112 
114  inline const uint32_t& vpspCcuChan() const;
115 
117  inline const uint32_t& lldGain() const;
118 
120  inline const uint32_t& lldBias() const;
121 
123  inline const uint32_t& deviceId() const;
124 
126  inline const uint32_t& processId() const;
127 
129  inline const uint32_t& processIp() const;
130 
132  inline const uint32_t& dcuId() const;
133 
135  inline const uint32_t& layerScanned() const;
136 
137  // ---------- Setter methods ----------
138 
140  void commissioningInfo(const uint32_t* const buffer, const uint32_t& event);
141 
143  void commissioningInfo(const uint32_t& daq_register1, const uint32_t& daq_register2);
144 
146  inline void triggerFed(const int16_t&);
147 
149  void fedReadoutMode(const uint16_t&);
150 
152  inline void event(const uint32_t&);
153 
155  inline void bx(const uint32_t&);
156 
157  inline void apveAddress(uint16_t& addr);
158  inline void nApvsInSync(uint32_t& napvs_in_sync);
159  inline void nApvsOutOfSync(uint32_t& napvs_out_of_sync);
160  inline void nApvsErrors(uint32_t& napvs_with_errors);
161 
162 private:
163  // ---------- General info ----------
164 
166  bool valid_;
167 
169  uint16_t triggerFed_;
170 
171  // ---------- Run- and event-related info ----------
172 
175 
177  uint32_t event_;
178 
180  uint32_t bx_;
181 
183  uint32_t spillNumber_;
184 
186  uint32_t nDataSenders_;
187 
188  // ---------- Hardware-related info ----------
189 
192 
195 
197  uint16_t apveAddress_;
198 
200  uint32_t nApvsInSync_;
201 
203  uint32_t nApvsOutOfSync_;
204 
206  uint32_t nApvsErrors_;
207 
209  std::vector<uint32_t> params_;
210 };
211 
212 // ---------- inline methods ----------
213 
214 bool SiStripEventSummary::valid() const { return valid_; }
215 uint16_t SiStripEventSummary::triggerFed() const { return triggerFed_; }
216 bool SiStripEventSummary::isSet() const { return (/* triggerFed_ > 0 && */ runType_ != sistrip::UNDEFINED_RUN_TYPE); }
217 
219 const uint32_t& SiStripEventSummary::event() const { return event_; }
220 const uint32_t& SiStripEventSummary::bx() const { return bx_; }
221 
224 
225 const uint16_t& SiStripEventSummary::apveAddress() const { return apveAddress_; }
226 const uint32_t& SiStripEventSummary::nApvsInSync() const { return nApvsInSync_; }
227 const uint32_t& SiStripEventSummary::nApvsOutOfSync() const { return nApvsOutOfSync_; }
228 const uint32_t& SiStripEventSummary::nApvsErrors() const { return nApvsErrors_; }
229 
230 bool SiStripEventSummary::nullParams() const { return (!params_[0] && !params_[1] && !params_[2] && !params_[3]); }
231 const std::vector<uint32_t>& SiStripEventSummary::params() const { return params_; }
232 const uint32_t& SiStripEventSummary::binNumber() const { return params_[0]; }
233 const uint32_t& SiStripEventSummary::pllCoarse() const { return params_[0]; }
234 const uint32_t& SiStripEventSummary::pllFine() const { return params_[1]; }
235 const uint32_t& SiStripEventSummary::latency() const { return params_[0]; }
236 const uint32_t& SiStripEventSummary::calChan() const { return params_[1]; }
237 const uint32_t& SiStripEventSummary::calSel() const { return params_[2]; }
238 const uint32_t& SiStripEventSummary::isha() const { return params_[3]; }
239 const uint32_t& SiStripEventSummary::vfs() const { return params_[4]; }
240 const uint32_t& SiStripEventSummary::ttcrx() const { return params_[2]; }
241 const uint32_t& SiStripEventSummary::vpsp() const { return params_[0]; }
242 const uint32_t& SiStripEventSummary::vpspCcuChan() const { return params_[1]; }
243 const uint32_t& SiStripEventSummary::lldGain() const { return params_[0]; }
244 const uint32_t& SiStripEventSummary::lldBias() const { return params_[1]; }
245 const uint32_t& SiStripEventSummary::deviceId() const { return params_[0]; }
246 const uint32_t& SiStripEventSummary::processId() const { return params_[1]; }
247 const uint32_t& SiStripEventSummary::processIp() const { return params_[2]; }
248 const uint32_t& SiStripEventSummary::dcuId() const { return params_[3]; }
249 const uint32_t& SiStripEventSummary::layerScanned() const { return params_[3]; }
250 
251 void SiStripEventSummary::triggerFed(const int16_t& fed) { fed < 0 ? triggerFed_ = 0 : triggerFed_ = fed; }
252 void SiStripEventSummary::event(const uint32_t& event) { event_ = event; }
253 void SiStripEventSummary::bx(const uint32_t& bx) { bx_ = bx; }
254 
256 void SiStripEventSummary::nApvsInSync(uint32_t& napvs_in_sync) { nApvsInSync_ = napvs_in_sync; }
257 void SiStripEventSummary::nApvsOutOfSync(uint32_t& napvs_out_of_sync) { nApvsOutOfSync_ = napvs_out_of_sync; }
258 void SiStripEventSummary::nApvsErrors(uint32_t& napvs_with_errors) { nApvsErrors_ = napvs_with_errors; }
259 
260 #endif // DataFormats_SiStripEventSummary_SiStripEventSummary_H
sistrip::FedReadoutMode fedReadoutMode_
const uint32_t & vfs() const
const uint32_t & nApvsOutOfSync() const
const uint32_t & latency() const
const uint32_t & layerScanned() const
const uint32_t & pllCoarse() const
std::ostream & operator<<(std::ostream &out, const ALILine &li)
Definition: ALILine.cc:167
const uint32_t & lldGain() const
const uint32_t & binNumber() const
const uint32_t & pllFine() const
const uint32_t & lldBias() const
const uint32_t & isha() const
const std::vector< uint32_t > & params() const
const sistrip::RunType & runType() const
const uint32_t & bx() const
sistrip::RunType runType_
const uint16_t & apveAddress() const
void commissioningInfo(const uint32_t *const buffer, const uint32_t &event)
const uint32_t & event() const
const uint32_t & nApvsErrors() const
const uint32_t & dcuId() const
const uint32_t & nApvsInSync() const
const uint32_t & processId() const
const uint32_t & deviceId() const
const uint32_t & calSel() const
sistrip::ApvReadoutMode apvReadoutMode_
const uint32_t & vpspCcuChan() const
uint16_t triggerFed() const
const sistrip::FedReadoutMode & fedReadoutMode() const
const uint32_t & calChan() const
const sistrip::ApvReadoutMode & apvReadoutMode() const
const uint32_t & ttcrx() const
const uint32_t & vpsp() const
std::vector< uint32_t > params_
const uint32_t & processIp() const