#include <RawCrateMonitorBlock.h>
Inheritance diagram for RawCrateMonitorBlock:

Public Member Functions | |
| RawCrateMonitorBlock () | |
| RawCrateMonitorBlock (const Int_t *block) | |
| virtual | ~RawCrateMonitorBlock () |
| Int_t | GetRun () const |
| Short_t | GetSubRun () const |
| Short_t | GetRunType () const |
| VldTimeStamp | GetTimeStamp () const |
| VldContext | GetVldContext () const |
| ElecType::Elec_t | GetElecType () const |
| Bool_t | GetPedMode () const |
| Bool_t | GetSparsMode () const |
| Bool_t | GetCommonMode () const |
| UShort_t | GetCrate () const |
| Int_t | GetCrateIdInfo () const |
| Int_t | GetTimeFrameNum () const |
| float | GetRopTempCpuC () const |
| float | GetRopTempMemC () const |
| float | GetRopTempPmcC () const |
| Int_t | GetNumVfbMonitors () const |
| const RawVfbMonitor & | GetVfbMonitor (UInt_t indx) const |
| const RawVfbMonitor & | GetVfbMonitor (RawChannelId rcid) const |
| Int_t | GetNumMasterMonitors () const |
| const RawMasterMonitor & | GetMasterMonitor (UInt_t indx) const |
| const RawMasterMonitor & | GetMasterMonitor (RawChannelId rcid) const |
| virtual std::ostream & | FormatToOStream (ostream &os, Option_t *option="") const |
| RawCrateMonitorBlock (const RawCrateMonitorBlock &rhs) | |
| RawCrateMonitorBlock & | operator= (const RawCrateMonitorBlock &rhs) |
Static Public Member Functions | |
| void | SetDebugFlags (const UInt_t dbgflgs) |
| UInt_t | GetDebugFlags () |
Protected Member Functions | |
| virtual void | FillCrateId () const |
| virtual void | UnpackFeeMonitors () const |
| virtual void | UnpackVfbMonitors () const |
| virtual void | UnpackQieMonitors () const |
| Int_t | GetNumFeeMonitors () const |
Protected Attributes | |
| RawChannelId | fCrateId |
| std::vector< RawVfbMonitor > | fVfbMonitors |
| unpacked crateinfo | |
| std::vector< RawMasterMonitor > | fMasterMonitors |
| unpacked vfb subblk | |
Static Private Attributes | |
| UInt_t | fgDebugFlags = 0 |
| unpacked | |
|
|
Definition at line 54 of file RawCrateMonitorBlock.cxx. 00055 : RawDataBlock(), fCrateId() 00056 { 00057 // Default constructor 00058 }
|
|
|
Definition at line 61 of file RawCrateMonitorBlock.cxx. 00062 : RawDataBlock(block), fCrateId() 00063 { 00064 // stored block format is: 00065 //--------------------- 00066 // 0 # words in block 00067 // 1 checksum 00068 // 2 Block Id 00069 //----- 00070 // 3 run # 00071 // 4 subRunAndType 00072 // 5 timestamp sec 00073 // 6 timestamp nsec 00074 // 7 crateIdentifier 00075 // 8 timeFrameNumber 00076 // 9 ropTempCpuInDegC 00077 // 10 ropTempMemInDegC 00078 // 11 ropTempPmcInDegC 00079 // 12 numFeeMonitorBlocks 00080 // ... some number of sub structures 00081 00082 }
|
|
|
Definition at line 85 of file RawCrateMonitorBlock.cxx. 00086 {
00087 // dtor
00088 }
|
|
|
Definition at line 128 of file RawCrateMonitorBlock.h. References fCrateId. 00129 : RawDataBlock(rhs), fCrateId(rhs.fCrateId) 00130 { ; }
|
|
|
Definition at line 397 of file RawCrateMonitorBlock.cxx. References fCrateId, RawDataBlock::GetBlockId(), GetCrateIdInfo(), DataUtil::GetDetector(), and RawChannelId::IsNull(). Referenced by GetCommonMode(), GetCrate(), GetElecType(), GetPedMode(), and GetSparsMode(). 00398 {
00399 // unpack crate info
00400 if (!fCrateId.IsNull()) return;
00401 fCrateId = RawChannelId(GetBlockId().GetDetector(),GetCrateIdInfo(),0x1fff);
00402 }
|
|
||||||||||||
|
Definition at line 302 of file RawCrateMonitorBlock.cxx. References RawCrateMonitorBlock::RawVfbMonitor::asdSupplyV, ElecType::AsString(), VldTimeStamp::AsString(), RawCrateMonitorBlock::RawMasterMonitor::dynodeThreshold, fgDebugFlags, RawCrateMonitorBlock::RawMasterMonitor::fMinderMonitors, RawDataBlock::FormatToOStream(), GetCrateIdInfo(), GetElecType(), GetMasterMonitor(), RawCrateMonitorBlock::RawMinderMonitor::GetMinderSerialNum(), RawCrateMonitorBlock::RawMinderMonitor::GetMinderSlot(), GetNumMasterMonitors(), GetNumVfbMonitors(), GetRopTempCpuC(), GetRopTempMemC(), GetRopTempPmcC(), GetRun(), GetRunType(), GetSubRun(), GetTimeFrameNum(), GetTimeStamp(), GetVfbMonitor(), RawCrateMonitorBlock::RawVfbMonitor::groundPlaneV, RawCrateMonitorBlock::RawMasterMonitor::masterCtrl, RawCrateMonitorBlock::RawMasterMonitor::masterId, RawCrateMonitorBlock::RawMasterMonitor::masterSlot, RawCrateMonitorBlock::RawMinderMonitor::minderId, RawCrateMonitorBlock::RawVfbMonitor::negativeVaRail0V, RawCrateMonitorBlock::RawVfbMonitor::negativeVaRail1V, RawCrateMonitorBlock::RawVfbMonitor::negativeVaRail2V, option, RawCrateMonitorBlock::RawVfbMonitor::positiveVaRailV, RawCrateMonitorBlock::RawMinderMonitor::sparsThreshold, RawCrateMonitorBlock::RawVfbMonitor::varcId, RawCrateMonitorBlock::RawVfbMonitor::vfbId, and RawCrateMonitorBlock::RawVfbMonitor::vfbTempC. 00304 {
00305 if (fgDebugFlags & kdbg_ForceHexDump) option = "x";
00306
00307 RawDataBlock::FormatToOStream(os,option);
00308 if (option[0] == 'X') return os;
00309
00310 // additional block specific formatted output is done here
00311
00312 os << " TimeStamp " << GetTimeStamp().AsString("c")
00313 << " TimeFrame " << GetTimeFrameNum() << endl;
00314 os << " Run " << GetRun()
00315 << " SubRun " << GetSubRun()
00316 << " RunType " << GetRunType();
00317 int crateid = GetCrateIdInfo();
00318
00319 MsgFormat f8p3("f8.3");
00320 MsgFormat f9p3("f9.3");
00321
00322 os << " Crate " << (crateid&0x3f)
00323 << " (0x" << hex << crateid << dec << ") had: " << endl
00324 << " ROP Temperatures (degC): "
00325 << f8p3(GetRopTempCpuC()) << " (CPU), "
00326 << f8p3(GetRopTempMemC()) << " (mem), "
00327 << f8p3(GetRopTempPmcC()) << " (pmc) " << endl;
00328
00329 ElecType::Elec_t etype = GetElecType();
00330 os << " ElecType: " << ElecType::AsString(etype);
00331 switch(etype) {
00332 case ElecType::kVA:
00333 {
00334 UInt_t nvfb = GetNumVfbMonitors();
00335 os << ", unpacked into " << nvfb << " VfbMonitors " << endl;
00336 os << " varc vfb : grnd asd +rail -rail0 -rail1 -rail2 (V) temp (C)" << endl;
00337 // xx[ii]x -12345 -12345 -12345 -12345 -12345 -12345 1234567
00338 for (UInt_t indxVfb = 0; indxVfb < nvfb; ++indxVfb) {
00339 // print out the info for this VFB
00340 const RawVfbMonitor& vfbmon = GetVfbMonitor(indxVfb);
00341 os << " " << "[" << setw(2) << indxVfb << "] "
00342 << setw(4) << vfbmon.varcId << setw(4) << vfbmon.vfbId
00343 << " :"
00344 << f8p3(vfbmon.groundPlaneV)
00345 << f8p3(vfbmon.asdSupplyV)
00346 << f8p3(vfbmon.positiveVaRailV)
00347 << f8p3(vfbmon.negativeVaRail0V)
00348 << f8p3(vfbmon.negativeVaRail1V)
00349 << f8p3(vfbmon.negativeVaRail2V)
00350 << " "
00351 << f9p3(vfbmon.vfbTempC)
00352 // << " [" << vfbmon.pseudo_rcid.AsString("ec") << "]"
00353 << endl;
00354 }
00355 break;
00356 };
00357 case ElecType::kQIE:
00358 {
00359 UInt_t nmaster = GetNumMasterMonitors();
00360 os << ", unpacked into " << nmaster << " MasterMonitors " << endl;
00361 for (UInt_t indxMaster = 0; indxMaster < nmaster; ++indxMaster) {
00362 // print out the info for this master
00363 const RawMasterMonitor& mastermon = GetMasterMonitor(indxMaster);
00364 os << " " << "[" << setw(2) << indxMaster << "] "
00365 << " masterId " << setw(4) << mastermon.masterId << " "
00366 << " Slot " << setw(2) << mastermon.masterSlot << " "
00367 << " Ctrl " <<setw(2) << mastermon.masterCtrl
00368 << " dynodeThreshold ";
00369 for (int ithr=0; ithr<4; ++ithr)
00370 os << mastermon.dynodeThreshold[ithr] << " ";
00371 os << endl;
00372 // print out the minders read out by this master
00373 UInt_t nminder = mastermon.fMinderMonitors.size();
00374 for (UInt_t indxMinder = 0; indxMinder < nminder; ++indxMinder) {
00375 const RawMinderMonitor& mindermon =
00376 mastermon.fMinderMonitors[indxMinder];
00377 os << " (" << indxMinder << ") "
00378 << " serial# " << setw(4)
00379 << mindermon.GetMinderSerialNum() << " "
00380 << " slot# " << setw(2)
00381 << mindermon.GetMinderSlot() << " "
00382 << " (0x" << hex << mindermon.minderId << dec << ") "
00383 << " sparsThr " << mindermon.sparsThreshold
00384 << endl;
00385 }
00386 }
00387 break;
00388 }
00389 default:
00390 os << " can't be unpacked (yet)." << endl;
00391 }
00392 os << endl;
00393 return os;
00394 }
|
|
|
Definition at line 168 of file RawCrateMonitorBlock.h. References fCrateId, FillCrateId(), and RawChannelId::GetCommonMode(). 00169 { FillCrateId(); return fCrateId.GetCommonMode(); }
|
|
|
Definition at line 171 of file RawCrateMonitorBlock.h. References fCrateId, FillCrateId(), and RawChannelId::GetCrate(). Referenced by RateSummary::Ana(), GetMasterMonitor(), and UnpackVfbMonitors(). 00172 { FillCrateId(); return fCrateId.GetCrate(); }
|
|
|
Definition at line 136 of file RawCrateMonitorBlock.cxx. Referenced by FillCrateId(), and FormatToOStream(). 00137 {
00138 // get the crate id info (packed)
00139 if (fSize > indx_crateid) return fRawBlock[indx_crateid];
00140 return -1;
00141 }
|
|
|
Definition at line 125 of file RawCrateMonitorBlock.h. 00125 { return fgDebugFlags; }
|
|
|
Definition at line 159 of file RawCrateMonitorBlock.h. References fCrateId, FillCrateId(), and RawChannelId::GetElecType(). Referenced by FormatToOStream(), UnpackFeeMonitors(), and UnpackVfbMonitors(). 00160 { FillCrateId(); return fCrateId.GetElecType(); }
|
|
|
Definition at line 258 of file RawCrateMonitorBlock.cxx. References fMasterMonitors, RawDataBlock::GetBlockId(), GetCrate(), RawChannelId::GetCrate(), RawBlockId::GetDetector(), RawChannelId::GetDetector(), RawChannelId::GetElecType(), RawChannelId::GetGeographicAddress(), GetNumMasterMonitors(), RawCrateMonitorBlock::RawMasterMonitor::masterSlot, and MSG. 00259 {
00260 // get the Master Monitor for a given raw channel (ignore chip,chan fields)
00261
00262 if (rcidLookFor.GetElecType() != ElecType::kQIE) {
00263 MSG("Raw",Msg::kWarning)
00264 << "GetMasterMonitor was supplied raw channel of wrong ElecType: "
00265 << rcidLookFor << endl;
00266 return dummyMasterMonitor;
00267 }
00268
00269 if (rcidLookFor.GetDetector() != GetBlockId().GetDetector() ||
00270 rcidLookFor.GetCrate() != GetCrate() ) {
00271 MSG("Raw",Msg::kWarning)
00272 << "GetMasterMonitor was supplied wrong crate: "
00273 << rcidLookFor << endl;
00274 return dummyMasterMonitor;
00275 }
00276
00277 UShort_t geoAddr = rcidLookFor.GetGeographicAddress();
00278
00279 size_t nmasters = GetNumMasterMonitors();
00280 for (size_t indx = 0; indx < nmasters; ++indx) {
00281 const RawMasterMonitor& mastermon = fMasterMonitors[indx];
00282 // compare w/ pseudo (incomplete) RawChannelId
00283 if ( mastermon.masterSlot == geoAddr ) return mastermon;
00284 }
00285
00286 // fell through without finding anything appropriate
00287 MSG("Raw",Msg::kWarning)
00288 << "GetMasterMonitors() can't get find a match for "
00289 << rcidLookFor << endl;
00290 return dummyMasterMonitor;
00291 }
|
|
|
Definition at line 243 of file RawCrateMonitorBlock.cxx. References fMasterMonitors, GetNumMasterMonitors(), and MSG. Referenced by FormatToOStream(). 00244 {
00245 // get the i--th Master Monitor sub-blocks
00246 size_t nmasters = GetNumMasterMonitors();
00247 if (indx >= nmasters) {
00248 MSG("Raw",Msg::kWarning)
00249 << "GetMasterMonitors() can't get index " << indx
00250 << " as there are only " << nmasters << endl;
00251 return dummyMasterMonitor;
00252 }
00253 return fMasterMonitors[indx];
00254 }
|
|
|
Definition at line 176 of file RawCrateMonitorBlock.cxx. Referenced by UnpackQieMonitors(), and UnpackVfbMonitors(). 00177 {
00178 // get the # of FEE Monitor sub-blocks
00179 if (fSize > indx_nfeeblks) return fRawBlock[indx_nfeeblks];
00180 return -1;
00181 }
|
|
|
Definition at line 234 of file RawCrateMonitorBlock.cxx. References fMasterMonitors, and UnpackFeeMonitors(). Referenced by FormatToOStream(), and GetMasterMonitor(). 00235 {
00236 // get the # of Master Monitor sub-blocks
00237 UnpackFeeMonitors();
00238 return fMasterMonitors.size();
00239 }
|
|
|
Definition at line 184 of file RawCrateMonitorBlock.cxx. References fVfbMonitors, and UnpackFeeMonitors(). Referenced by RateSummary::Ana(), FormatToOStream(), and GetVfbMonitor(). 00185 {
00186 // get the # of Vfb Monitor sub-blocks
00187 UnpackFeeMonitors();
00188 return fVfbMonitors.size();
00189 }
|
|
|
Definition at line 162 of file RawCrateMonitorBlock.h. References fCrateId, FillCrateId(), and RawChannelId::GetPedMode(). 00163 { FillCrateId(); return fCrateId.GetPedMode(); }
|
|
|
Definition at line 152 of file RawCrateMonitorBlock.cxx. Referenced by RateSummary::Ana(), and FormatToOStream(). 00153 {
00154 // get the ROP CPU temperature in deg C
00155 if (fSize > indx_roptempcpu) return fRawBlock[indx_roptempcpu];
00156 return -1;
00157 }
|
|
|
Definition at line 160 of file RawCrateMonitorBlock.cxx. Referenced by RateSummary::Ana(), and FormatToOStream(). 00161 {
00162 // get the ROP memory temperature in deg C
00163 if (fSize > indx_roptempmem) return fRawBlock[indx_roptempmem];
00164 return -1;
00165 }
|
|
|
Definition at line 168 of file RawCrateMonitorBlock.cxx. Referenced by RateSummary::Ana(), and FormatToOStream(). 00169 {
00170 // get the ROP "pmc" temperature in deg C
00171 if (fSize > indx_roptemppmc) return fRawBlock[indx_roptemppmc];
00172 return -1;
00173 }
|
|
|
Definition at line 112 of file RawCrateMonitorBlock.cxx. Referenced by FormatToOStream(). 00113 {
00114 // get the run number
00115 if (fSize > indx_run) return fRawBlock[indx_run];
00116 return -1;
00117 }
|
|
|
Definition at line 128 of file RawCrateMonitorBlock.cxx. Referenced by FormatToOStream(). 00129 {
00130 // get the run type
00131 if (fSize > indx_runtype) return fRawBlock[indx_runtype]&0xffff;
00132 return -1;
00133 }
|
|
|
Definition at line 165 of file RawCrateMonitorBlock.h. References fCrateId, FillCrateId(), and RawChannelId::GetSparsMode(). 00166 { FillCrateId(); return fCrateId.GetSparsMode(); }
|
|
|
Definition at line 120 of file RawCrateMonitorBlock.cxx. Referenced by FormatToOStream(). 00121 {
00122 // get the subrun number
00123 if (fSize > indx_subrun) return (fRawBlock[indx_subrun]>>16)&0xffff;
00124 return -1;
00125 }
|
|
|
Definition at line 144 of file RawCrateMonitorBlock.cxx. Referenced by FormatToOStream(). 00145 {
00146 // get the time frame
00147 if (fSize > indx_tf) return fRawBlock[indx_tf];
00148 return -1;
00149 }
|
|
|
Definition at line 102 of file RawCrateMonitorBlock.cxx. References indx_nsec, and indx_sec. Referenced by FormatToOStream(), and GetVldContext(). 00103 {
00104 // get the timestamp
00105 if (fSize > indx_nsec)
00106 return VldTimeStamp(fRawBlock[indx_sec],fRawBlock[indx_nsec]);
00107
00108 return VldTimeStamp((time_t)0,(Int_t)0);
00109 }
|
|
|
Definition at line 208 of file RawCrateMonitorBlock.cxx. References fVfbMonitors, RawChannelId::GetElecType(), GetNumVfbMonitors(), RawChannelId::IsSameVfb(), MSG, and RawCrateMonitorBlock::RawVfbMonitor::pseudo_rcid. 00209 {
00210 // get the Vfb Monitor for a given raw channel (ignore chip,chan fields)
00211
00212 if (rcidLookFor.GetElecType() != ElecType::kVA) {
00213 MSG("Raw",Msg::kWarning)
00214 << "GetVfbMonitor was supplied raw channel of wrong ElecType: "
00215 << rcidLookFor << endl;
00216 return dummyVfbMonitor;
00217 }
00218
00219 size_t nvfbs = GetNumVfbMonitors();
00220 for (size_t indx = 0; indx < nvfbs; ++indx) {
00221 const RawVfbMonitor& vfbmon = fVfbMonitors[indx];
00222 // compare w/ pseudo (incomplete) RawChannelId
00223 if (rcidLookFor.IsSameVfb(vfbmon.pseudo_rcid)) return vfbmon;
00224 }
00225
00226 // fell through without finding anything appropriate
00227 MSG("Raw",Msg::kWarning)
00228 << "GetVfbMonitors() can't get find a match for "
00229 << rcidLookFor << endl;
00230 return dummyVfbMonitor;
00231 }
|
|
|
Definition at line 193 of file RawCrateMonitorBlock.cxx. References fVfbMonitors, GetNumVfbMonitors(), and MSG. Referenced by RateSummary::Ana(), and FormatToOStream(). 00194 {
00195 // get the i--th Vfb Monitor sub-blocks
00196 size_t nvfbs = GetNumVfbMonitors();
00197 if (indx >= nvfbs) {
00198 MSG("Raw",Msg::kWarning)
00199 << "GetVfbMonitors() can't get index " << indx
00200 << " as there are only " << nvfbs << endl;
00201 return dummyVfbMonitor;
00202 }
00203 return fVfbMonitors[indx];
00204 }
|
|
|
Definition at line 294 of file RawCrateMonitorBlock.cxx. References RawDataBlock::GetBlockId(), RawBlockId::GetDetector(), RawBlockId::GetSimFlag(), and GetTimeStamp(). 00295 {
00296 // build validity context
00297 RawBlockId rbid = GetBlockId();
00298 return VldContext(rbid.GetDetector(),rbid.GetSimFlag(),GetTimeStamp());
00299 }
|
|
|
Definition at line 91 of file RawCrateMonitorBlock.cxx. References fCrateId, and RawDataBlock::operator=(). 00092 {
00093 // deep copy assignment
00094 if (this != &rhs) {
00095 RawDataBlock::operator=(rhs);
00096 fCrateId = rhs.fCrateId;
00097 }
00098 return *this;
00099 }
|
|
|
Definition at line 124 of file RawCrateMonitorBlock.h. References fgDebugFlags. 00124 {fgDebugFlags=dbgflgs;}
|
|
|
Definition at line 405 of file RawCrateMonitorBlock.cxx. References ElecType::AsString(), fMasterMonitors, fVfbMonitors, GetElecType(), MSG, UnpackQieMonitors(), and UnpackVfbMonitors(). Referenced by GetNumMasterMonitors(), and GetNumVfbMonitors(). 00406 {
00407 // unpack individual monitor sub-blocks
00408 if (!fVfbMonitors.empty() || !fMasterMonitors.empty()) return;
00409
00410 switch (GetElecType()) {
00411 case ElecType::kVA: UnpackVfbMonitors(); break;
00412 case ElecType::kQIE: UnpackQieMonitors(); break;
00413 default:
00414 MSG("Raw",Msg::kWarning)
00415 << "Unpacking of data for "
00416 << ElecType::AsString(GetElecType())
00417 << " crates not yet supported" << endl;
00418 }
00419
00420 }
|
|
|
Definition at line 483 of file RawCrateMonitorBlock.cxx. References RawCrateMonitorBlock::RawMasterMonitor::dynodeThreshold, fMasterMonitors, RawCrateMonitorBlock::RawMasterMonitor::fMinderMonitors, GetNumFeeMonitors(), indx_nfeeblks, RawCrateMonitorBlock::RawMasterMonitor::masterCtrl, RawCrateMonitorBlock::RawMasterMonitor::masterId, RawCrateMonitorBlock::RawMasterMonitor::masterSlot, RawCrateMonitorBlock::RawMinderMonitor::minderId, MSG, and RawCrateMonitorBlock::RawMinderMonitor::sparsThreshold. Referenced by UnpackFeeMonitors(). 00484 {
00485 // unpack individual Master/Minder monitor sub-blocks
00486
00487 Int_t *master_start, *minder_start;
00488 Int_t *toofar = fRawBlock + fSize;
00489 Int_t nmasters = GetNumFeeMonitors();
00490 Int_t imaster = 0;
00491
00492 const size_t sizeMasterSubBlk = 8;
00493 const size_t sizeMinderSubBlk = 2;
00494
00495 master_start = fRawBlock + indx_nfeeblks + 1;
00496
00497 //Detector::Detector_t det = GetBlockId().GetDetector();
00498 //ElecType::Elec_t etype = GetElecType();
00499 //UShort_t crate = GetCrate();
00500
00501 while (master_start < toofar) {
00502 RawMasterMonitor mastermon;
00503 mastermon.masterId = master_start[0];
00504 mastermon.masterSlot = master_start[1];
00505 mastermon.masterCtrl = master_start[2];
00506 mastermon.dynodeThreshold[0] = master_start[3];
00507 mastermon.dynodeThreshold[1] = master_start[4];
00508 mastermon.dynodeThreshold[2] = master_start[5];
00509 mastermon.dynodeThreshold[3] = master_start[6];
00510 unsigned long numMinders = master_start[7];
00511 minder_start = master_start + sizeMasterSubBlk;
00512 for (unsigned long currMinder = 0; currMinder < numMinders; ++currMinder) {
00513 RawMinderMonitor mindermon;
00514 mindermon.minderId = minder_start[0];
00515 mindermon.sparsThreshold = minder_start[1];
00516 mastermon.fMinderMonitors.push_back(mindermon);
00517 minder_start += sizeMinderSubBlk;
00518 }
00519 ++imaster;
00520 fMasterMonitors.push_back(mastermon);
00521 master_start = minder_start;
00522 }
00523
00524 if (imaster != nmasters || master_start != toofar)
00525 MSG("Raw",Msg::kWarning)
00526 << "Unpacking reached end in an inconsistent manner"
00527 << " ptr @ " << master_start << " should be " << toofar
00528 << " saw " << imaster << " of " << nmasters
00529 << " fee (Master) sub-blocks " << endl;
00530 }
|
|
|
Definition at line 423 of file RawCrateMonitorBlock.cxx. References RawCrateMonitorBlock::RawVfbMonitor::asdSupplyV, det, fVfbMonitors, RawDataBlock::GetBlockId(), GetCrate(), RawBlockId::GetDetector(), GetElecType(), GetNumFeeMonitors(), RawCrateMonitorBlock::RawVfbMonitor::groundPlaneV, indx_nfeeblks, MSG, RawCrateMonitorBlock::RawVfbMonitor::negativeVaRail0V, RawCrateMonitorBlock::RawVfbMonitor::negativeVaRail1V, RawCrateMonitorBlock::RawVfbMonitor::negativeVaRail2V, RawCrateMonitorBlock::RawVfbMonitor::positiveVaRailV, RawCrateMonitorBlock::RawVfbMonitor::pseudo_rcid, RawCrateMonitorBlock::RawVfbMonitor::varcId, RawCrateMonitorBlock::RawVfbMonitor::vfbId, and RawCrateMonitorBlock::RawVfbMonitor::vfbTempC. Referenced by UnpackFeeMonitors(). 00424 {
00425 // unpack individual VFB monitor sub-blocks
00426
00427 Int_t *varc_start, *vfb_start;
00428 Int_t *toofar = fRawBlock + fSize;
00429 Int_t nvarc = GetNumFeeMonitors();
00430 Int_t ivarc = 0;
00431
00432 const size_t sizeVarcSubBlk = 2;
00433 const size_t sizeVfbSubBlk = 8;
00434
00435 varc_start = fRawBlock + indx_nfeeblks + 1;
00436
00437 Detector::Detector_t det = GetBlockId().GetDetector();
00438 ElecType::Elec_t etype = GetElecType();
00439 UShort_t crate = GetCrate();
00440
00441 while (varc_start < toofar) {
00442 unsigned long varcId, numVfbs;
00443 varcId = varc_start[0];
00444 numVfbs = varc_start[1];
00445 vfb_start = varc_start + sizeVarcSubBlk;
00446 for (unsigned long currVfb = 0; currVfb < numVfbs; ++currVfb) {
00447 RawVfbMonitor vfbmon;
00448
00449 vfbmon.varcId = varcId;
00450 vfbmon.vfbId = vfb_start[0];
00451 const float mVtoV = 0.001;
00452 const float mCtoC = 0.001;
00453 vfbmon.groundPlaneV = vfb_start[1] * mVtoV;
00454 vfbmon.asdSupplyV = vfb_start[2] * mVtoV;
00455 vfbmon.positiveVaRailV = vfb_start[3] * mVtoV;
00456 vfbmon.negativeVaRail0V = vfb_start[4] * mVtoV;
00457 vfbmon.negativeVaRail1V = vfb_start[5] * mVtoV;
00458 vfbmon.negativeVaRail2V = vfb_start[6] * mVtoV;
00459 vfbmon.vfbTempC = vfb_start[7] * mCtoC;
00460 UInt_t vmm = vfbmon.vfbId >> 1;
00461 UInt_t adcsel = vfbmon.vfbId & 1;
00462 const UInt_t vachip = 0;
00463 const UInt_t vachan = 0;
00464 vfbmon.pseudo_rcid =
00465 RawChannelId(det,etype,crate,varcId,vmm,adcsel,vachip,vachan);
00466
00467 fVfbMonitors.push_back(vfbmon);
00468 vfb_start += sizeVfbSubBlk;
00469 }
00470 ++ivarc;
00471 varc_start = vfb_start;
00472 }
00473
00474 if (ivarc != nvarc || varc_start != toofar)
00475 MSG("Raw",Msg::kWarning)
00476 << "Unpacking reached end in an inconsistent manner"
00477 << " ptr @ " << varc_start << " should be " << toofar
00478 << " saw " << ivarc << " of " << nvarc
00479 << " fee (Varc) sub-blocks " << endl;
00480 }
|
|
|
Definition at line 147 of file RawCrateMonitorBlock.h. Referenced by FillCrateId(), GetCommonMode(), GetCrate(), GetElecType(), GetPedMode(), GetSparsMode(), operator=(), and RawCrateMonitorBlock(). |
|
|
unpacked
Definition at line 18 of file RawCrateMonitorBlock.cxx. Referenced by FormatToOStream(), and SetDebugFlags(). |
|
|
unpacked vfb subblk
Definition at line 149 of file RawCrateMonitorBlock.h. Referenced by GetMasterMonitor(), GetNumMasterMonitors(), UnpackFeeMonitors(), and UnpackQieMonitors(). |
|
|
unpacked crateinfo
Definition at line 148 of file RawCrateMonitorBlock.h. Referenced by GetNumVfbMonitors(), GetVfbMonitor(), UnpackFeeMonitors(), and UnpackVfbMonitors(). |
1.3.9.1