641 int hocrate_loc[
NHOCR]={3,7,6,13};
644 int fedhonum_loc[
NHOCR][2]={{724,725},{726,727},{728,729},{730,731}};
647 int ihslotho_loc[
NHSETSHO][
NHTRSHO]={{2,3,4,5},{6,7,13,14},{15,16,17,18}};
650 int ihophis_loc[
NHOCR]={71,17,35,53};
656 int HO_RM_table_loc[24][16][2] =
658 {{2,2},{2,2},{2,2},{2,2},{2,2},{2,2},{2,2},{2,2},{2,2},{2,2},{4,2},{4,2},{4,2},{4,2},{4,2},{4,2}},
659 {{2,2},{2,2},{2,2},{2,2},{4,4},{4,4},{4,4},{4,4},{4,4},{4,4},{2,4},{2,4},{2,4},{2,4},{2,4},{2,4}},
660 {{3,3},{3,3},{3,3},{3,3},{4,4},{4,4},{4,4},{4,4},{4,4},{4,4},{2,4},{2,4},{2,4},{2,4},{2,4},{2,4}},
661 {{3,3},{3,3},{3,3},{3,3},{4,4},{4,4},{4,4},{4,4},{4,4},{4,4},{2,4},{2,4},{2,4},{2,4},{2,4},{2,4}},
662 {{4,4},{4,4},{4,4},{4,4},{3,3},{3,3},{3,3},{3,3},{3,3},{3,3},{1,3},{1,3},{1,3},{1,3},{1,3},{1,3}},
663 {{4,4},{4,4},{4,4},{4,4},{3,3},{3,3},{3,3},{3,3},{3,3},{3,3},{1,3},{1,3},{1,3},{1,3},{1,3},{1,3}},
664 {{3,3},{3,3},{3,3},{3,3},{3,3},{3,3},{3,3},{3,3},{3,3},{3,3},{1,3},{1,3},{1,3},{1,3},{1,3},{1,3}},
665 {{3,3},{3,3},{3,3},{3,3},{1,1},{1,1},{1,1},{1,1},{1,1},{1,1},{3,1},{3,1},{3,1},{3,1},{3,1},{3,1}},
666 {{2,2},{2,2},{2,2},{2,2},{1,1},{1,1},{1,1},{1,1},{1,1},{1,1},{3,1},{3,1},{3,1},{3,1},{3,1},{3,1}},
667 {{2,2},{2,2},{2,2},{2,2},{1,1},{1,1},{1,1},{1,1},{1,1},{1,1},{3,1},{3,1},{3,1},{3,1},{3,1},{3,1}},
668 {{4,4},{4,4},{4,4},{4,4},{2,2},{2,2},{2,2},{2,2},{2,2},{2,2},{4,2},{4,2},{4,2},{4,2},{4,2},{4,2}},
669 {{4,4},{4,4},{4,4},{4,4},{2,2},{2,2},{2,2},{2,2},{2,2},{2,2},{4,2},{4,2},{4,2},{4,2},{4,2},{4,2}},
670 {{3,3},{3,3},{3,3},{3,3},{2,2},{2,2},{2,2},{2,2},{2,2},{2,2},{4,2},{4,2},{4,2},{4,2},{4,2},{4,2}},
671 {{3,3},{3,3},{3,3},{3,3},{4,4},{4,4},{4,4},{4,4},{4,4},{4,4},{2,4},{2,4},{2,4},{2,4},{2,4},{2,4}},
672 {{2,2},{2,2},{2,2},{2,2},{4,4},{4,4},{4,4},{4,4},{4,4},{4,4},{2,4},{2,4},{2,4},{2,4},{2,4},{2,4}},
673 {{2,2},{2,2},{2,2},{2,2},{4,4},{4,4},{4,4},{4,4},{4,4},{4,4},{2,4},{2,4},{2,4},{2,4},{2,4},{2,4}},
674 {{1,1},{1,1},{1,1},{1,1},{3,3},{3,3},{3,3},{3,3},{3,3},{3,3},{1,3},{1,3},{1,3},{1,3},{1,3},{1,3}},
675 {{1,1},{1,1},{1,1},{1,1},{3,3},{3,3},{3,3},{3,3},{3,3},{3,3},{1,3},{1,3},{1,3},{1,3},{1,3},{1,3}},
676 {{2,2},{2,2},{2,2},{2,2},{3,3},{3,3},{3,3},{3,3},{3,3},{3,3},{1,3},{1,3},{1,3},{1,3},{1,3},{1,3}},
677 {{2,2},{2,2},{2,2},{2,2},{1,1},{1,1},{1,1},{1,1},{1,1},{1,1},{3,1},{3,1},{3,1},{3,1},{3,1},{3,1}},
678 {{3,3},{3,3},{3,3},{3,3},{1,1},{1,1},{1,1},{1,1},{1,1},{1,1},{3,1},{3,1},{3,1},{3,1},{3,1},{3,1}},
679 {{3,3},{3,3},{3,3},{3,3},{1,1},{1,1},{1,1},{1,1},{1,1},{1,1},{3,1},{3,1},{3,1},{3,1},{3,1},{3,1}},
680 {{1,1},{1,1},{1,1},{1,1},{2,2},{2,2},{2,2},{2,2},{2,2},{2,2},{4,2},{4,2},{4,2},{4,2},{4,2},{4,2}},
681 {{1,1},{1,1},{1,1},{1,1},{2,2},{2,2},{2,2},{2,2},{2,2},{2,2},{4,2},{4,2},{4,2},{4,2},{4,2},{4,2}}
683 memcpy(
HO_RM_table, HO_RM_table_loc,
sizeof(
int)*24*16*2 );
686 int HO_RM_fi_eta5to15_loc[11] = {3, 2, 5, 4, 7, 6, 3, 2, 5, 4, 7};
702 int HO_RM_fi_eta1to4_loc[24][2][2] =
704 {{7,3},{4,5}},{{6,2},{4,5}},{{7,3},{4,5}},{{6,2},{4,5}},{{2,6},{5,4}},{{3,7},{5,4}},{{2,6},{5,4}},{{3,7},{5,4}},
705 {{2,6},{5,4}},{{3,7},{5,4}},{{2,6},{5,4}},{{3,7},{5,4}},{{2,6},{5,4}},{{3,7},{5,4}},{{2,6},{5,4}},{{3,7},{5,4}},
706 {{7,3},{4,5}},{{6,2},{4,5}},{{7,3},{4,5}},{{6,2},{4,5}},{{7,3},{4,5}},{{6,2},{4,5}},{{7,3},{4,5}},{{6,2},{4,5}}
719 int HO_RM_fi_eta1to4_sipm_loc[24][4][2] =
721 {{5,3},{5,5},{7,3},{6,3}}, {{4,2},{7,4},{7,2},{6,2}}, {{5,3},{5,5},{7,3},{6,3}}, {{4,2},{7,4},{7,2},{6,2}},
722 {{2,4},{4,7},{2,7},{2,6}}, {{3,5},{5,5},{3,7},{3,6}}, {{2,4},{4,7},{2,7},{2,6}}, {{3,5},{5,5},{3,7},{3,6}},
723 {{2,4},{4,7},{2,7},{2,6}}, {{3,5},{5,5},{3,7},{3,6}}, {{2,4},{4,7},{2,7},{2,6}}, {{3,5},{5,5},{3,7},{3,6}},
724 {{2,4},{4,7},{2,7},{2,6}}, {{3,5},{5,5},{3,7},{3,6}}, {{2,4},{4,7},{2,7},{2,6}}, {{3,5},{5,5},{3,7},{3,6}},
725 {{5,3},{5,5},{7,3},{6,3}}, {{4,2},{7,4},{7,2},{6,2}}, {{5,3},{5,5},{7,3},{6,3}}, {{4,2},{7,4},{7,2},{6,2}},
726 {{5,3},{5,5},{7,3},{6,3}}, {{4,2},{7,4},{7,2},{6,2}}, {{5,3},{5,5},{7,3},{6,3}}, {{4,2},{7,4},{7,2},{6,2}},
731 int HO_htr_fi_450eta5to15_loc[2][11] = {{2, 2, 4, 6, 8, 2, 4, 6, 8, 4, 6},
732 {2, 8, 6, 4, 2, 8, 6, 4, 2, 4, 2}};
736 int HO_htr_fi_450eta16M_loc[4] = {7, 7, 8, 8};
740 int HO_htr_fi_450eta16P_loc[4][6] = { {4,2,4,4,2,6},{2,6,6,2,6,4},{5,3,5,5,3,7},{3,7,7,3,7,5} };
744 int HO_htr_fi_eta4_loc[2][6] = {{6, 6, 8, 8, 7, 7},
749 int HO_htr_fi_eta123_loc[2][6] = {{6, 5, 4, 3, 8, 7},
762 int HO_htr_fi_eta1234_sipm[6][5][2][2] = {
764 {{4,8},{6,4}}, {{4,4},{4,7}}, {{6,8},{6,7}}, {{5,8},{6,8}}, {{5,6},{-1,-1}} },
766 {{6,7},{5,6}}, {{6,6},{6,6}}, {{6,7},{5,7}}, {{5,7},{5,8}}, {{-1,-1},{4,8}} },
768 {{4,5},{5,6}}, {{5,5},{5,5}}, {{4,5},{4,6}}, {{4,6},{3,6}}, {{-1,-1},{3,8}} },
770 {{3,8},{8,5}}, {{8,8},{4,8}}, {{3,5},{4,5}}, {{3,6},{3,5}}, {{5,6},{-1,-1}} },
772 {{3,2},{8,3}}, {{3,3},{3,1}}, {{8,2},{8,1}}, {{7,2},{8,2}}, {{7,7},{-1,-1}} },
774 {{7,1},{7,7}}, {{8,7},{7,7}}, {{8,1},{7,1}}, {{7,1},{7,2}}, {{-1,-1},{3,2}} },
782 int ipixelHO_loc[
NRMFIBR][
NFCH][2] = {{{12,12},{ 7, 7},{ 6, 3}},
783 {{ 4, 4},{ 8, 8},{ 5, 1}},
784 {{19,11},{18, 6},{17, 2}},
785 {{ 2, 9},{ 1,13},{ 3, 5}},
786 {{11,19},{16,18},{15,17}},
787 {{13,15},{ 9,14},{14,16}}};
789 int ipixelHO_sipm[
NRMFIBR][
NFCH][2] = {{{12,12},{ 7, 7},{ 3, 3}},
790 {{ 4, 4},{ 8, 8},{ 1, 1}},
791 {{11,11},{ 6, 6},{ 2, 2}},
792 {{ 9, 9},{13,13},{ 5, 5}},
793 {{19,19},{18,18},{17,17}},
794 {{15,15},{14,14},{16,16}}};
802 {{
"Q",
"M"},{
"N",
"T"},{
"P",
"F"}},
803 {{
"A",
"C"},{
"X",
"J"},{
"J",
"Q"}},
804 {{
"X",
"K"},{
"R",
"R"},{
"H",
"D"}},
805 {{
"D",
"A"},{
"C",
"G"},{
"B",
"N"}},
806 {{
"L",
"H"},{
"M",
"P"},{
"K",
"B"}}};
809 {{
"Q",
"M"},{
"N",
"T"},{
"R",
"F"}},
810 {{
"D",
"C"},{
"F",
"J"},{
"X",
"Q"}},
811 {{
"M",
"K"},{
"L",
"R"},{
"P",
"D"}},
812 {{
"A",
"A"},{
"X",
"G"},{
"J",
"N"}},
813 {{
"B",
"H"},{
"K",
"P"},{
"C",
"B"}}};
817 for (
int ll = 0; ll < 2; ll++) {
841 int rmspecialeta_loc[6][6] = {
842 { 14, 15, 14, 13, 12, 11 },
843 { 14, 15, 14, 13, 12, 11 },
844 { 10, 9, 8, 7, 6, 5 },
845 { 10, 9, 8, 7, 6, 5 },
846 { 14, 15, 14, 13, 12, 11 },
847 { 14, 15, 14, 13, 12, 11 }
851 {
"X",
"B",
"C",
"D",
"E",
"F" },
852 {
"X",
"P",
"Q",
"R",
"S",
"T" },
853 {
"G",
"H",
"J",
"K",
"L",
"M" },
854 {
"A",
"B",
"C",
"D",
"E",
"F" },
855 {
"X",
"B",
"C",
"D",
"E",
"F" },
856 {
"X",
"P",
"Q",
"R",
"S",
"T" }
860 {
"HOX",
"HO",
"HO",
"HO",
"HO",
"HO" },
861 {
"HOX",
"HO",
"HO",
"HO",
"HO",
"HO" },
862 {
"HO",
"HO",
"HO",
"HO",
"HO",
"HO" },
863 {
"HO",
"HO",
"HO",
"HO",
"HO",
"HO" },
864 {
"HOX",
"HO",
"HO",
"HO",
"HO",
"HO" },
865 {
"HOX",
"HO",
"HO",
"HO",
"HO",
"HO" }
868 memcpy(
rmspecialeta, rmspecialeta_loc,
sizeof(
int)*6*6 );
871 for (
int jj = 0;
jj < 6;
jj++) {
872 for (
int kk = 0;
kk < 6;
kk++) {
875 for (
int jj = 0;
jj < 6;
jj++) {
876 for (
int kk = 0;
kk < 6;
kk++) {
881 int rmspecialeta_loc[6][6] = {
882 { 11, 12, 13, 14, 15, 15 },
883 { 11, 12, 13, 14, 15, 15 },
884 { 5, 6, 7, 8, 9, 10 },
885 { 5, 6, 7, 8, 9, 10 },
886 { 14, 15, 14, 13, 12, 11 },
887 { 11, 12, 13, 14, 15, 15 }
891 {
"F",
"E",
"D",
"C",
"B",
"X" },
892 {
"T",
"S",
"R",
"Q",
"P",
"X" },
893 {
"M",
"L",
"K",
"J",
"H",
"G" },
894 {
"F",
"E",
"D",
"C",
"B",
"A" },
895 {
"X",
"B",
"C",
"D",
"E",
"F" },
896 {
"T",
"S",
"R",
"Q",
"P",
"X" }
900 {
"HO",
"HO",
"HO",
"HO",
"HO",
"HOX" },
901 {
"HO",
"HO",
"HO",
"HO",
"HO",
"HOX" },
902 {
"HO",
"HO",
"HO",
"HO",
"HO",
"HO" },
903 {
"HO",
"HO",
"HO",
"HO",
"HO",
"HO" },
904 {
"HOX",
"HO",
"HO",
"HO",
"HO",
"HO" },
905 {
"HO",
"HO",
"HO",
"HO",
"HO",
"HOX" }
908 memcpy(
rmspecialeta, rmspecialeta_loc,
sizeof(
int)*6*6 );
911 for (
int jj = 0;
jj < 6;
jj++) {
912 for (
int kk = 0;
kk < 6;
kk++) {
915 for (
int jj = 0;
jj < 6;
jj++) {
916 for (
int kk = 0;
kk < 6;
kk++) {
921 int rmspecialeta_loc[6][6] = {
922 { 11, 12, 13, 14, 15, 15 },
923 { 11, 12, 13, 14, 15, 15 },
924 { 5, 6, 7, 8, 9, 10 },
925 { 5, 6, 7, 8, 9, 10 },
926 { 11, 12, 13, 14, 15, 15 },
927 { 11, 12, 13, 14, 15, 15 }
931 {
"F",
"E",
"D",
"C",
"B",
"X" },
932 {
"T",
"S",
"R",
"Q",
"P",
"X" },
933 {
"M",
"L",
"K",
"J",
"H",
"G" },
934 {
"F",
"E",
"D",
"C",
"B",
"A" },
935 {
"F",
"E",
"D",
"C",
"B",
"X" },
936 {
"T",
"S",
"R",
"Q",
"P",
"X" }
940 {
"HO",
"HO",
"HO",
"HO",
"HO",
"HOX" },
941 {
"HO",
"HO",
"HO",
"HO",
"HO",
"HOX" },
942 {
"HO",
"HO",
"HO",
"HO",
"HO",
"HO" },
943 {
"HO",
"HO",
"HO",
"HO",
"HO",
"HO" },
944 {
"HO",
"HO",
"HO",
"HO",
"HO",
"HOX" },
945 {
"HO",
"HO",
"HO",
"HO",
"HO",
"HOX" }
948 memcpy(
rmspecialeta, rmspecialeta_loc,
sizeof(
int)*6*6 );
951 for (
int jj = 0;
jj < 6;
jj++) {
952 for (
int kk = 0;
kk < 6;
kk++) {
955 for (
int jj = 0;
jj < 6;
jj++) {
956 for (
int kk = 0;
kk < 6;
kk++) {
962 char tempbuff[30]{0};
965 stringstream mystream;
994 if (
ieta <= 3 && (iside < 0 || phmod6 >= 4))
fpga =
"bot";
995 else if (ieta <= 3 && iside > 0 &&
phmod6 < 4)
fpga =
"top";
1001 else if (ieta < 10 && ieta >= 6 &&
iside > 0)
fpga =
"bot";
1005 else if ((ieta < 10 && ieta >= 6) &&
iside < 0)
fpga =
"top";
1006 else edm::LogInfo(
"HcalLogicalMapGenerator") <<
"Bad fpga code"<<endl;
1041 else if (
ieta <= 4) {
1099 else if (
ieta == 1){
1173 if (ieta <= 4 && mapIOV_ >= 5) {
1201 else if (ieta <= 13 && ieta >= 6 &&
iside == 1)
ih = 1;
1202 else if (ieta <= 13 && ieta >= 6 &&
iside == -1)
ih = 3;
1209 int php2mod18 = (
iph+2)%18;
1210 int php2mod18ov6 = php2mod18/6;
1215 if (
iphi % 18 == 17 ||
iphi % 18 <= 4)
is = 0;
1216 else if (
iphi % 18 >= 5 &&
iphi % 18 <= 10)
is = 1;
1227 if (mytype == 1 || mytype == 2)
1264 if (
ring == 0) snprintf (tempbuff,
sizeof tempbuff,
"%s%i%2.2d",
det.c_str(),
ring,
sector);
1267 rbx = mystream.str();
1295 else if ( iphi == 67 ) {
1301 else if (
iside == -1) {
1308 else if ( iphi == 65 ) {
1314 else if (
ring == 2 ) {
1320 else if ( iphi == 31 ) {
1334 HOHXEntries.push_back(hoxlmapentry);
1338 unsigned int denseId;
1341 HoHash2Entry.at(denseId)=HOHXEntries.size();
1344 HxCalibHash2Entry.at(denseId)=HOHXEntries.size();
1378 HOHXEntries.push_back(hoxlmapentry);
1382 unsigned int denseId;
1385 HoHash2Entry.at(denseId)=HOHXEntries.size();
1388 HxCalibHash2Entry.at(denseId)=HOHXEntries.size();
1424 HOHXEntries.push_back(hoxlmapentry);
1428 unsigned int denseId;
1431 HoHash2Entry.at(denseId)=HOHXEntries.size();
1434 HxCalibHash2Entry.at(denseId)=HOHXEntries.size();
std::string rmspeciallet_code[6][6]
static const int NHSETSHO
int ihslotho[NHSETSHO][NHTRSHO]
int ipixelHO[NRMFIBR][NFCH][2]
static uint32_t makeEntryNumber(bool, int, int)
int HO_htr_fi_450eta16M[4]
int HO_RM_fi_eta1to4[24][2][2]
int HO_RM_fi_eta5to15[11]
int HO_RM_table[24][16][2]
int HO_RM_fi_eta1to4_sipm[24][4][2]
int HO_htr_fi_450eta5to15[2][11]
int HO_htr_fi_eta123[2][6]
unsigned int detId2denseIdHO(const DetId &id) const
return a linear packed id from HO
std::string rmspecialdet[6][6]
unsigned int detId2denseIdCALIB(const DetId &id) const
return a linear packed id from CALIB
int HO_htr_fi_450eta16P[4][6]
std::string letterHO[NRMFIBR][NFCH][2]