]>
Commit | Line | Data |
---|---|---|
3daf4fbc | 1 | //-*- Mode: C++ -*- |
2 | // $Id$ | |
3 | #ifndef ALIHLTTRIGGERSELECTIVEREADOUTCOMPONENT_H | |
4 | #define ALIHLTTRIGGERSELECTIVEREADOUTCOMPONENT_H | |
5 | ||
6 | /* This file is property of and copyright by the ALICE HLT Project * | |
7 | * ALICE Experiment at CERN, All rights reserved. * | |
8 | * See cxx source for full Copyright notice */ | |
9 | ||
10 | /** @file AliHLTTriggerSelectiveReadoutComponent.h | |
11 | @author Jochen Thaeder | |
12 | @date | |
13 | @brief Component for the Selective Readout Trigger | |
14 | */ | |
15 | ||
16 | // see below for class documentation | |
17 | // or | |
18 | // refer to README to build package | |
19 | // or | |
20 | // visit http://web.ift.uib.no/~kjeks/doc/alice-hlt | |
21 | ||
22 | #include "AliHLTProcessor.h" | |
23 | #include "TString.h" | |
24 | ||
25 | /** | |
26 | * @class AliHLTTriggerSelectiveReadoutComponent | |
27 | * @brief Component for the Selective Readout Trigger | |
28 | * | |
29 | * This class is the trigger component for selective readout. It is not detector specific. | |
30 | * However, a detector can be provided via the commandline arguments, in order to turn off the | |
31 | * the whole detector for readout. | |
32 | * | |
33 | * If threshold has been enabled, incoming blocks with size > threshold, will not been | |
34 | * forwarded and Bit for this readout partition in ReadoutList will be set for DAQ readout. | |
35 | * | |
36 | * The component has the following component arguments: | |
6291d256 | 37 | * -detector \em TPC |\em PHOS|\em TRD | \em MUON : Select Detector for discarding raw data, use 4 Char_t origin format. |
2b4385d9 | 38 | * -enableThreshold \em size : Enables threshold on size ( default is kFALSE ) |
6291d256 | 39 | * -threshold Int_t threshold[6] : Size threshold in Byte for different patches for TPC -> This will be disappear later on, will be taken from xCDB entry. |
3daf4fbc | 40 | * |
41 | * @ingroup alihlt_trigger | |
42 | */ | |
43 | class AliHLTTriggerSelectiveReadoutComponent : public AliHLTProcessor | |
44 | { | |
45 | public: | |
46 | ||
47 | /** constructor */ | |
48 | AliHLTTriggerSelectiveReadoutComponent(); | |
49 | /** destructor */ | |
50 | virtual ~AliHLTTriggerSelectiveReadoutComponent(); | |
51 | ||
52 | // Public functions to implement AliHLTComponent's interface. | |
53 | // These functions are required for the registration process | |
54 | ||
55 | const char* GetComponentID(); | |
56 | void GetInputDataTypes( AliHLTComponentDataTypeList& list ); | |
57 | ||
58 | AliHLTComponentDataType GetOutputDataType(); | |
59 | Int_t GetOutputDataTypes( AliHLTComponentDataTypeList& tgtList ); | |
60 | ||
61 | virtual void GetOutputDataSize( unsigned long& constBase, double& inputMultiplier ); | |
62 | AliHLTComponent* Spawn(); | |
63 | ||
64 | protected: | |
65 | ||
66 | using AliHLTProcessor::DoEvent; | |
67 | ||
68 | // Protected functions to implement AliHLTComponent's interface. | |
69 | // These functions provide initialization as well as the actual processing | |
70 | // capabilities of the component. | |
71 | ||
72 | /** Initialize the trigger component. */ | |
73 | Int_t DoInit( int argc, const char** argv ); | |
74 | ||
75 | /** DeInitialize the trigger component. */ | |
76 | Int_t DoDeinit(); | |
77 | ||
78 | /** Process the data in the trigger component */ | |
79 | Int_t DoEvent( const AliHLTComponentEventData& evtData, AliHLTComponentTriggerData& trigData); | |
80 | ||
81 | private: | |
82 | /** size of the threshold array */ | |
ed504011 | 83 | static const int fkNThreshold = 6; // see above |
3daf4fbc | 84 | |
85 | /** copy constructor prohibited */ | |
86 | AliHLTTriggerSelectiveReadoutComponent(const AliHLTTriggerSelectiveReadoutComponent&); | |
87 | ||
88 | /** assignment operator prohibited */ | |
89 | AliHLTTriggerSelectiveReadoutComponent& operator=(const AliHLTTriggerSelectiveReadoutComponent&); | |
90 | ||
ed504011 | 91 | /** Detector name in HLT origin format */ |
92 | TString fDetector; //! transient | |
3daf4fbc | 93 | |
94 | /** Enable of the size Threshold */ | |
ed504011 | 95 | Bool_t fEnableThresholdSize; //! transient |
3daf4fbc | 96 | |
97 | /** Threshold in Bytes for each a readout partition */ | |
ed504011 | 98 | AliHLTUInt32_t fThreshold[fkNThreshold]; //! transient |
3daf4fbc | 99 | |
100 | ClassDef(AliHLTTriggerSelectiveReadoutComponent, 0); | |
101 | ||
102 | }; | |
103 | #endif |