|
|
Go to the documentation of this file.
22 std::string mthn =
"[PixelROCMaskBits::setROCMaskBits()]\t\t\t ";
26 for (
unsigned int i = 0;
i < bits.size();
i++) {
27 bits_[
i] = static_cast<unsigned char>(cpt[
i]);
50 for (
int i = 0;
i < 52;
i++) {
61 unsigned char byte = 0;
63 for (
int j = 0;
j < 80;
j++) {
67 if ((
j + 1) % 8 == 0) {
69 bits_[
i * 10 + (
j + 1) / 8 - 1] =
byte;
85 for (
int i = 0;
i < 52;
i++) {
91 unsigned char byte = 0;
92 for (
int j = 0;
j < 80;
j++) {
95 if ((
j + 1) % 8 == 0) {
97 bits_[
i * 10 + (
j + 1) / 8 - 1] =
byte;
121 for (
unsigned int i = 0;
i < 520;
i++) {
130 for (
unsigned int col = 0;
col < 52;
col++) {
135 for (
int row = 0; row < 80; row++) {
158 unsigned int bit = 1 << (row % 8);
167 s <<
"Dumping ROC masks" << std::endl;
169 for (
int i = 0;
i < 52;
i++) {
170 s <<
"Col" <<
i <<
":";
171 for (
int j = 0;
j < 10;
j++) {
172 unsigned char bitmask = 1;
173 for (
int k = 0;
k < 8;
k++) {
174 if (mask.
bits_[
i * 10 +
j] & bitmask) {
190 std::string mthn =
"[PixelROCMaskBits::writeXML()]\t\t\t\t";
194 *
out <<
" <DATA>" << std::endl;
196 *
out <<
" <KILL_MASK>" << encoded <<
"</KILL_MASK>" << std::endl;
197 *
out <<
" </DATA>" << std::endl;
198 *
out <<
" " << std::endl;
std::string rocname() const
void setROCMaskBits(PixelROCName &rocid, std::string bits)
int readBinary(const PixelROCName &rocid, std::ifstream &in)
int read(const PixelROCName &rocid, std::string in)
void writeBinary(std::ofstream &out) const
void setMask(unsigned int col, unsigned int row, unsigned int mask)
void writeASCII(std::ofstream &out) const
std::ostream & operator<<(std::ostream &s, const PixelCalibConfiguration &calib)
void writeXML(std::ofstream *out) const
unsigned int mask(unsigned int col, unsigned int row) const
std::string base64_encode(unsigned char const *, unsigned int len)
char data[epos_bytes_allocation]