8 : nAFEBs_(
header.nLCTChipRead()), nTimeBins_(
header.NTBins()) {
16 : nAFEBs_(
header.nLCTChipRead()), nTimeBins_(
header.NTBins()) {
27 static const unsigned short int layerParts[7] = {3, 3, 4, 6, 6, 8, 10};
28 static const unsigned short int wireGroups[7] = {32, 32, 48, 64, 64, 96, 112};
31 layerParts[
header.alctHeader2007().boardType];
37 std::vector<CSCWireDigi> digis;
38 uint32_t tbinbits = 0;
39 uint32_t wireGroup = 0;
41 for (
int layerPart = 0; layerPart <
layerParts_; ++layerPart) {
46 for (
int tbin = 0; tbin <
nTimeBins_; ++tbin) {
48 if (
frame.data() != 0) {
50 tbinbits = tbinbits + (1 << tbin);
55 wireGroup = (layerPart * 12 +
j) + 1;
58 wireGroup = wireGroup | (wireGroupBX << 16);
60 LogTrace(
"CSCAnodeData|CSCRawToDigi") <<
"Layer " << layer <<
" " << digi;
61 digis.push_back(digi);
86 unsigned layerPart = (wireGroup - 1) / 12;
87 unsigned wireInPart = (wireGroup - 1) % 12;
90 for (std::vector<int>::const_iterator timeBinOn = timeBinsOn.begin(); timeBinOn != timeBinsOn.end(); ++timeBinOn) {
95 edm::LogError(
"CSCAnodeData|CSCRawToDigi") <<
"Bad Wire Number for this digi.";
99 if ((*timeBinOn) >= 0 && (*timeBinOn) <
nTimeBins_) {
101 frame.addHit(wireInPart);
105 LogTrace(
"CSCAnodeData|CSCRawToDigi")
106 <<
"warning: not saving anode data in bx " << *timeBinOn <<
": out of range ";
117 anodeData.
add(wireDigi, 1);
118 anodeData.
add(wireDigi, 6);
120 std::vector<CSCWireDigi> wires1 = anodeData.
wireDigis(1);
121 std::vector<CSCWireDigi> wires6 = anodeData.
wireDigis(6);
123 assert(wires1.size() == 1);
124 assert(wires6.size() == 1);
125 assert(wires1[0].getWireGroup() == wireGroup);
126 assert(wires6[0].getWireGroup() == wireGroup);
127 assert(wires1[0].getTimeBin() == timeBin);
128 assert(wires6[0].getTimeBin() == timeBin);