Main Page
Namespaces
Classes
Package Documentation
CVS Directory
WorkBook
Offline Guide
Release schedule
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Pages
src
EventFilter
Utilities
src
DebugUtils.cc
Go to the documentation of this file.
1
#include "
EventFilter/Utilities/interface/DebugUtils.h
"
2
3
#include <sstream>
4
#include <iomanip>
5
#include <cstdio>
6
7
using namespace
std;
8
9
string
evf::dumpFrame
(
unsigned
char
*
data
,
unsigned
int
len)
10
{
11
12
ostringstream
out
;
13
char
left[40];
14
char
right[40];
15
16
// LOG4CPLUS_ERROR(adapter_->getApplicationLogger(),toolbox::toString("Byte 0 1 2 3 4 5 6 7\n"));
17
out <<
"Byte: 0 1 2 3 4 5 6 7\n"
;
18
19
int
c
= 0;
20
int
pos
= 0;
21
22
23
for
(
unsigned
int
i
= 0;
i
< (len/8);
i
++) {
24
int
rpos = 0;
25
c += 7;
26
for
(pos = 0; pos < 8*3; pos += 3) {
27
sprintf (&left[pos],
"%2.2x "
, ((
unsigned
char
*)data)[c]);
28
sprintf (&right[rpos],
"%1c"
, ((data[c] > 32) && (data[c] < 127)) ? data[c]:
'.'
);
29
rpos += 1;
30
c--;
31
}
32
c += 9;
33
out << setw(4) << setfill(
'0'
) << c-8 <<
": "
<< left <<
" || "
34
<< right << endl;
35
36
}
37
return
out.str();
38
}
i
int i
Definition:
DBlmapReader.cc:9
pos
Definition:
Histograms.cc:19
evf::dumpFrame
std::string dumpFrame(unsigned char *data, unsigned int len)
Definition:
DebugUtils.cc:9
dbtoconf.out
tuple out
Definition:
dbtoconf.py:99
DebugUtils.h
trackerHits.c
tuple c
Definition:
trackerHits.py:26
runTheMatrix.data
data
Definition:
runTheMatrix.py:756
Generated for CMSSW Reference Manual by
1.8.5