Belle II Software development
TOPPackerModule.h
1/**************************************************************************
2 * basf2 (Belle II Analysis Software Framework) *
3 * Author: The Belle II Collaboration *
4 * *
5 * See git log for contributors and copyright holders. *
6 * This file is licensed under LGPL-3.0, see LICENSE.md. *
7 **************************************************************************/
8
9#pragma once
10
11#include <framework/core/Module.h>
12#include <top/geometry/TOPGeometryPar.h>
13#include <top/RawDataTypes.h>
14#include <string>
15
16namespace Belle2 {
21
25 class TOPPackerModule : public Module {
26
27 public:
28
33
38 virtual void initialize() override;
39
43 virtual void event() override;
44
45 private:
46
52
57 void packType0Ver16();
58
63
67 static unsigned short sumShorts(unsigned int x)
68 {
69 return x + (x >> 16);
70 }
71
72 std::string m_inputDigitsName;
74 std::string m_outputRawDataName;
75 std::string m_format;
76 TOP::RawDataType m_dataType = TOP::RawDataType::c_Draft;
77
79
80 };
81
83} // Belle2 namespace
84
Module()
Constructor.
Definition Module.cc:30
std::string m_format
data format
std::string m_inputDigitsName
name of TOPDigit store array
TOP::RawDataType m_dataType
enum for data format
std::string m_outputRawDataName
name of RawTOP store array
std::string m_inputRawDigitsName
name of TOPRawDigit store array
static unsigned short sumShorts(unsigned int x)
sum both 16-bit words of 32-bit integer
TOP::TOPGeometryPar * m_topgp
geometry
Singleton class for TOP Geometry Parameters.
static TOPGeometryPar * Instance()
Static method to obtain the pointer to its instance.
virtual void initialize() override
Initialize the Module.
void packProductionDraft()
Pack in format: c_Draft (tentative production format) this format was never implemented in firmware!
void packProductionDebug()
Pack in format: Production Debugging Data Format 01.
virtual void event() override
Event processor.
void packType0Ver16()
Pack in format: c_Type0Ver16 (Feature-extracted data) this format was never implemented in firmware!
Abstract base class for different kinds of events.