Skip to content

Commit

Permalink
code cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
jshlee committed Oct 22, 2020
1 parent 7433f4c commit 78a7536
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 11 deletions.
2 changes: 1 addition & 1 deletion CondFormats/GEMObjects/interface/GEMROMapping.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
class GEMROMapping {
public:
struct chamEC {
int fedId;
unsigned int fedId;
uint8_t amcNum;
uint8_t gebId;
bool operator<(const chamEC& r) const {
Expand Down
8 changes: 3 additions & 5 deletions CondFormats/GEMObjects/interface/GEMeMap.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ class GEMeMap {
void convertDummy(GEMROMapping& romap);

struct GEMChamberMap {
std::vector<int> fedId;
std::vector<unsigned int> fedId;
std::vector<uint8_t> amcNum;
std::vector<uint8_t> gebId;
std::vector<int> gemNum;
Expand Down Expand Up @@ -59,11 +59,9 @@ class GEMeMap {
static const int vfatVerV3_ = 3; // VFAT v3
static const int vfatTypeV3_ = 11; // VFAT v3
static const int chipIdMask_ = 0xfff; // chipId mask for 12 bits
static const int maxAMCs_ = 15; // 4 bits for AMC no.
static const int maxGEBs_ = 32; // 5 bits for GEB id
static const int maxGEB0_ = 30; // Not known yet for ME0
static const int maxGEB1_ = 12; // 12 for GE11
static const int maxVFatGE0_ = 3; // vFat per eta partition, not known yet for ME0
static const int maxAMCs_ = 15; // 4 bits for AMC no.
static const int maxVFatGE0_ = 12; // vFat per eta partition, not known yet for ME0
static const int maxVFatGE11_ = 3; // vFat per eta partition in GE11
static const int maxVFatGE21_ = 6; // vFat per eta partition in GE21
static const int maxChan_ = 128; // channels per vFat
Expand Down
2 changes: 1 addition & 1 deletion DataFormats/GEMDigi/interface/AMCdata.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ namespace gem {
uint8_t amcNum() const { return AMCheader1{amch1_}.AMCnum; }

uint16_t boardId() const { return AMCheader2{amch2_}.boardID; }
int16_t orbitNum() const { return AMCheader2{amch2_}.orbitNum; }
uint16_t orbitNum() const { return AMCheader2{amch2_}.orbitNum; }
uint8_t param3() const { return AMCheader2{amch2_}.param3; }
uint8_t param2() const { return AMCheader2{amch2_}.param2; }
uint8_t param1() const { return AMCheader2{amch2_}.param1; }
Expand Down
2 changes: 1 addition & 1 deletion EventFilter/GEMRawToDigi/plugins/GEMDigiToRawModule.cc
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ void GEMDigiToRawModule::produce(edm::StreamID iID, edm::Event& iEvent, edm::Eve
}
}

for (int fedId = FEDNumbering::MINGEMFEDID; fedId <= FEDNumbering::MAXME0FEDID; ++fedId) {
for (unsigned int fedId = FEDNumbering::MINGEMFEDID; fedId <= FEDNumbering::MAXME0FEDID; ++fedId) {
uint32_t amc13EvtLength = 0;
std::unique_ptr<AMC13Event> amc13Event = std::make_unique<AMC13Event>();

Expand Down
2 changes: 1 addition & 1 deletion EventFilter/GEMRawToDigi/plugins/GEMRawToDigiModule.cc
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ void GEMRawToDigiModule::produce(edm::StreamID iID, edm::Event& iEvent, edm::Eve

auto gemROMap = runCache(iEvent.getRun().index());

for (int fedId = FEDNumbering::MINGEMFEDID; fedId <= FEDNumbering::MAXGEMFEDID; ++fedId) {
for (unsigned int fedId = FEDNumbering::MINGEMFEDID; fedId <= FEDNumbering::MAXGEMFEDID; ++fedId) {
const FEDRawData& fedData = fed_buffers->FEDData(fedId);

int nWords = fedData.size() / sizeof(uint64_t);
Expand Down
2 changes: 0 additions & 2 deletions EventFilter/GEMRawToDigi/src/GEMRawToDigi.cc
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
*/
#include "EventFilter/GEMRawToDigi/interface/GEMRawToDigi.h"
#include "FWCore/MessageLogger/interface/MessageLogger.h"
// temp
#include <iostream>
using namespace gem;

std::unique_ptr<AMC13Event> GEMRawToDigi::convertWordToAMC13Event(const uint64_t* word) {
Expand Down

0 comments on commit 78a7536

Please sign in to comment.