X-Git-Url: http://git.uio.no/git/?p=u%2Fmrichter%2FAliRoot.git;a=blobdiff_plain;f=HLT%2FRCU%2FAliHLTAltroChannelSelectorComponent.h;h=04bb19c9a014d462fb4a0ff1ccc0df6b04a642ac;hp=50ad0c74a461f8ae779e240de203a12f6861060e;hb=72ecb506e7901ed17650690c08cb3b56c19f9398;hpb=3dcae0cc6c79e22adea4996a5c10c99f4b6431a5;ds=sidebyside diff --git a/HLT/RCU/AliHLTAltroChannelSelectorComponent.h b/HLT/RCU/AliHLTAltroChannelSelectorComponent.h index 50ad0c74a46..04bb19c9a01 100644 --- a/HLT/RCU/AliHLTAltroChannelSelectorComponent.h +++ b/HLT/RCU/AliHLTAltroChannelSelectorComponent.h @@ -1,46 +1,70 @@ //-*- Mode: C++ -*- -// @(#) $Id$ +// $Id$ #ifndef ALIHLTALTROCHANNELSELECTORCOMPONENT_H #define ALIHLTALTROCHANNELSELECTORCOMPONENT_H -/* This file is property of and copyright by the ALICE HLT Project * - * ALICE Experiment at CERN, All rights reserved. * - * See cxx source for full Copyright notice */ +//* This file is property of and copyright by the ALICE HLT Project * +//* ALICE Experiment at CERN, All rights reserved. * +//* See cxx source for full Copyright notice * -/** @file AliHLTAltroChannelSelectorComponent.h - @author Matthias Richter - @date - @brief A filter/selective readout component for Altro data. -*/ +/// @file AliHLTAltroChannelSelectorComponent.h +/// @author Matthias Richter +/// @date +/// @brief A filter/selective readout component for Altro data. +/// -// see below for class documentation -// or -// refer to README to build package -// or // visit http://web.ift.uib.no/~kjeks/doc/alice-hlt #include "AliHLTProcessor.h" +class TH1F; + /** * @class AliHLTAltroChannelSelectorComponent * A selector component for ALTRO Raw data. The component subscribes - * to the RAW data {***:DDL_RAW } and gets in addition a list of channels - * to select. The list must be of identical specification as the RAW data - * and can be of data type: - * - {***:HWADDR16}: 16 bit hardware addresses + * to the RAW data {***:DDL_RAW }, and produces the same raw data block + * with only the selected ALTRO channels.
+ * Three different modes are supported: + * - -signal-threshold
+ * the average of all signals in the channel is calculated and it is + * selected when the maximum signal exceeds average+threshold + * - -rms-threshold
+ * the implemented logic needs to be checked, never been used + * - list of channels to select. + * The list must be of identical specification as the RAW data and of + * data type {***:HWADDR16}: 16 bit hardware addresses + * * - * TheAliAltroDecoder is used as input decoder to read and scan the + * The AliAltroRawStreamV3 is used as input decoder to read and scan the * Altro Raw data. * - * Component ID: \b AltroChannelSelector
- * Library: \b libAliHLTRCU + *

General properties:

+ * + * Component ID: \b AltroChannelSelector
+ * Library: \b libAliHLTRCU
+ * Input Data Types: kAliHLTDataTypeDDLRaw, kAliHLTDataTypeHwAddr16
+ * Output Data Types: kAliHLTDataTypeDDLRaw
* * Mandatory arguments:
- * + * * * Optional arguments:
- * + * + * \li -keep-corrupted + * keep corrupted channels, by default ignored + * \li -talkative + * be a bit more verbose, prints out statistics message and warnings + * \li -start-timebin bin + * all time bins below will be ignored + * \li -end-timebin bin + * all time bins above will be ignored + * \li -signal-threshold adc_counts + * the average will be calculated from all bins between start and end, + * a channel is considered active if the maximum is bigger than averge + * plus threshold + * \li -rms-threshold sigma * + * @ingroup alihlt_rcu_components */ class AliHLTAltroChannelSelectorComponent : public AliHLTProcessor { public: @@ -74,26 +98,22 @@ class AliHLTAltroChannelSelectorComponent : public AliHLTProcessor { /** assignment operator prohibited */ AliHLTAltroChannelSelectorComponent& operator=(const AliHLTAltroChannelSelectorComponent&); - /** - * Copy a data block at the end of a buffer. - * The source buffer is inserted at given position relative to the buffer - * end. - * @param pTgt target buffer - * @param capacity capacity (size) of the buffer - * @param position porition relative to the END of the buffer - * @param pSrc source buffer to be copied - * @param size size of the source buffer - * @return copied size, neg error code if failed - */ - int CopyBlockToEnd(AliHLTUInt8_t* pTgt, unsigned capacity, unsigned position, void* pSrc, unsigned size); - /** skip corrupted channels */ bool fSkipCorrupted; //!transient /** more verbose output */ bool fTalkative; //!transient - ClassDef(AliHLTAltroChannelSelectorComponent, 1); + unsigned int fStartTimeBin; //!transient + unsigned int fEndTimeBin; //!transient + unsigned int fSignalThreshold; //!transient + float fRMSThreshold; //!transient + bool fMakeHistogram; //!transient + + TH1F *fhThreshold;//! Histgram of the "threshold value" + TH1F *fhRMS;//! Histgrams of the "RMS value" + + ClassDef(AliHLTAltroChannelSelectorComponent, 0); }; #endif