CondFormats
RPCObjects
src
L1RPCHwConfig.cc
Go to the documentation of this file.
1
// -*- C++ -*-
2
//
3
// Package: RPCObjects
4
// Class : L1RPCHwConfig
5
//
6
// Implementation:
7
// <Notes on implementation>
8
//
9
// Original Author:
10
// Created: Wed Apr 9 13:48:10 CEST 2008
11
// $Id$
12
//
13
14
// system include files
15
16
// user include files
17
#include "
CondFormats/RPCObjects/interface/L1RPCHwConfig.h
"
18
19
#include <iostream>
20
//
21
// constants, enums and typedefs
22
//
23
24
//
25
// static data member definitions
26
//
27
28
//
29
// constructors and destructor
30
//
31
L1RPCHwConfig::L1RPCHwConfig
() {}
32
33
// L1RPCHwConfig::L1RPCHwConfig(const L1RPCHwConfig& rhs)
34
// {
35
// // do actual copying here;
36
// }
37
38
L1RPCHwConfig::~L1RPCHwConfig
() {}
39
40
void
L1RPCHwConfig::enablePAC
(
int
tower
,
int
sector,
int
segment,
bool
enable
) {
41
if
(
enable
) {
42
// std::cout << "+";
43
m_disabledDevices
.erase(
L1RPCDevCoords
(
tower
, sector, segment));
44
}
else
{
45
// std::cout << "-";
46
m_disabledDevices
.insert(
L1RPCDevCoords
(
tower
, sector, segment));
47
}
48
}
49
50
void
L1RPCHwConfig::enableTower
(
int
tower
,
bool
enable
) {
51
for
(
int
sec
= 0;
sec
< 12; ++
sec
) {
52
for
(
int
seg = 0; seg < 12; ++seg) {
53
enablePAC
(
tower
,
sec
, seg,
enable
);
54
}
55
}
56
}
57
58
void
L1RPCHwConfig::enableTowerInCrate
(
int
tower
,
int
crate,
bool
enable
) {
59
for
(
int
seg = 0; seg < 12; ++seg) {
60
enablePAC
(
tower
, crate, seg,
enable
);
61
}
62
}
63
64
void
L1RPCHwConfig::enableCrate
(
int
crate,
bool
enable
) {
65
for
(
int
tower
= -16;
tower
< 17; ++
tower
) {
66
for
(
int
seg = 0; seg < 12; ++seg) {
67
enablePAC
(
tower
, crate, seg,
enable
);
68
}
69
}
70
}
71
72
void
L1RPCHwConfig::enableAll
(
bool
enable
) {
73
for
(
int
seg = 0; seg < 12; ++seg) {
74
// std::cout << seg << " ";
75
enableCrate
(seg,
enable
);
76
// std::cout << std::endl;
77
}
78
}
remoteMonitoring_LED_IterMethod_cfg.enable
enable
Definition:
remoteMonitoring_LED_IterMethod_cfg.py:423
hgcalTowerProducer_cfi.tower
tower
Definition:
hgcalTowerProducer_cfi.py:4
L1RPCHwConfig::enableTower
void enableTower(int tower, bool enable)
Definition:
L1RPCHwConfig.cc:50
L1RPCHwConfig::L1RPCHwConfig
L1RPCHwConfig()
Definition:
L1RPCHwConfig.cc:31
L1RPCHwConfig::enableAll
void enableAll(bool enable)
Definition:
L1RPCHwConfig.cc:72
L1RPCHwConfig::~L1RPCHwConfig
virtual ~L1RPCHwConfig()
Definition:
L1RPCHwConfig.cc:38
L1RPCHwConfig.h
L1RPCDevCoords
Definition:
L1RPCHwConfig.h:35
fileinputsource_cfi.sec
sec
Definition:
fileinputsource_cfi.py:87
L1RPCHwConfig::enablePAC
void enablePAC(int tower, int sector, int segment, bool enable)
Definition:
L1RPCHwConfig.cc:40
L1RPCHwConfig::m_disabledDevices
std::set< L1RPCDevCoords > m_disabledDevices
Definition:
L1RPCHwConfig.h:93
L1RPCHwConfig::enableTowerInCrate
void enableTowerInCrate(int tower, int crate, bool enable)
Definition:
L1RPCHwConfig.cc:58
L1RPCHwConfig::enableCrate
void enableCrate(int logSector, bool enable)
Definition:
L1RPCHwConfig.cc:64
Generated for CMSSW Reference Manual by
1.8.16