File indexing completed on 2024-04-06 11:56:29
0001
0002
0003
0004
0005
0006
0007
0008
0009 #include "Alignment/LaserDQM/plugins/LaserDQM.h"
0010 #include "FWCore/Framework/interface/Event.h"
0011 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0012
0013 #include "DataFormats/Common/interface/Handle.h"
0014 #include "FWCore/Framework/interface/ESHandle.h"
0015 #include "FWCore/Framework/interface/EventSetup.h"
0016
0017 #include "DataFormats/DetId/interface/DetId.h"
0018 #include "Geometry/Records/interface/TrackerDigiGeometryRecord.h"
0019 #include "Geometry/TrackerGeometryBuilder/interface/StripGeomDetUnit.h"
0020 #include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h"
0021
0022 #include "DataFormats/SiStripDetId/interface/StripSubdetector.h"
0023 #include "DataFormats/TrackerCommon/interface/TrackerTopology.h"
0024 #include "Geometry/Records/interface/TrackerTopologyRcd.h"
0025
0026 void LaserDQM::trackerStatistics(edm::Event const &theEvent, edm::EventSetup const &theSetup) {
0027
0028 const TrackerTopology *const tTopo = &theSetup.getData(tTopoToken);
0029
0030
0031 const TrackerGeometry &theTracker = theSetup.getData(tGeoToken);
0032
0033
0034
0035 edm::Handle<edm::DetSetVector<SiStripDigi>> theStripDigis;
0036
0037 for (Parameters::iterator itDigiProducersList = theDigiProducersList.begin();
0038 itDigiProducersList != theDigiProducersList.end();
0039 ++itDigiProducersList) {
0040 std::string digiProducer = itDigiProducersList->getParameter<std::string>("DigiProducer");
0041 std::string digiLabel = itDigiProducersList->getParameter<std::string>("DigiLabel");
0042
0043 theEvent.getByLabel(digiProducer, digiLabel, theStripDigis);
0044
0045
0046
0047 for (edm::DetSetVector<SiStripDigi>::const_iterator DSViter = theStripDigis->begin();
0048 DSViter != theStripDigis->end();
0049 DSViter++) {
0050 DetId theDetUnitID(DSViter->id);
0051
0052
0053 const StripGeomDetUnit *const theStripDet =
0054 dynamic_cast<const StripGeomDetUnit *>(theTracker.idToDet(theDetUnitID));
0055
0056
0057 edm::DetSet<SiStripDigi>::const_iterator theDigiRangeIterator = (*DSViter).data.begin();
0058 edm::DetSet<SiStripDigi>::const_iterator theDigiRangeIteratorEnd = (*DSViter).data.end();
0059
0060
0061 int theBeam = 0;
0062 int theRing = 0;
0063 std::string thePart = "";
0064 int theTIBLayer = 0;
0065 int theTOBLayer = 0;
0066 int theTECWheel = 0;
0067 int theTOBStereoDet = 0;
0068
0069 switch (theDetUnitID.subdetId()) {
0070 case StripSubdetector::TIB: {
0071 thePart = "TIB";
0072 theTIBLayer = tTopo->tibLayer(theDetUnitID.rawId());
0073 break;
0074 }
0075 case StripSubdetector::TOB: {
0076 thePart = "TOB";
0077 theTOBLayer = tTopo->tobLayer(theDetUnitID.rawId());
0078 theTOBStereoDet = tTopo->tobStereo(theDetUnitID.rawId());
0079 break;
0080 }
0081 case StripSubdetector::TEC: {
0082
0083 if (tTopo->tecSide(theDetUnitID.rawId()) == 1) {
0084 thePart = "TEC-";
0085 } else if (tTopo->tecSide(theDetUnitID.rawId()) == 2) {
0086 thePart = "TEC+";
0087 }
0088
0089
0090 if (theStripDet->surface().position().perp() > 55.0 && theStripDet->surface().position().perp() < 59.0) {
0091 theRing = 4;
0092 }
0093 else if (theStripDet->surface().position().perp() > 81.0 && theStripDet->surface().position().perp() < 85.0) {
0094 theRing = 6;
0095 }
0096 else {
0097 theRing = -1;
0098 }
0099
0100
0101 theTECWheel = tTopo->tecWheel(theDetUnitID.rawId());
0102 break;
0103 }
0104 }
0105
0106
0107 if (thePart == "TIB" && theTIBLayer == 4) {
0108 if ((theStripDet->surface().position().phi() > 0.39 - theSearchPhiTIB) &&
0109 (theStripDet->surface().position().phi() < 0.39 + theSearchPhiTIB)) {
0110 theBeam = 0;
0111 }
0112
0113 else if ((theStripDet->surface().position().phi() > 1.29 - theSearchPhiTIB) &&
0114 (theStripDet->surface().position().phi() < 1.29 + theSearchPhiTIB)) {
0115 theBeam = 1;
0116 }
0117
0118 else if ((theStripDet->surface().position().phi() > 1.85 - theSearchPhiTIB) &&
0119 (theStripDet->surface().position().phi() < 1.85 + theSearchPhiTIB)) {
0120 theBeam = 2;
0121 }
0122
0123 else if ((theStripDet->surface().position().phi() > 2.75 - theSearchPhiTIB) &&
0124 (theStripDet->surface().position().phi() < 2.75 + theSearchPhiTIB)) {
0125 theBeam = 3;
0126 }
0127
0128 else if ((theStripDet->surface().position().phi() > -2.59 - theSearchPhiTIB) &&
0129 (theStripDet->surface().position().phi() < -2.59 + theSearchPhiTIB)) {
0130 theBeam = 4;
0131 }
0132
0133 else if ((theStripDet->surface().position().phi() > -2.00 - theSearchPhiTIB) &&
0134 (theStripDet->surface().position().phi() < -2.00 + theSearchPhiTIB)) {
0135 theBeam = 5;
0136 }
0137
0138 else if ((theStripDet->surface().position().phi() > -1.10 - theSearchPhiTIB) &&
0139 (theStripDet->surface().position().phi() < -1.10 + theSearchPhiTIB)) {
0140 theBeam = 6;
0141 }
0142
0143 else if ((theStripDet->surface().position().phi() > -0.50 - theSearchPhiTIB) &&
0144 (theStripDet->surface().position().phi() < -0.50 + theSearchPhiTIB)) {
0145 theBeam = 7;
0146 }
0147 else {
0148 theBeam = -1;
0149 }
0150 } else if (thePart == "TOB" && theTOBLayer == 1) {
0151 if ((theStripDet->surface().position().phi() > 0.39 - theSearchPhiTOB) &&
0152 (theStripDet->surface().position().phi() < 0.39 + theSearchPhiTOB)) {
0153 theBeam = 0;
0154 }
0155
0156 else if ((theStripDet->surface().position().phi() > 1.29 - theSearchPhiTOB) &&
0157 (theStripDet->surface().position().phi() < 1.29 + theSearchPhiTOB)) {
0158 theBeam = 1;
0159 }
0160
0161 else if ((theStripDet->surface().position().phi() > 1.85 - theSearchPhiTOB) &&
0162 (theStripDet->surface().position().phi() < 1.85 + theSearchPhiTOB)) {
0163 theBeam = 2;
0164 }
0165
0166 else if ((theStripDet->surface().position().phi() > 2.75 - theSearchPhiTOB) &&
0167 (theStripDet->surface().position().phi() < 2.75 + theSearchPhiTOB)) {
0168 theBeam = 3;
0169 }
0170
0171 else if ((theStripDet->surface().position().phi() > -2.59 - theSearchPhiTOB) &&
0172 (theStripDet->surface().position().phi() < -2.59 + theSearchPhiTOB)) {
0173 theBeam = 4;
0174 }
0175
0176 else if ((theStripDet->surface().position().phi() > -2.00 - theSearchPhiTOB) &&
0177 (theStripDet->surface().position().phi() < -2.00 + theSearchPhiTOB)) {
0178 theBeam = 5;
0179 }
0180
0181 else if ((theStripDet->surface().position().phi() > -1.10 - theSearchPhiTOB) &&
0182 (theStripDet->surface().position().phi() < -1.10 + theSearchPhiTOB)) {
0183 theBeam = 6;
0184 }
0185
0186 else if ((theStripDet->surface().position().phi() > -0.50 - theSearchPhiTOB) &&
0187 (theStripDet->surface().position().phi() < -0.50 + theSearchPhiTOB)) {
0188 theBeam = 7;
0189 }
0190 else {
0191 theBeam = -1;
0192 }
0193 } else if (thePart == "TEC+" || thePart == "TEC-") {
0194 if ((theStripDet->surface().position().phi() > 0.39 - theSearchPhiTEC) &&
0195 (theStripDet->surface().position().phi() < 0.39 + theSearchPhiTEC)) {
0196 theBeam = 0;
0197 }
0198
0199 else if ((theStripDet->surface().position().phi() > 1.18 - theSearchPhiTEC) &&
0200 (theStripDet->surface().position().phi() < 1.18 + theSearchPhiTEC)) {
0201 theBeam = 1;
0202 }
0203
0204 else if ((theStripDet->surface().position().phi() > 1.96 - theSearchPhiTEC) &&
0205 (theStripDet->surface().position().phi() < 1.96 + theSearchPhiTEC)) {
0206 theBeam = 2;
0207 }
0208
0209 else if ((theStripDet->surface().position().phi() > 2.74 - theSearchPhiTEC) &&
0210 (theStripDet->surface().position().phi() < 2.74 + theSearchPhiTEC)) {
0211 theBeam = 3;
0212 }
0213
0214 else if ((theStripDet->surface().position().phi() > -2.74 - theSearchPhiTEC) &&
0215 (theStripDet->surface().position().phi() < -2.74 + theSearchPhiTEC)) {
0216 theBeam = 4;
0217 }
0218
0219 else if ((theStripDet->surface().position().phi() > -1.96 - theSearchPhiTEC) &&
0220 (theStripDet->surface().position().phi() < -1.96 + theSearchPhiTEC)) {
0221 theBeam = 5;
0222 }
0223
0224 else if ((theStripDet->surface().position().phi() > -1.18 - theSearchPhiTEC) &&
0225 (theStripDet->surface().position().phi() < -1.18 + theSearchPhiTEC)) {
0226 theBeam = 6;
0227 }
0228
0229 else if ((theStripDet->surface().position().phi() > -0.39 - theSearchPhiTEC) &&
0230 (theStripDet->surface().position().phi() < -0.39 + theSearchPhiTEC)) {
0231 theBeam = 7;
0232 }
0233
0234 else if ((theStripDet->surface().position().phi() > 1.28 - theSearchPhiTEC) &&
0235 (theStripDet->surface().position().phi() < 1.28 + theSearchPhiTEC)) {
0236 theBeam = 21;
0237 }
0238
0239 else if ((theStripDet->surface().position().phi() > 1.84 - theSearchPhiTEC) &&
0240 (theStripDet->surface().position().phi() < 1.84 + theSearchPhiTEC)) {
0241 theBeam = 22;
0242 }
0243
0244 else if ((theStripDet->surface().position().phi() > -2.59 - theSearchPhiTEC) &&
0245 (theStripDet->surface().position().phi() < -2.59 + theSearchPhiTEC)) {
0246 theBeam = 24;
0247 }
0248
0249 else if ((theStripDet->surface().position().phi() > -1.10 - theSearchPhiTEC) &&
0250 (theStripDet->surface().position().phi() < -1.10 + theSearchPhiTEC)) {
0251 theBeam = 26;
0252 }
0253
0254 else if ((theStripDet->surface().position().phi() > -0.50 - theSearchPhiTEC) &&
0255 (theStripDet->surface().position().phi() < -0.50 + theSearchPhiTEC)) {
0256 theBeam = 27;
0257 }
0258 else {
0259 theBeam = -1;
0260 }
0261 }
0262
0263
0264
0265
0266
0267
0268
0269
0270
0271
0272
0273
0274
0275
0276
0277
0278
0279 if ((thePart == "TEC+") && (theRing == 4) && (theBeam == 0)) {
0280 if (theTECWheel == 1) {
0281 fillAdcCounts(theMEBeam0Ring4Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0282 } else if (theTECWheel == 2) {
0283 fillAdcCounts(theMEBeam0Ring4Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0284 } else if (theTECWheel == 3) {
0285 fillAdcCounts(theMEBeam0Ring4Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0286 } else if (theTECWheel == 4) {
0287 fillAdcCounts(theMEBeam0Ring4Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0288 } else if (theTECWheel == 5) {
0289 fillAdcCounts(theMEBeam0Ring4Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0290 } else if (theTECWheel == 6) {
0291 fillAdcCounts(theMEBeam0Ring4Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0292 } else if (theTECWheel == 7) {
0293 fillAdcCounts(theMEBeam0Ring4Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0294 } else if (theTECWheel == 8) {
0295 fillAdcCounts(theMEBeam0Ring4Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0296 } else if (theTECWheel == 9) {
0297 fillAdcCounts(theMEBeam0Ring4Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0298 }
0299 }
0300
0301
0302
0303 else if ((thePart == "TEC+") && (theRing == 4) && (theBeam == 1)) {
0304 if (theTECWheel == 1) {
0305 fillAdcCounts(theMEBeam1Ring4Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0306 } else if (theTECWheel == 2) {
0307 fillAdcCounts(theMEBeam1Ring4Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0308 } else if (theTECWheel == 3) {
0309 fillAdcCounts(theMEBeam1Ring4Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0310 } else if (theTECWheel == 4) {
0311 fillAdcCounts(theMEBeam1Ring4Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0312 } else if (theTECWheel == 5) {
0313 fillAdcCounts(theMEBeam1Ring4Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0314 } else if (theTECWheel == 6) {
0315 fillAdcCounts(theMEBeam1Ring4Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0316 } else if (theTECWheel == 7) {
0317 fillAdcCounts(theMEBeam1Ring4Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0318 } else if (theTECWheel == 8) {
0319 fillAdcCounts(theMEBeam1Ring4Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0320 } else if (theTECWheel == 9) {
0321 fillAdcCounts(theMEBeam1Ring4Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0322 }
0323 }
0324
0325 else if ((thePart == "TEC+") && (theRing == 4) && (theBeam == 21)) {
0326 if (theTECWheel == 1) {
0327 fillAdcCounts(theMEBeam1Ring4Disc1PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0328 } else if (theTECWheel == 2) {
0329 fillAdcCounts(theMEBeam1Ring4Disc2PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0330 } else if (theTECWheel == 3) {
0331 fillAdcCounts(theMEBeam1Ring4Disc3PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0332 } else if (theTECWheel == 4) {
0333 fillAdcCounts(theMEBeam1Ring4Disc4PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0334 } else if (theTECWheel == 5) {
0335 fillAdcCounts(theMEBeam1Ring4Disc5PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0336 }
0337 }
0338
0339
0340
0341 else if ((thePart == "TEC+") && (theRing == 4) && (theBeam == 2)) {
0342 if (theTECWheel == 1) {
0343 fillAdcCounts(theMEBeam2Ring4Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0344 } else if (theTECWheel == 2) {
0345 fillAdcCounts(theMEBeam2Ring4Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0346 } else if (theTECWheel == 3) {
0347 fillAdcCounts(theMEBeam2Ring4Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0348 } else if (theTECWheel == 4) {
0349 fillAdcCounts(theMEBeam2Ring4Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0350 } else if (theTECWheel == 5) {
0351 fillAdcCounts(theMEBeam2Ring4Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0352 } else if (theTECWheel == 6) {
0353 fillAdcCounts(theMEBeam2Ring4Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0354 } else if (theTECWheel == 7) {
0355 fillAdcCounts(theMEBeam2Ring4Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0356 } else if (theTECWheel == 8) {
0357 fillAdcCounts(theMEBeam2Ring4Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0358 } else if (theTECWheel == 9) {
0359 fillAdcCounts(theMEBeam2Ring4Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0360 }
0361 }
0362
0363
0364 else if ((thePart == "TEC+") && (theRing == 4) && (theBeam == 22)) {
0365 if (theTECWheel == 1) {
0366 fillAdcCounts(theMEBeam2Ring4Disc1PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0367 } else if (theTECWheel == 2) {
0368 fillAdcCounts(theMEBeam2Ring4Disc2PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0369 } else if (theTECWheel == 3) {
0370 fillAdcCounts(theMEBeam2Ring4Disc3PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0371 } else if (theTECWheel == 4) {
0372 fillAdcCounts(theMEBeam2Ring4Disc4PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0373 } else if (theTECWheel == 5) {
0374 fillAdcCounts(theMEBeam2Ring4Disc5PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0375 }
0376 }
0377
0378
0379
0380 else if ((thePart == "TEC+") && (theRing == 4) && (theBeam == 3)) {
0381 if (theTECWheel == 1) {
0382 fillAdcCounts(theMEBeam3Ring4Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0383 } else if (theTECWheel == 2) {
0384 fillAdcCounts(theMEBeam3Ring4Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0385 } else if (theTECWheel == 3) {
0386 fillAdcCounts(theMEBeam3Ring4Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0387 } else if (theTECWheel == 4) {
0388 fillAdcCounts(theMEBeam3Ring4Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0389 } else if (theTECWheel == 5) {
0390 fillAdcCounts(theMEBeam3Ring4Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0391 } else if (theTECWheel == 6) {
0392 fillAdcCounts(theMEBeam3Ring4Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0393 } else if (theTECWheel == 7) {
0394 fillAdcCounts(theMEBeam3Ring4Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0395 } else if (theTECWheel == 8) {
0396 fillAdcCounts(theMEBeam3Ring4Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0397 } else if (theTECWheel == 9) {
0398 fillAdcCounts(theMEBeam3Ring4Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0399 }
0400 }
0401
0402
0403
0404 else if ((thePart == "TEC+") && (theRing == 4) && (theBeam == 4)) {
0405 if (theTECWheel == 1) {
0406 fillAdcCounts(theMEBeam4Ring4Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0407 } else if (theTECWheel == 2) {
0408 fillAdcCounts(theMEBeam4Ring4Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0409 } else if (theTECWheel == 3) {
0410 fillAdcCounts(theMEBeam4Ring4Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0411 } else if (theTECWheel == 4) {
0412 fillAdcCounts(theMEBeam4Ring4Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0413 } else if (theTECWheel == 5) {
0414 fillAdcCounts(theMEBeam4Ring4Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0415 } else if (theTECWheel == 6) {
0416 fillAdcCounts(theMEBeam4Ring4Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0417 } else if (theTECWheel == 7) {
0418 fillAdcCounts(theMEBeam4Ring4Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0419 } else if (theTECWheel == 8) {
0420 fillAdcCounts(theMEBeam4Ring4Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0421 } else if (theTECWheel == 9) {
0422 fillAdcCounts(theMEBeam4Ring4Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0423 }
0424 }
0425
0426 else if ((thePart == "TEC+") && (theRing == 4) && (theBeam == 24)) {
0427 if (theTECWheel == 1) {
0428 fillAdcCounts(theMEBeam4Ring4Disc1PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0429 } else if (theTECWheel == 2) {
0430 fillAdcCounts(theMEBeam4Ring4Disc2PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0431 } else if (theTECWheel == 3) {
0432 fillAdcCounts(theMEBeam4Ring4Disc3PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0433 } else if (theTECWheel == 4) {
0434 fillAdcCounts(theMEBeam4Ring4Disc4PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0435 } else if (theTECWheel == 5) {
0436 fillAdcCounts(theMEBeam4Ring4Disc5PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0437 }
0438 }
0439
0440
0441
0442 else if ((thePart == "TEC+") && (theRing == 4) && (theBeam == 5)) {
0443 if (theTECWheel == 1) {
0444 fillAdcCounts(theMEBeam5Ring4Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0445 } else if (theTECWheel == 2) {
0446 fillAdcCounts(theMEBeam5Ring4Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0447 } else if (theTECWheel == 3) {
0448 fillAdcCounts(theMEBeam5Ring4Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0449 } else if (theTECWheel == 4) {
0450 fillAdcCounts(theMEBeam5Ring4Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0451 } else if (theTECWheel == 5) {
0452 fillAdcCounts(theMEBeam5Ring4Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0453 } else if (theTECWheel == 6) {
0454 fillAdcCounts(theMEBeam5Ring4Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0455 } else if (theTECWheel == 7) {
0456 fillAdcCounts(theMEBeam5Ring4Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0457 } else if (theTECWheel == 8) {
0458 fillAdcCounts(theMEBeam5Ring4Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0459 } else if (theTECWheel == 9) {
0460 fillAdcCounts(theMEBeam5Ring4Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0461 }
0462 }
0463
0464
0465
0466 else if ((thePart == "TEC+") && (theRing == 4) && (theBeam == 6)) {
0467 if (theTECWheel == 1) {
0468 fillAdcCounts(theMEBeam6Ring4Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0469 } else if (theTECWheel == 2) {
0470 fillAdcCounts(theMEBeam6Ring4Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0471 } else if (theTECWheel == 3) {
0472 fillAdcCounts(theMEBeam6Ring4Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0473 } else if (theTECWheel == 4) {
0474 fillAdcCounts(theMEBeam6Ring4Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0475 } else if (theTECWheel == 5) {
0476 fillAdcCounts(theMEBeam6Ring4Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0477 } else if (theTECWheel == 6) {
0478 fillAdcCounts(theMEBeam6Ring4Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0479 } else if (theTECWheel == 7) {
0480 fillAdcCounts(theMEBeam6Ring4Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0481 } else if (theTECWheel == 8) {
0482 fillAdcCounts(theMEBeam6Ring4Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0483 } else if (theTECWheel == 9) {
0484 fillAdcCounts(theMEBeam6Ring4Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0485 }
0486 }
0487
0488 else if ((thePart == "TEC+") && (theRing == 4) && (theBeam == 26)) {
0489 if (theTECWheel == 1) {
0490 fillAdcCounts(theMEBeam6Ring4Disc1PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0491 } else if (theTECWheel == 2) {
0492 fillAdcCounts(theMEBeam6Ring4Disc2PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0493 } else if (theTECWheel == 3) {
0494 fillAdcCounts(theMEBeam6Ring4Disc3PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0495 } else if (theTECWheel == 4) {
0496 fillAdcCounts(theMEBeam6Ring4Disc4PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0497 } else if (theTECWheel == 5) {
0498 fillAdcCounts(theMEBeam6Ring4Disc5PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0499 }
0500 }
0501
0502
0503
0504 else if ((thePart == "TEC+") && (theRing == 4) && (theBeam == 7)) {
0505 if (theTECWheel == 1) {
0506 fillAdcCounts(theMEBeam7Ring4Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0507 } else if (theTECWheel == 2) {
0508 fillAdcCounts(theMEBeam7Ring4Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0509 } else if (theTECWheel == 3) {
0510 fillAdcCounts(theMEBeam7Ring4Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0511 } else if (theTECWheel == 4) {
0512 fillAdcCounts(theMEBeam7Ring4Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0513 } else if (theTECWheel == 5) {
0514 fillAdcCounts(theMEBeam7Ring4Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0515 } else if (theTECWheel == 6) {
0516 fillAdcCounts(theMEBeam7Ring4Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0517 } else if (theTECWheel == 7) {
0518 fillAdcCounts(theMEBeam7Ring4Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0519 } else if (theTECWheel == 8) {
0520 fillAdcCounts(theMEBeam7Ring4Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0521 } else if (theTECWheel == 9) {
0522 fillAdcCounts(theMEBeam7Ring4Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0523 }
0524 }
0525
0526 else if ((thePart == "TEC+") && (theRing == 4) && (theBeam == 27)) {
0527 if (theTECWheel == 1) {
0528 fillAdcCounts(theMEBeam7Ring4Disc1PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0529 } else if (theTECWheel == 2) {
0530 fillAdcCounts(theMEBeam7Ring4Disc2PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0531 } else if (theTECWheel == 3) {
0532 fillAdcCounts(theMEBeam7Ring4Disc3PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0533 } else if (theTECWheel == 4) {
0534 fillAdcCounts(theMEBeam7Ring4Disc4PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0535 } else if (theTECWheel == 5) {
0536 fillAdcCounts(theMEBeam7Ring4Disc5PosTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0537 }
0538 }
0539
0540
0541
0542 else if ((thePart == "TEC+") && (theRing == 6) && (theBeam == 0)) {
0543 if (theTECWheel == 1) {
0544 fillAdcCounts(theMEBeam0Ring6Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0545 } else if (theTECWheel == 2) {
0546 fillAdcCounts(theMEBeam0Ring6Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0547 } else if (theTECWheel == 3) {
0548 fillAdcCounts(theMEBeam0Ring6Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0549 } else if (theTECWheel == 4) {
0550 fillAdcCounts(theMEBeam0Ring6Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0551 } else if (theTECWheel == 5) {
0552 fillAdcCounts(theMEBeam0Ring6Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0553 } else if (theTECWheel == 6) {
0554 fillAdcCounts(theMEBeam0Ring6Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0555 } else if (theTECWheel == 7) {
0556 fillAdcCounts(theMEBeam0Ring6Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0557 } else if (theTECWheel == 8) {
0558 fillAdcCounts(theMEBeam0Ring6Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0559 } else if (theTECWheel == 9) {
0560 fillAdcCounts(theMEBeam0Ring6Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0561 }
0562 }
0563
0564
0565
0566 else if ((thePart == "TEC+") && (theRing == 6) && (theBeam == 1)) {
0567 if (theTECWheel == 1) {
0568 fillAdcCounts(theMEBeam1Ring6Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0569 } else if (theTECWheel == 2) {
0570 fillAdcCounts(theMEBeam1Ring6Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0571 } else if (theTECWheel == 3) {
0572 fillAdcCounts(theMEBeam1Ring6Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0573 } else if (theTECWheel == 4) {
0574 fillAdcCounts(theMEBeam1Ring6Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0575 } else if (theTECWheel == 5) {
0576 fillAdcCounts(theMEBeam1Ring6Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0577 } else if (theTECWheel == 6) {
0578 fillAdcCounts(theMEBeam1Ring6Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0579 } else if (theTECWheel == 7) {
0580 fillAdcCounts(theMEBeam1Ring6Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0581 } else if (theTECWheel == 8) {
0582 fillAdcCounts(theMEBeam1Ring6Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0583 } else if (theTECWheel == 9) {
0584 fillAdcCounts(theMEBeam1Ring6Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0585 }
0586 }
0587
0588
0589
0590 else if ((thePart == "TEC+") && (theRing == 6) && (theBeam == 2)) {
0591 if (theTECWheel == 1) {
0592 fillAdcCounts(theMEBeam2Ring6Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0593 } else if (theTECWheel == 2) {
0594 fillAdcCounts(theMEBeam2Ring6Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0595 } else if (theTECWheel == 3) {
0596 fillAdcCounts(theMEBeam2Ring6Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0597 } else if (theTECWheel == 4) {
0598 fillAdcCounts(theMEBeam2Ring6Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0599 } else if (theTECWheel == 5) {
0600 fillAdcCounts(theMEBeam2Ring6Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0601 } else if (theTECWheel == 6) {
0602 fillAdcCounts(theMEBeam2Ring6Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0603 } else if (theTECWheel == 7) {
0604 fillAdcCounts(theMEBeam2Ring6Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0605 } else if (theTECWheel == 8) {
0606 fillAdcCounts(theMEBeam2Ring6Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0607 } else if (theTECWheel == 9) {
0608 fillAdcCounts(theMEBeam2Ring6Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0609 }
0610 }
0611
0612
0613
0614 else if ((thePart == "TEC+") && (theRing == 6) && (theBeam == 3)) {
0615 if (theTECWheel == 1) {
0616 fillAdcCounts(theMEBeam3Ring6Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0617 } else if (theTECWheel == 2) {
0618 fillAdcCounts(theMEBeam3Ring6Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0619 } else if (theTECWheel == 3) {
0620 fillAdcCounts(theMEBeam3Ring6Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0621 } else if (theTECWheel == 4) {
0622 fillAdcCounts(theMEBeam3Ring6Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0623 } else if (theTECWheel == 5) {
0624 fillAdcCounts(theMEBeam3Ring6Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0625 } else if (theTECWheel == 6) {
0626 fillAdcCounts(theMEBeam3Ring6Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0627 } else if (theTECWheel == 7) {
0628 fillAdcCounts(theMEBeam3Ring6Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0629 } else if (theTECWheel == 8) {
0630 fillAdcCounts(theMEBeam3Ring6Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0631 } else if (theTECWheel == 9) {
0632 fillAdcCounts(theMEBeam3Ring6Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0633 }
0634 }
0635
0636
0637
0638 else if ((thePart == "TEC+") && (theRing == 6) && (theBeam == 4)) {
0639 if (theTECWheel == 1) {
0640 fillAdcCounts(theMEBeam4Ring6Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0641 } else if (theTECWheel == 2) {
0642 fillAdcCounts(theMEBeam4Ring6Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0643 } else if (theTECWheel == 3) {
0644 fillAdcCounts(theMEBeam4Ring6Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0645 } else if (theTECWheel == 4) {
0646 fillAdcCounts(theMEBeam4Ring6Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0647 } else if (theTECWheel == 5) {
0648 fillAdcCounts(theMEBeam4Ring6Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0649 } else if (theTECWheel == 6) {
0650 fillAdcCounts(theMEBeam4Ring6Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0651 } else if (theTECWheel == 7) {
0652 fillAdcCounts(theMEBeam4Ring6Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0653 } else if (theTECWheel == 8) {
0654 fillAdcCounts(theMEBeam4Ring6Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0655 } else if (theTECWheel == 9) {
0656 fillAdcCounts(theMEBeam4Ring6Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0657 }
0658 }
0659
0660
0661
0662 else if ((thePart == "TEC+") && (theRing == 6) && (theBeam == 5)) {
0663 if (theTECWheel == 1) {
0664 fillAdcCounts(theMEBeam5Ring6Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0665 } else if (theTECWheel == 2) {
0666 fillAdcCounts(theMEBeam5Ring6Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0667 } else if (theTECWheel == 3) {
0668 fillAdcCounts(theMEBeam5Ring6Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0669 } else if (theTECWheel == 4) {
0670 fillAdcCounts(theMEBeam5Ring6Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0671 } else if (theTECWheel == 5) {
0672 fillAdcCounts(theMEBeam5Ring6Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0673 } else if (theTECWheel == 6) {
0674 fillAdcCounts(theMEBeam5Ring6Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0675 } else if (theTECWheel == 7) {
0676 fillAdcCounts(theMEBeam5Ring6Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0677 } else if (theTECWheel == 8) {
0678 fillAdcCounts(theMEBeam5Ring6Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0679 } else if (theTECWheel == 9) {
0680 fillAdcCounts(theMEBeam5Ring6Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0681 }
0682 }
0683
0684
0685
0686 else if ((thePart == "TEC+") && (theRing == 6) && (theBeam == 6)) {
0687 if (theTECWheel == 1) {
0688 fillAdcCounts(theMEBeam6Ring6Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0689 } else if (theTECWheel == 2) {
0690 fillAdcCounts(theMEBeam6Ring6Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0691 } else if (theTECWheel == 3) {
0692 fillAdcCounts(theMEBeam6Ring6Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0693 } else if (theTECWheel == 4) {
0694 fillAdcCounts(theMEBeam6Ring6Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0695 } else if (theTECWheel == 5) {
0696 fillAdcCounts(theMEBeam6Ring6Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0697 } else if (theTECWheel == 6) {
0698 fillAdcCounts(theMEBeam6Ring6Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0699 } else if (theTECWheel == 7) {
0700 fillAdcCounts(theMEBeam6Ring6Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0701 } else if (theTECWheel == 8) {
0702 fillAdcCounts(theMEBeam6Ring6Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0703 } else if (theTECWheel == 9) {
0704 fillAdcCounts(theMEBeam6Ring6Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0705 }
0706 }
0707
0708
0709
0710 else if ((thePart == "TEC+") && (theRing == 6) && (theBeam == 7)) {
0711 if (theTECWheel == 1) {
0712 fillAdcCounts(theMEBeam7Ring6Disc1PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0713 } else if (theTECWheel == 2) {
0714 fillAdcCounts(theMEBeam7Ring6Disc2PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0715 } else if (theTECWheel == 3) {
0716 fillAdcCounts(theMEBeam7Ring6Disc3PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0717 } else if (theTECWheel == 4) {
0718 fillAdcCounts(theMEBeam7Ring6Disc4PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0719 } else if (theTECWheel == 5) {
0720 fillAdcCounts(theMEBeam7Ring6Disc5PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0721 } else if (theTECWheel == 6) {
0722 fillAdcCounts(theMEBeam7Ring6Disc6PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0723 } else if (theTECWheel == 7) {
0724 fillAdcCounts(theMEBeam7Ring6Disc7PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0725 } else if (theTECWheel == 8) {
0726 fillAdcCounts(theMEBeam7Ring6Disc8PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0727 } else if (theTECWheel == 9) {
0728 fillAdcCounts(theMEBeam7Ring6Disc9PosAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0729 }
0730 }
0731
0732
0733
0734 else if ((thePart == "TEC-") && (theRing == 4) && (theBeam == 0)) {
0735 if (theTECWheel == 1) {
0736 fillAdcCounts(theMEBeam0Ring4Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0737 } else if (theTECWheel == 2) {
0738 fillAdcCounts(theMEBeam0Ring4Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0739 } else if (theTECWheel == 3) {
0740 fillAdcCounts(theMEBeam0Ring4Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0741 } else if (theTECWheel == 4) {
0742 fillAdcCounts(theMEBeam0Ring4Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0743 } else if (theTECWheel == 5) {
0744 fillAdcCounts(theMEBeam0Ring4Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0745 } else if (theTECWheel == 6) {
0746 fillAdcCounts(theMEBeam0Ring4Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0747 } else if (theTECWheel == 7) {
0748 fillAdcCounts(theMEBeam0Ring4Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0749 } else if (theTECWheel == 8) {
0750 fillAdcCounts(theMEBeam0Ring4Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0751 } else if (theTECWheel == 9) {
0752 fillAdcCounts(theMEBeam0Ring4Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0753 }
0754 }
0755
0756
0757
0758 else if ((thePart == "TEC-") && (theRing == 4) && (theBeam == 1)) {
0759 if (theTECWheel == 1) {
0760 fillAdcCounts(theMEBeam1Ring4Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0761 } else if (theTECWheel == 2) {
0762 fillAdcCounts(theMEBeam1Ring4Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0763 } else if (theTECWheel == 3) {
0764 fillAdcCounts(theMEBeam1Ring4Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0765 } else if (theTECWheel == 4) {
0766 fillAdcCounts(theMEBeam1Ring4Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0767 } else if (theTECWheel == 5) {
0768 fillAdcCounts(theMEBeam1Ring4Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0769 } else if (theTECWheel == 6) {
0770 fillAdcCounts(theMEBeam1Ring4Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0771 } else if (theTECWheel == 7) {
0772 fillAdcCounts(theMEBeam1Ring4Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0773 } else if (theTECWheel == 8) {
0774 fillAdcCounts(theMEBeam1Ring4Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0775 } else if (theTECWheel == 9) {
0776 fillAdcCounts(theMEBeam1Ring4Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0777 }
0778 }
0779
0780 else if ((thePart == "TEC-") && (theRing == 4) && (theBeam == 21)) {
0781 if (theTECWheel == 1) {
0782 fillAdcCounts(theMEBeam1Ring4Disc1NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0783 } else if (theTECWheel == 2) {
0784 fillAdcCounts(theMEBeam1Ring4Disc2NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0785 } else if (theTECWheel == 3) {
0786 fillAdcCounts(theMEBeam1Ring4Disc3NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0787 } else if (theTECWheel == 4) {
0788 fillAdcCounts(theMEBeam1Ring4Disc4NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0789 } else if (theTECWheel == 5) {
0790 fillAdcCounts(theMEBeam1Ring4Disc5NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0791 }
0792 }
0793
0794
0795
0796 else if ((thePart == "TEC-") && (theRing == 4) && (theBeam == 2)) {
0797 if (theTECWheel == 1) {
0798 fillAdcCounts(theMEBeam2Ring4Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0799 } else if (theTECWheel == 2) {
0800 fillAdcCounts(theMEBeam2Ring4Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0801 } else if (theTECWheel == 3) {
0802 fillAdcCounts(theMEBeam2Ring4Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0803 } else if (theTECWheel == 4) {
0804 fillAdcCounts(theMEBeam2Ring4Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0805 } else if (theTECWheel == 5) {
0806 fillAdcCounts(theMEBeam2Ring4Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0807 } else if (theTECWheel == 6) {
0808 fillAdcCounts(theMEBeam2Ring4Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0809 } else if (theTECWheel == 7) {
0810 fillAdcCounts(theMEBeam2Ring4Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0811 } else if (theTECWheel == 8) {
0812 fillAdcCounts(theMEBeam2Ring4Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0813 } else if (theTECWheel == 9) {
0814 fillAdcCounts(theMEBeam2Ring4Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0815 }
0816 }
0817
0818
0819 else if ((thePart == "TEC-") && (theRing == 4) && (theBeam == 22)) {
0820 if (theTECWheel == 1) {
0821 fillAdcCounts(theMEBeam2Ring4Disc1NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0822 } else if (theTECWheel == 2) {
0823 fillAdcCounts(theMEBeam2Ring4Disc2NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0824 } else if (theTECWheel == 3) {
0825 fillAdcCounts(theMEBeam2Ring4Disc3NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0826 } else if (theTECWheel == 4) {
0827 fillAdcCounts(theMEBeam2Ring4Disc4NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0828 } else if (theTECWheel == 5) {
0829 fillAdcCounts(theMEBeam2Ring4Disc5NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0830 }
0831 }
0832
0833
0834
0835 else if ((thePart == "TEC-") && (theRing == 4) && (theBeam == 3)) {
0836 if (theTECWheel == 1) {
0837 fillAdcCounts(theMEBeam3Ring4Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0838 } else if (theTECWheel == 2) {
0839 fillAdcCounts(theMEBeam3Ring4Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0840 } else if (theTECWheel == 3) {
0841 fillAdcCounts(theMEBeam3Ring4Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0842 } else if (theTECWheel == 4) {
0843 fillAdcCounts(theMEBeam3Ring4Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0844 } else if (theTECWheel == 5) {
0845 fillAdcCounts(theMEBeam3Ring4Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0846 } else if (theTECWheel == 6) {
0847 fillAdcCounts(theMEBeam3Ring4Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0848 } else if (theTECWheel == 7) {
0849 fillAdcCounts(theMEBeam3Ring4Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0850 } else if (theTECWheel == 8) {
0851 fillAdcCounts(theMEBeam3Ring4Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0852 } else if (theTECWheel == 9) {
0853 fillAdcCounts(theMEBeam3Ring4Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0854 }
0855 }
0856
0857
0858
0859 else if ((thePart == "TEC-") && (theRing == 4) && (theBeam == 4)) {
0860 if (theTECWheel == 1) {
0861 fillAdcCounts(theMEBeam4Ring4Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0862 } else if (theTECWheel == 2) {
0863 fillAdcCounts(theMEBeam4Ring4Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0864 } else if (theTECWheel == 3) {
0865 fillAdcCounts(theMEBeam4Ring4Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0866 } else if (theTECWheel == 4) {
0867 fillAdcCounts(theMEBeam4Ring4Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0868 } else if (theTECWheel == 5) {
0869 fillAdcCounts(theMEBeam4Ring4Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0870 } else if (theTECWheel == 6) {
0871 fillAdcCounts(theMEBeam4Ring4Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0872 } else if (theTECWheel == 7) {
0873 fillAdcCounts(theMEBeam4Ring4Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0874 } else if (theTECWheel == 8) {
0875 fillAdcCounts(theMEBeam4Ring4Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0876 } else if (theTECWheel == 9) {
0877 fillAdcCounts(theMEBeam4Ring4Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0878 }
0879 }
0880
0881 else if ((thePart == "TEC-") && (theRing == 4) && (theBeam == 24)) {
0882 if (theTECWheel == 1) {
0883 fillAdcCounts(theMEBeam4Ring4Disc1NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0884 } else if (theTECWheel == 2) {
0885 fillAdcCounts(theMEBeam4Ring4Disc2NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0886 } else if (theTECWheel == 3) {
0887 fillAdcCounts(theMEBeam4Ring4Disc3NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0888 } else if (theTECWheel == 4) {
0889 fillAdcCounts(theMEBeam4Ring4Disc4NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0890 } else if (theTECWheel == 5) {
0891 fillAdcCounts(theMEBeam4Ring4Disc5NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0892 }
0893 }
0894
0895
0896
0897 else if ((thePart == "TEC-") && (theRing == 4) && (theBeam == 5)) {
0898 if (theTECWheel == 1) {
0899 fillAdcCounts(theMEBeam5Ring4Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0900 } else if (theTECWheel == 2) {
0901 fillAdcCounts(theMEBeam5Ring4Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0902 } else if (theTECWheel == 3) {
0903 fillAdcCounts(theMEBeam5Ring4Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0904 } else if (theTECWheel == 4) {
0905 fillAdcCounts(theMEBeam5Ring4Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0906 } else if (theTECWheel == 5) {
0907 fillAdcCounts(theMEBeam5Ring4Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0908 } else if (theTECWheel == 6) {
0909 fillAdcCounts(theMEBeam5Ring4Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0910 } else if (theTECWheel == 7) {
0911 fillAdcCounts(theMEBeam5Ring4Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0912 } else if (theTECWheel == 8) {
0913 fillAdcCounts(theMEBeam5Ring4Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0914 } else if (theTECWheel == 9) {
0915 fillAdcCounts(theMEBeam5Ring4Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0916 }
0917 }
0918
0919
0920
0921 else if ((thePart == "TEC-") && (theRing == 4) && (theBeam == 6)) {
0922 if (theTECWheel == 1) {
0923 fillAdcCounts(theMEBeam6Ring4Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0924 } else if (theTECWheel == 2) {
0925 fillAdcCounts(theMEBeam6Ring4Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0926 } else if (theTECWheel == 3) {
0927 fillAdcCounts(theMEBeam6Ring4Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0928 } else if (theTECWheel == 4) {
0929 fillAdcCounts(theMEBeam6Ring4Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0930 } else if (theTECWheel == 5) {
0931 fillAdcCounts(theMEBeam6Ring4Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0932 } else if (theTECWheel == 6) {
0933 fillAdcCounts(theMEBeam6Ring4Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0934 } else if (theTECWheel == 7) {
0935 fillAdcCounts(theMEBeam6Ring4Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0936 } else if (theTECWheel == 8) {
0937 fillAdcCounts(theMEBeam6Ring4Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0938 } else if (theTECWheel == 9) {
0939 fillAdcCounts(theMEBeam6Ring4Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0940 }
0941 }
0942
0943 else if ((thePart == "TEC-") && (theRing == 4) && (theBeam == 26)) {
0944 if (theTECWheel == 1) {
0945 fillAdcCounts(theMEBeam6Ring4Disc1NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0946 } else if (theTECWheel == 2) {
0947 fillAdcCounts(theMEBeam6Ring4Disc2NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0948 } else if (theTECWheel == 3) {
0949 fillAdcCounts(theMEBeam6Ring4Disc3NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0950 } else if (theTECWheel == 4) {
0951 fillAdcCounts(theMEBeam6Ring4Disc4NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0952 } else if (theTECWheel == 5) {
0953 fillAdcCounts(theMEBeam6Ring4Disc5NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0954 }
0955 }
0956
0957
0958
0959 else if ((thePart == "TEC-") && (theRing == 4) && (theBeam == 7)) {
0960 if (theTECWheel == 1) {
0961 fillAdcCounts(theMEBeam7Ring4Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0962 } else if (theTECWheel == 2) {
0963 fillAdcCounts(theMEBeam7Ring4Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0964 } else if (theTECWheel == 3) {
0965 fillAdcCounts(theMEBeam7Ring4Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0966 } else if (theTECWheel == 4) {
0967 fillAdcCounts(theMEBeam7Ring4Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0968 } else if (theTECWheel == 5) {
0969 fillAdcCounts(theMEBeam7Ring4Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0970 } else if (theTECWheel == 6) {
0971 fillAdcCounts(theMEBeam7Ring4Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0972 } else if (theTECWheel == 7) {
0973 fillAdcCounts(theMEBeam7Ring4Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0974 } else if (theTECWheel == 8) {
0975 fillAdcCounts(theMEBeam7Ring4Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0976 } else if (theTECWheel == 9) {
0977 fillAdcCounts(theMEBeam7Ring4Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0978 }
0979 }
0980
0981 else if ((thePart == "TEC-") && (theRing == 4) && (theBeam == 27)) {
0982 if (theTECWheel == 1) {
0983 fillAdcCounts(theMEBeam7Ring4Disc1NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0984 } else if (theTECWheel == 2) {
0985 fillAdcCounts(theMEBeam7Ring4Disc2NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0986 } else if (theTECWheel == 3) {
0987 fillAdcCounts(theMEBeam7Ring4Disc3NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0988 } else if (theTECWheel == 4) {
0989 fillAdcCounts(theMEBeam7Ring4Disc4NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0990 } else if (theTECWheel == 5) {
0991 fillAdcCounts(theMEBeam7Ring4Disc5NegTEC2TECAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
0992 }
0993 }
0994
0995
0996
0997 else if ((thePart == "TEC-") && (theRing == 6) && (theBeam == 0)) {
0998 if (theTECWheel == 1) {
0999 fillAdcCounts(theMEBeam0Ring6Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1000 } else if (theTECWheel == 2) {
1001 fillAdcCounts(theMEBeam0Ring6Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1002 } else if (theTECWheel == 3) {
1003 fillAdcCounts(theMEBeam0Ring6Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1004 } else if (theTECWheel == 4) {
1005 fillAdcCounts(theMEBeam0Ring6Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1006 } else if (theTECWheel == 5) {
1007 fillAdcCounts(theMEBeam0Ring6Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1008 } else if (theTECWheel == 6) {
1009 fillAdcCounts(theMEBeam0Ring6Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1010 } else if (theTECWheel == 7) {
1011 fillAdcCounts(theMEBeam0Ring6Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1012 } else if (theTECWheel == 8) {
1013 fillAdcCounts(theMEBeam0Ring6Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1014 } else if (theTECWheel == 9) {
1015 fillAdcCounts(theMEBeam0Ring6Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1016 }
1017 }
1018
1019
1020
1021 else if ((thePart == "TEC-") && (theRing == 6) && (theBeam == 1)) {
1022 if (theTECWheel == 1) {
1023 fillAdcCounts(theMEBeam1Ring6Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1024 } else if (theTECWheel == 2) {
1025 fillAdcCounts(theMEBeam1Ring6Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1026 } else if (theTECWheel == 3) {
1027 fillAdcCounts(theMEBeam1Ring6Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1028 } else if (theTECWheel == 4) {
1029 fillAdcCounts(theMEBeam1Ring6Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1030 } else if (theTECWheel == 5) {
1031 fillAdcCounts(theMEBeam1Ring6Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1032 } else if (theTECWheel == 6) {
1033 fillAdcCounts(theMEBeam1Ring6Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1034 } else if (theTECWheel == 7) {
1035 fillAdcCounts(theMEBeam1Ring6Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1036 } else if (theTECWheel == 8) {
1037 fillAdcCounts(theMEBeam1Ring6Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1038 } else if (theTECWheel == 9) {
1039 fillAdcCounts(theMEBeam1Ring6Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1040 }
1041 }
1042
1043
1044
1045 else if ((thePart == "TEC-") && (theRing == 6) && (theBeam == 2)) {
1046 if (theTECWheel == 1) {
1047 fillAdcCounts(theMEBeam2Ring6Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1048 } else if (theTECWheel == 2) {
1049 fillAdcCounts(theMEBeam2Ring6Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1050 } else if (theTECWheel == 3) {
1051 fillAdcCounts(theMEBeam2Ring6Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1052 } else if (theTECWheel == 4) {
1053 fillAdcCounts(theMEBeam2Ring6Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1054 } else if (theTECWheel == 5) {
1055 fillAdcCounts(theMEBeam2Ring6Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1056 } else if (theTECWheel == 6) {
1057 fillAdcCounts(theMEBeam2Ring6Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1058 } else if (theTECWheel == 7) {
1059 fillAdcCounts(theMEBeam2Ring6Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1060 } else if (theTECWheel == 8) {
1061 fillAdcCounts(theMEBeam2Ring6Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1062 } else if (theTECWheel == 9) {
1063 fillAdcCounts(theMEBeam2Ring6Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1064 }
1065 }
1066
1067
1068
1069 else if ((thePart == "TEC-") && (theRing == 6) && (theBeam == 3)) {
1070 if (theTECWheel == 1) {
1071 fillAdcCounts(theMEBeam3Ring6Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1072 } else if (theTECWheel == 2) {
1073 fillAdcCounts(theMEBeam3Ring6Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1074 } else if (theTECWheel == 3) {
1075 fillAdcCounts(theMEBeam3Ring6Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1076 } else if (theTECWheel == 4) {
1077 fillAdcCounts(theMEBeam3Ring6Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1078 } else if (theTECWheel == 5) {
1079 fillAdcCounts(theMEBeam3Ring6Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1080 } else if (theTECWheel == 6) {
1081 fillAdcCounts(theMEBeam3Ring6Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1082 } else if (theTECWheel == 7) {
1083 fillAdcCounts(theMEBeam3Ring6Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1084 } else if (theTECWheel == 8) {
1085 fillAdcCounts(theMEBeam3Ring6Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1086 } else if (theTECWheel == 9) {
1087 fillAdcCounts(theMEBeam3Ring6Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1088 }
1089 }
1090
1091
1092
1093 else if ((thePart == "TEC-") && (theRing == 6) && (theBeam == 4)) {
1094 if (theTECWheel == 1) {
1095 fillAdcCounts(theMEBeam4Ring6Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1096 } else if (theTECWheel == 2) {
1097 fillAdcCounts(theMEBeam4Ring6Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1098 } else if (theTECWheel == 3) {
1099 fillAdcCounts(theMEBeam4Ring6Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1100 } else if (theTECWheel == 4) {
1101 fillAdcCounts(theMEBeam4Ring6Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1102 } else if (theTECWheel == 5) {
1103 fillAdcCounts(theMEBeam4Ring6Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1104 } else if (theTECWheel == 6) {
1105 fillAdcCounts(theMEBeam4Ring6Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1106 } else if (theTECWheel == 7) {
1107 fillAdcCounts(theMEBeam4Ring6Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1108 } else if (theTECWheel == 8) {
1109 fillAdcCounts(theMEBeam4Ring6Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1110 } else if (theTECWheel == 9) {
1111 fillAdcCounts(theMEBeam4Ring6Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1112 }
1113 }
1114
1115
1116
1117 else if ((thePart == "TEC-") && (theRing == 6) && (theBeam == 5)) {
1118 if (theTECWheel == 1) {
1119 fillAdcCounts(theMEBeam5Ring6Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1120 } else if (theTECWheel == 2) {
1121 fillAdcCounts(theMEBeam5Ring6Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1122 } else if (theTECWheel == 3) {
1123 fillAdcCounts(theMEBeam5Ring6Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1124 } else if (theTECWheel == 4) {
1125 fillAdcCounts(theMEBeam5Ring6Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1126 } else if (theTECWheel == 5) {
1127 fillAdcCounts(theMEBeam5Ring6Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1128 } else if (theTECWheel == 6) {
1129 fillAdcCounts(theMEBeam5Ring6Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1130 } else if (theTECWheel == 7) {
1131 fillAdcCounts(theMEBeam5Ring6Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1132 } else if (theTECWheel == 8) {
1133 fillAdcCounts(theMEBeam5Ring6Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1134 } else if (theTECWheel == 9) {
1135 fillAdcCounts(theMEBeam5Ring6Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1136 }
1137 }
1138
1139
1140
1141 else if ((thePart == "TEC-") && (theRing == 6) && (theBeam == 6)) {
1142 if (theTECWheel == 1) {
1143 fillAdcCounts(theMEBeam6Ring6Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1144 } else if (theTECWheel == 2) {
1145 fillAdcCounts(theMEBeam6Ring6Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1146 } else if (theTECWheel == 3) {
1147 fillAdcCounts(theMEBeam6Ring6Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1148 } else if (theTECWheel == 4) {
1149 fillAdcCounts(theMEBeam6Ring6Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1150 } else if (theTECWheel == 5) {
1151 fillAdcCounts(theMEBeam6Ring6Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1152 } else if (theTECWheel == 6) {
1153 fillAdcCounts(theMEBeam6Ring6Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1154 } else if (theTECWheel == 7) {
1155 fillAdcCounts(theMEBeam6Ring6Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1156 } else if (theTECWheel == 8) {
1157 fillAdcCounts(theMEBeam6Ring6Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1158 } else if (theTECWheel == 9) {
1159 fillAdcCounts(theMEBeam6Ring6Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1160 }
1161 }
1162
1163
1164
1165 else if ((thePart == "TEC-") && (theRing == 6) && (theBeam == 7)) {
1166 if (theTECWheel == 1) {
1167 fillAdcCounts(theMEBeam7Ring6Disc1NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1168 } else if (theTECWheel == 2) {
1169 fillAdcCounts(theMEBeam7Ring6Disc2NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1170 } else if (theTECWheel == 3) {
1171 fillAdcCounts(theMEBeam7Ring6Disc3NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1172 } else if (theTECWheel == 4) {
1173 fillAdcCounts(theMEBeam7Ring6Disc4NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1174 } else if (theTECWheel == 5) {
1175 fillAdcCounts(theMEBeam7Ring6Disc5NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1176 } else if (theTECWheel == 6) {
1177 fillAdcCounts(theMEBeam7Ring6Disc6NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1178 } else if (theTECWheel == 7) {
1179 fillAdcCounts(theMEBeam7Ring6Disc7NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1180 } else if (theTECWheel == 8) {
1181 fillAdcCounts(theMEBeam7Ring6Disc8NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1182 } else if (theTECWheel == 9) {
1183 fillAdcCounts(theMEBeam7Ring6Disc9NegAdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1184 }
1185 }
1186
1187
1188
1189
1190 else if ((thePart == "TOB") && (theTOBLayer == 1) && (theBeam == 0) && (theTOBStereoDet == 0) &&
1191 (theStripDet->surface().position().perp() < 58.5)) {
1192 if ((theStripDet->surface().position().z() > 99.0 - theSearchZTOB) &&
1193 (theStripDet->surface().position().z() < 99.0 + theSearchZTOB)) {
1194 fillAdcCounts(theMEBeam0TOBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1195 } else if ((theStripDet->surface().position().z() > 64.0 - theSearchZTOB) &&
1196 (theStripDet->surface().position().z() < 64.0 + theSearchZTOB)) {
1197 fillAdcCounts(theMEBeam0TOBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1198 } else if ((theStripDet->surface().position().z() > 27.5 - theSearchZTOB) &&
1199 (theStripDet->surface().position().z() < 27.5 + theSearchZTOB)) {
1200 fillAdcCounts(theMEBeam0TOBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1201 } else if ((theStripDet->surface().position().z() < -10.0 + theSearchZTOB) &&
1202 (theStripDet->surface().position().z() > -10.0 - theSearchZTOB)) {
1203 fillAdcCounts(theMEBeam0TOBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1204 } else if ((theStripDet->surface().position().z() < -46.0 + theSearchZTOB) &&
1205 (theStripDet->surface().position().z() > -46.0 - theSearchZTOB)) {
1206 fillAdcCounts(theMEBeam0TOBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1207 } else if ((theStripDet->surface().position().z() < -80.0 + theSearchZTOB) &&
1208 (theStripDet->surface().position().z() > -80.0 - theSearchZTOB)) {
1209 fillAdcCounts(theMEBeam0TOBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1210 }
1211 }
1212
1213
1214
1215 else if ((thePart == "TOB") && (theTOBLayer == 1) && (theBeam == 1) && (theTOBStereoDet == 0) &&
1216 (theStripDet->surface().position().perp() < 58.5)) {
1217 if ((theStripDet->surface().position().z() > 99.0 - theSearchZTOB) &&
1218 (theStripDet->surface().position().z() < 99.0 + theSearchZTOB)) {
1219 fillAdcCounts(theMEBeam1TOBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1220 } else if ((theStripDet->surface().position().z() > 64.0 - theSearchZTOB) &&
1221 (theStripDet->surface().position().z() < 64.0 + theSearchZTOB)) {
1222 fillAdcCounts(theMEBeam1TOBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1223 } else if ((theStripDet->surface().position().z() > 27.5 - theSearchZTOB) &&
1224 (theStripDet->surface().position().z() < 27.5 + theSearchZTOB)) {
1225 fillAdcCounts(theMEBeam1TOBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1226 } else if ((theStripDet->surface().position().z() < -10.0 + theSearchZTOB) &&
1227 (theStripDet->surface().position().z() > -10.0 - theSearchZTOB)) {
1228 fillAdcCounts(theMEBeam1TOBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1229 } else if ((theStripDet->surface().position().z() < -46.0 + theSearchZTOB) &&
1230 (theStripDet->surface().position().z() > -46.0 - theSearchZTOB)) {
1231 fillAdcCounts(theMEBeam1TOBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1232 } else if ((theStripDet->surface().position().z() < -80.0 + theSearchZTOB) &&
1233 (theStripDet->surface().position().z() > -80.0 - theSearchZTOB)) {
1234 fillAdcCounts(theMEBeam1TOBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1235 }
1236 }
1237
1238
1239
1240 else if ((thePart == "TOB") && (theTOBLayer == 1) && (theBeam == 2) && (theTOBStereoDet == 0) &&
1241 (theStripDet->surface().position().perp() < 58.5)) {
1242 if ((theStripDet->surface().position().z() > 99.0 - theSearchZTOB) &&
1243 (theStripDet->surface().position().z() < 99.0 + theSearchZTOB)) {
1244 fillAdcCounts(theMEBeam2TOBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1245 } else if ((theStripDet->surface().position().z() > 64.0 - theSearchZTOB) &&
1246 (theStripDet->surface().position().z() < 64.0 + theSearchZTOB)) {
1247 fillAdcCounts(theMEBeam2TOBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1248 } else if ((theStripDet->surface().position().z() > 27.5 - theSearchZTOB) &&
1249 (theStripDet->surface().position().z() < 27.5 + theSearchZTOB)) {
1250 fillAdcCounts(theMEBeam2TOBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1251 } else if ((theStripDet->surface().position().z() < -10.0 + theSearchZTOB) &&
1252 (theStripDet->surface().position().z() > -10.0 - theSearchZTOB)) {
1253 fillAdcCounts(theMEBeam2TOBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1254 } else if ((theStripDet->surface().position().z() < -46.0 + theSearchZTOB) &&
1255 (theStripDet->surface().position().z() > -46.0 - theSearchZTOB)) {
1256 fillAdcCounts(theMEBeam2TOBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1257 } else if ((theStripDet->surface().position().z() < -80.0 + theSearchZTOB) &&
1258 (theStripDet->surface().position().z() > -80.0 - theSearchZTOB)) {
1259 fillAdcCounts(theMEBeam2TOBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1260 }
1261 }
1262
1263
1264
1265 else if ((thePart == "TOB") && (theTOBLayer == 1) && (theBeam == 3) && (theTOBStereoDet == 0) &&
1266 (theStripDet->surface().position().perp() < 58.5)) {
1267 if ((theStripDet->surface().position().z() > 99.0 - theSearchZTOB) &&
1268 (theStripDet->surface().position().z() < 99.0 + theSearchZTOB)) {
1269 fillAdcCounts(theMEBeam3TOBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1270 } else if ((theStripDet->surface().position().z() > 64.0 - theSearchZTOB) &&
1271 (theStripDet->surface().position().z() < 64.0 + theSearchZTOB)) {
1272 fillAdcCounts(theMEBeam3TOBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1273 } else if ((theStripDet->surface().position().z() > 27.5 - theSearchZTOB) &&
1274 (theStripDet->surface().position().z() < 27.5 + theSearchZTOB)) {
1275 fillAdcCounts(theMEBeam3TOBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1276 } else if ((theStripDet->surface().position().z() < -10.0 + theSearchZTOB) &&
1277 (theStripDet->surface().position().z() > -10.0 - theSearchZTOB)) {
1278 fillAdcCounts(theMEBeam3TOBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1279 } else if ((theStripDet->surface().position().z() < -46.0 + theSearchZTOB) &&
1280 (theStripDet->surface().position().z() > -46.0 - theSearchZTOB)) {
1281 fillAdcCounts(theMEBeam3TOBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1282 } else if ((theStripDet->surface().position().z() < -80.0 + theSearchZTOB) &&
1283 (theStripDet->surface().position().z() > -80.0 - theSearchZTOB)) {
1284 fillAdcCounts(theMEBeam3TOBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1285 }
1286 }
1287
1288
1289
1290 else if ((thePart == "TOB") && (theTOBLayer == 1) && (theBeam == 4) && (theTOBStereoDet == 0) &&
1291 (theStripDet->surface().position().perp() < 58.5)) {
1292 if ((theStripDet->surface().position().z() > 99.0 - theSearchZTOB) &&
1293 (theStripDet->surface().position().z() < 99.0 + theSearchZTOB)) {
1294 fillAdcCounts(theMEBeam4TOBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1295 } else if ((theStripDet->surface().position().z() > 64.0 - theSearchZTOB) &&
1296 (theStripDet->surface().position().z() < 64.0 + theSearchZTOB)) {
1297 fillAdcCounts(theMEBeam4TOBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1298 } else if ((theStripDet->surface().position().z() > 27.5 - theSearchZTOB) &&
1299 (theStripDet->surface().position().z() < 27.5 + theSearchZTOB)) {
1300 fillAdcCounts(theMEBeam4TOBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1301 } else if ((theStripDet->surface().position().z() < -10.0 + theSearchZTOB) &&
1302 (theStripDet->surface().position().z() > -10.0 - theSearchZTOB)) {
1303 fillAdcCounts(theMEBeam4TOBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1304 } else if ((theStripDet->surface().position().z() < -46.0 + theSearchZTOB) &&
1305 (theStripDet->surface().position().z() > -46.0 - theSearchZTOB)) {
1306 fillAdcCounts(theMEBeam4TOBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1307 } else if ((theStripDet->surface().position().z() < -80.0 + theSearchZTOB) &&
1308 (theStripDet->surface().position().z() > -80.0 - theSearchZTOB)) {
1309 fillAdcCounts(theMEBeam4TOBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1310 }
1311 }
1312
1313
1314
1315 else if ((thePart == "TOB") && (theTOBLayer == 1) && (theBeam == 5) && (theTOBStereoDet == 0) &&
1316 (theStripDet->surface().position().perp() < 58.5)) {
1317 if ((theStripDet->surface().position().z() > 99.0 - theSearchZTOB) &&
1318 (theStripDet->surface().position().z() < 99.0 + theSearchZTOB)) {
1319 fillAdcCounts(theMEBeam5TOBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1320 } else if ((theStripDet->surface().position().z() > 64.0 - theSearchZTOB) &&
1321 (theStripDet->surface().position().z() < 64.0 + theSearchZTOB)) {
1322 fillAdcCounts(theMEBeam5TOBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1323 } else if ((theStripDet->surface().position().z() > 27.5 - theSearchZTOB) &&
1324 (theStripDet->surface().position().z() < 27.5 + theSearchZTOB)) {
1325 fillAdcCounts(theMEBeam5TOBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1326 } else if ((theStripDet->surface().position().z() < -10.0 + theSearchZTOB) &&
1327 (theStripDet->surface().position().z() > -10.0 - theSearchZTOB)) {
1328 fillAdcCounts(theMEBeam5TOBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1329 } else if ((theStripDet->surface().position().z() < -46.0 + theSearchZTOB) &&
1330 (theStripDet->surface().position().z() > -46.0 - theSearchZTOB)) {
1331 fillAdcCounts(theMEBeam5TOBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1332 } else if ((theStripDet->surface().position().z() < -80.0 + theSearchZTOB) &&
1333 (theStripDet->surface().position().z() > -80.0 - theSearchZTOB)) {
1334 fillAdcCounts(theMEBeam5TOBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1335 }
1336 }
1337
1338
1339
1340 else if ((thePart == "TOB") && (theTOBLayer == 1) && (theBeam == 6) && (theTOBStereoDet == 0) &&
1341 (theStripDet->surface().position().perp() < 58.5)) {
1342 if ((theStripDet->surface().position().z() > 99.0 - theSearchZTOB) &&
1343 (theStripDet->surface().position().z() < 99.0 + theSearchZTOB)) {
1344 fillAdcCounts(theMEBeam6TOBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1345 } else if ((theStripDet->surface().position().z() > 64.0 - theSearchZTOB) &&
1346 (theStripDet->surface().position().z() < 64.0 + theSearchZTOB)) {
1347 fillAdcCounts(theMEBeam6TOBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1348 } else if ((theStripDet->surface().position().z() > 27.5 - theSearchZTOB) &&
1349 (theStripDet->surface().position().z() < 27.5 + theSearchZTOB)) {
1350 fillAdcCounts(theMEBeam6TOBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1351 } else if ((theStripDet->surface().position().z() < -10.0 + theSearchZTOB) &&
1352 (theStripDet->surface().position().z() > -10.0 - theSearchZTOB)) {
1353 fillAdcCounts(theMEBeam6TOBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1354 } else if ((theStripDet->surface().position().z() < -46.0 + theSearchZTOB) &&
1355 (theStripDet->surface().position().z() > -46.0 - theSearchZTOB)) {
1356 fillAdcCounts(theMEBeam6TOBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1357 } else if ((theStripDet->surface().position().z() < -80.0 + theSearchZTOB) &&
1358 (theStripDet->surface().position().z() > -80.0 - theSearchZTOB)) {
1359 fillAdcCounts(theMEBeam6TOBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1360 }
1361 }
1362
1363
1364
1365 else if ((thePart == "TOB") && (theTOBLayer == 1) && (theBeam == 7) && (theTOBStereoDet == 0) &&
1366 (theStripDet->surface().position().perp() < 58.5)) {
1367 if ((theStripDet->surface().position().z() > 99.0 - theSearchZTOB) &&
1368 (theStripDet->surface().position().z() < 99.0 + theSearchZTOB)) {
1369 fillAdcCounts(theMEBeam7TOBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1370 } else if ((theStripDet->surface().position().z() > 64.0 - theSearchZTOB) &&
1371 (theStripDet->surface().position().z() < 64.0 + theSearchZTOB)) {
1372 fillAdcCounts(theMEBeam7TOBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1373 } else if ((theStripDet->surface().position().z() > 27.5 - theSearchZTOB) &&
1374 (theStripDet->surface().position().z() < 27.5 + theSearchZTOB)) {
1375 fillAdcCounts(theMEBeam7TOBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1376 } else if ((theStripDet->surface().position().z() < -10.0 + theSearchZTOB) &&
1377 (theStripDet->surface().position().z() > -10.0 - theSearchZTOB)) {
1378 fillAdcCounts(theMEBeam7TOBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1379 } else if ((theStripDet->surface().position().z() < -46.0 + theSearchZTOB) &&
1380 (theStripDet->surface().position().z() > -46.0 - theSearchZTOB)) {
1381 fillAdcCounts(theMEBeam7TOBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1382 } else if ((theStripDet->surface().position().z() < -80.0 + theSearchZTOB) &&
1383 (theStripDet->surface().position().z() > -80.0 - theSearchZTOB)) {
1384 fillAdcCounts(theMEBeam7TOBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1385 }
1386 }
1387
1388
1389
1390
1391 else if ((thePart == "TIB") && (theTIBLayer == 4) && (theBeam == 0)) {
1392 if ((theStripDet->surface().position().z() > 60.5 - theSearchZTIB) &&
1393 (theStripDet->surface().position().z() < 60.5 + theSearchZTIB)) {
1394 fillAdcCounts(theMEBeam0TIBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1395 } else if ((theStripDet->surface().position().z() > 37.5 - theSearchZTIB) &&
1396 (theStripDet->surface().position().z() < 37.5 + theSearchZTIB)) {
1397 fillAdcCounts(theMEBeam0TIBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1398 } else if ((theStripDet->surface().position().z() > 15.0 - theSearchZTIB) &&
1399 (theStripDet->surface().position().z() < 15.0 + theSearchZTIB)) {
1400 fillAdcCounts(theMEBeam0TIBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1401 } else if ((theStripDet->surface().position().z() < -7.5 + theSearchZTIB) &&
1402 (theStripDet->surface().position().z() > -7.5 - theSearchZTIB)) {
1403 fillAdcCounts(theMEBeam0TIBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1404 } else if ((theStripDet->surface().position().z() < -30.5 + theSearchZTIB) &&
1405 (theStripDet->surface().position().z() > -30.5 - theSearchZTIB)) {
1406 fillAdcCounts(theMEBeam0TIBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1407 } else if ((theStripDet->surface().position().z() < -53.0 + theSearchZTIB) &&
1408 (theStripDet->surface().position().z() > -53.0 - theSearchZTIB)) {
1409 fillAdcCounts(theMEBeam0TIBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1410 }
1411 }
1412
1413
1414
1415 else if ((thePart == "TIB") && (theTIBLayer == 4) && (theBeam == 1)) {
1416 if ((theStripDet->surface().position().z() > 60.5 - theSearchZTIB) &&
1417 (theStripDet->surface().position().z() < 60.5 + theSearchZTIB)) {
1418 fillAdcCounts(theMEBeam1TIBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1419 } else if ((theStripDet->surface().position().z() > 37.5 - theSearchZTIB) &&
1420 (theStripDet->surface().position().z() < 37.5 + theSearchZTIB)) {
1421 fillAdcCounts(theMEBeam1TIBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1422 } else if ((theStripDet->surface().position().z() > 15.0 - theSearchZTIB) &&
1423 (theStripDet->surface().position().z() < 15.0 + theSearchZTIB)) {
1424 fillAdcCounts(theMEBeam1TIBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1425 } else if ((theStripDet->surface().position().z() < -7.5 + theSearchZTIB) &&
1426 (theStripDet->surface().position().z() > -7.5 - theSearchZTIB)) {
1427 fillAdcCounts(theMEBeam1TIBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1428 } else if ((theStripDet->surface().position().z() < -30.5 + theSearchZTIB) &&
1429 (theStripDet->surface().position().z() > -30.5 - theSearchZTIB)) {
1430 fillAdcCounts(theMEBeam1TIBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1431 } else if ((theStripDet->surface().position().z() < -53.0 + theSearchZTIB) &&
1432 (theStripDet->surface().position().z() > -53.0 - theSearchZTIB)) {
1433 fillAdcCounts(theMEBeam1TIBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1434 }
1435 }
1436
1437
1438
1439 else if ((thePart == "TIB") && (theTIBLayer == 4) && (theBeam == 2)) {
1440 if ((theStripDet->surface().position().z() > 60.5 - theSearchZTIB) &&
1441 (theStripDet->surface().position().z() < 60.5 + theSearchZTIB)) {
1442 fillAdcCounts(theMEBeam2TIBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1443 } else if ((theStripDet->surface().position().z() > 37.5 - theSearchZTIB) &&
1444 (theStripDet->surface().position().z() < 37.5 + theSearchZTIB)) {
1445 fillAdcCounts(theMEBeam2TIBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1446 } else if ((theStripDet->surface().position().z() > 15.0 - theSearchZTIB) &&
1447 (theStripDet->surface().position().z() < 15.0 + theSearchZTIB)) {
1448 fillAdcCounts(theMEBeam2TIBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1449 } else if ((theStripDet->surface().position().z() < -7.5 + theSearchZTIB) &&
1450 (theStripDet->surface().position().z() > -7.5 - theSearchZTIB)) {
1451 fillAdcCounts(theMEBeam2TIBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1452 } else if ((theStripDet->surface().position().z() < -30.5 + theSearchZTIB) &&
1453 (theStripDet->surface().position().z() > -30.5 - theSearchZTIB)) {
1454 fillAdcCounts(theMEBeam2TIBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1455 } else if ((theStripDet->surface().position().z() < -53.0 + theSearchZTIB) &&
1456 (theStripDet->surface().position().z() > -53.0 - theSearchZTIB)) {
1457 fillAdcCounts(theMEBeam2TIBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1458 }
1459 }
1460
1461
1462
1463 else if ((thePart == "TIB") && (theTIBLayer == 4) && (theBeam == 3)) {
1464 if ((theStripDet->surface().position().z() > 60.5 - theSearchZTIB) &&
1465 (theStripDet->surface().position().z() < 60.5 + theSearchZTIB)) {
1466 fillAdcCounts(theMEBeam3TIBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1467 } else if ((theStripDet->surface().position().z() > 37.5 - theSearchZTIB) &&
1468 (theStripDet->surface().position().z() < 37.5 + theSearchZTIB)) {
1469 fillAdcCounts(theMEBeam3TIBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1470 } else if ((theStripDet->surface().position().z() > 15.0 - theSearchZTIB) &&
1471 (theStripDet->surface().position().z() < 15.0 + theSearchZTIB)) {
1472 fillAdcCounts(theMEBeam3TIBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1473 } else if ((theStripDet->surface().position().z() < -7.5 + theSearchZTIB) &&
1474 (theStripDet->surface().position().z() > -7.5 - theSearchZTIB)) {
1475 fillAdcCounts(theMEBeam3TIBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1476 } else if ((theStripDet->surface().position().z() < -30.5 + theSearchZTIB) &&
1477 (theStripDet->surface().position().z() > -30.5 - theSearchZTIB)) {
1478 fillAdcCounts(theMEBeam3TIBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1479 } else if ((theStripDet->surface().position().z() < -53.0 + theSearchZTIB) &&
1480 (theStripDet->surface().position().z() > -53.0 - theSearchZTIB)) {
1481 fillAdcCounts(theMEBeam3TIBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1482 }
1483 }
1484
1485
1486
1487 else if ((thePart == "TIB") && (theTIBLayer == 4) && (theBeam == 4)) {
1488 if ((theStripDet->surface().position().z() > 60.5 - theSearchZTIB) &&
1489 (theStripDet->surface().position().z() < 60.5 + theSearchZTIB)) {
1490 fillAdcCounts(theMEBeam4TIBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1491 } else if ((theStripDet->surface().position().z() > 37.5 - theSearchZTIB) &&
1492 (theStripDet->surface().position().z() < 37.5 + theSearchZTIB)) {
1493 fillAdcCounts(theMEBeam4TIBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1494 } else if ((theStripDet->surface().position().z() > 15.0 - theSearchZTIB) &&
1495 (theStripDet->surface().position().z() < 15.0 + theSearchZTIB)) {
1496 fillAdcCounts(theMEBeam4TIBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1497 } else if ((theStripDet->surface().position().z() < -7.5 + theSearchZTIB) &&
1498 (theStripDet->surface().position().z() > -7.5 - theSearchZTIB)) {
1499 fillAdcCounts(theMEBeam4TIBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1500 } else if ((theStripDet->surface().position().z() < -30.5 + theSearchZTIB) &&
1501 (theStripDet->surface().position().z() > -30.5 - theSearchZTIB)) {
1502 fillAdcCounts(theMEBeam4TIBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1503 } else if ((theStripDet->surface().position().z() < -53.0 + theSearchZTIB) &&
1504 (theStripDet->surface().position().z() > -53.0 - theSearchZTIB)) {
1505 fillAdcCounts(theMEBeam4TIBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1506 }
1507 }
1508
1509
1510
1511 else if ((thePart == "TIB") && (theTIBLayer == 4) && (theBeam == 5)) {
1512 if ((theStripDet->surface().position().z() > 60.5 - theSearchZTIB) &&
1513 (theStripDet->surface().position().z() < 60.5 + theSearchZTIB)) {
1514 fillAdcCounts(theMEBeam5TIBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1515 } else if ((theStripDet->surface().position().z() > 37.5 - theSearchZTIB) &&
1516 (theStripDet->surface().position().z() < 37.5 + theSearchZTIB)) {
1517 fillAdcCounts(theMEBeam5TIBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1518 } else if ((theStripDet->surface().position().z() > 15.0 - theSearchZTIB) &&
1519 (theStripDet->surface().position().z() < 15.0 + theSearchZTIB)) {
1520 fillAdcCounts(theMEBeam5TIBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1521 } else if ((theStripDet->surface().position().z() < -7.5 + theSearchZTIB) &&
1522 (theStripDet->surface().position().z() > -7.5 - theSearchZTIB)) {
1523 fillAdcCounts(theMEBeam5TIBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1524 } else if ((theStripDet->surface().position().z() < -30.5 + theSearchZTIB) &&
1525 (theStripDet->surface().position().z() > -30.5 - theSearchZTIB)) {
1526 fillAdcCounts(theMEBeam5TIBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1527 } else if ((theStripDet->surface().position().z() < -53.0 + theSearchZTIB) &&
1528 (theStripDet->surface().position().z() > -53.0 - theSearchZTIB)) {
1529 fillAdcCounts(theMEBeam5TIBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1530 }
1531 }
1532
1533
1534
1535 else if ((thePart == "TIB") && (theTIBLayer == 4) && (theBeam == 6)) {
1536 if ((theStripDet->surface().position().z() > 60.5 - theSearchZTIB) &&
1537 (theStripDet->surface().position().z() < 60.5 + theSearchZTIB)) {
1538 fillAdcCounts(theMEBeam6TIBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1539 } else if ((theStripDet->surface().position().z() > 37.5 - theSearchZTIB) &&
1540 (theStripDet->surface().position().z() < 37.5 + theSearchZTIB)) {
1541 fillAdcCounts(theMEBeam6TIBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1542 } else if ((theStripDet->surface().position().z() > 15.0 - theSearchZTIB) &&
1543 (theStripDet->surface().position().z() < 15.0 + theSearchZTIB)) {
1544 fillAdcCounts(theMEBeam6TIBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1545 } else if ((theStripDet->surface().position().z() < -7.5 + theSearchZTIB) &&
1546 (theStripDet->surface().position().z() > -7.5 - theSearchZTIB)) {
1547 fillAdcCounts(theMEBeam6TIBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1548 } else if ((theStripDet->surface().position().z() < -30.5 + theSearchZTIB) &&
1549 (theStripDet->surface().position().z() > -30.5 - theSearchZTIB)) {
1550 fillAdcCounts(theMEBeam6TIBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1551 } else if ((theStripDet->surface().position().z() < -53.0 + theSearchZTIB) &&
1552 (theStripDet->surface().position().z() > -53.0 - theSearchZTIB)) {
1553 fillAdcCounts(theMEBeam6TIBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1554 }
1555 }
1556
1557
1558
1559 else if ((thePart == "TIB") && (theTIBLayer == 4) && (theBeam == 7)) {
1560 if ((theStripDet->surface().position().z() > 60.5 - theSearchZTIB) &&
1561 (theStripDet->surface().position().z() < 60.5 + theSearchZTIB)) {
1562 fillAdcCounts(theMEBeam7TIBPosition1AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1563 } else if ((theStripDet->surface().position().z() > 37.5 - theSearchZTIB) &&
1564 (theStripDet->surface().position().z() < 37.5 + theSearchZTIB)) {
1565 fillAdcCounts(theMEBeam7TIBPosition2AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1566 } else if ((theStripDet->surface().position().z() > 15.0 - theSearchZTIB) &&
1567 (theStripDet->surface().position().z() < 15.0 + theSearchZTIB)) {
1568 fillAdcCounts(theMEBeam7TIBPosition3AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1569 } else if ((theStripDet->surface().position().z() < -7.5 + theSearchZTIB) &&
1570 (theStripDet->surface().position().z() > -7.5 - theSearchZTIB)) {
1571 fillAdcCounts(theMEBeam7TIBPosition4AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1572 } else if ((theStripDet->surface().position().z() < -30.5 + theSearchZTIB) &&
1573 (theStripDet->surface().position().z() > -30.5 - theSearchZTIB)) {
1574 fillAdcCounts(theMEBeam7TIBPosition5AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1575 } else if ((theStripDet->surface().position().z() < -53.0 + theSearchZTIB) &&
1576 (theStripDet->surface().position().z() > -53.0 - theSearchZTIB)) {
1577 fillAdcCounts(theMEBeam7TIBPosition6AdcCounts, theDigiRangeIterator, theDigiRangeIteratorEnd);
1578 }
1579 }
1580
1581 }
1582 }
1583 }