- inline Int_t GetDDLNumber() const { return fDDLNumber; } // Provide current DDL number
- inline Int_t GetPrevDDLNumber() const { return fPrevDDLNumber; }// Provide previous DDL number
- inline Bool_t IsNewDDLNumber() const {return (fDDLNumber != fPrevDDLNumber);};
- inline Int_t GetHWAddress() const { return fHWAddress; } // Provide current hardware address
- inline Int_t GetPrevHWAddress() const { return fPrevHWAddress; } // Provide previous hardware address
- inline Bool_t IsNewHWAddress() const {return (fHWAddress != fPrevHWAddress) || IsNewDDLNumber();};
- inline Int_t GetTime() const { return fTime; } // Provide index of current time bin
- inline Int_t GetPrevTime() const { return fPrevTime; } // Provide index of previous time bin
- inline Bool_t IsNewTime() const {return (fTime != fPrevTime) || IsNewHWAddress();};
- inline Int_t GetSignal() const { return fSignal; } // Provide signal in ADC counts
- inline Int_t GetTimeLength() const { return fTimeBunch; } // Provide total length of current time bunch
-
+ virtual Bool_t NextDDL(UChar_t* data = NULL); // Iterate over DDLs/RCUs
+ virtual Bool_t NextChannel(); // Iterate over altro channels
+ virtual Bool_t NextBunch(UShort_t *bunchData,
+ Int_t &bunchLength,
+ Int_t &startTimeBin); // Iterate over altro bunches
+
+ Int_t GetDDLNumber() const { return fDDLNumber; } // Provide current DDL number
+ Int_t GetPrevDDLNumber() const { return fPrevDDLNumber; }// Provide previous DDL number
+ Bool_t IsNewDDLNumber() const {return (fDDLNumber != fPrevDDLNumber);};
+ Int_t GetRCUId() const { return fRCUId; } // Provide current RCU identifier
+ Int_t GetPrevRCUId() const { return fPrevRCUId; } // Provide previous RCU identifier
+ Bool_t IsNewRCUId() const {return (fRCUId != fPrevRCUId);};
+ Int_t GetHWAddress() const { return fHWAddress; } // Provide current hardware address
+ Int_t GetPrevHWAddress() const { return fPrevHWAddress; } // Provide previous hardware address
+ Bool_t IsNewHWAddress() const {return (fHWAddress != fPrevHWAddress) || IsNewDDLNumber();};
+ Int_t GetTime() const { return fTime; } // Provide index of current time bin
+ Int_t GetPrevTime() const { return fPrevTime; } // Provide index of previous time bin
+ Bool_t IsNewTime() const {return (fTime != fPrevTime) || IsNewHWAddress();};
+ Int_t GetSignal() const { return fSignal; } // Provide signal in ADC counts
+ Int_t GetTimeLength() const { return fTimeBunch; } // Provide total length of current time bunch
+
+ Int_t GetChannelPayloadSize() const { return fChannelPayloadSize; }
+ Int_t GetRCUPayloadSizeInSOD() const;
+
+ Int_t GetBranch() const; // Provide the branch index for the current hardware address
+ Int_t GetFEC() const; // Provide the front-end card index for the current hardware address
+ Int_t GetAltro() const; // Provide the altro chip index for the current hardware address
+ Int_t GetChannel() const; // Provide the channel index for the current hardware address
+
+ Bool_t GetRCUTrailerData(UChar_t*& data) const; // Provide a pointer to RCU trailer
+ Int_t GetRCUTrailerSize() const { return fRCUTrailerSize; } // Provide size of RCU trailer
+
+ // RCU trailer related getters
+ UInt_t GetFECERRA() const { return fFECERRA; }
+ UInt_t GetFECERRB() const { return fFECERRB; }
+ UShort_t GetERRREG2() const { return fERRREG2; }
+ UShort_t GetNChAddrMismatch() const { return fERRREG3; }
+ UShort_t GetNChLengthMismatch() const { return fERRREG4; }
+
+ UShort_t GetActiveFECsA() const { return fActiveFECsA; }
+ UShort_t GetActiveFECsB() const { return fActiveFECsB; }
+
+ UInt_t GetAltroCFG1() const { return fAltroCFG1; }
+ UChar_t GetBaselineCorr() const { return fAltroCFG1 & 0xF; }
+ Bool_t GetPolarity() const { return (fAltroCFG1 >> 4) & 0x1; }
+ UChar_t GetNPresamples() const { return (fAltroCFG1 >> 5) & 0x3; }
+ UChar_t GetNPostsamples() const { return (fAltroCFG1 >> 7) & 0xF; }
+ Bool_t GetSecondBaselineCorr() const { return (fAltroCFG1 >> 11) & 0x1; }
+ UChar_t GetGlitchFilter() const { return (fAltroCFG1 >> 12) & 0x3; }
+ UChar_t GetNNonZSPostsamples() const { return (fAltroCFG1 >> 14) & 0x7; }
+ UChar_t GetNNonZSPresamples() const { return (fAltroCFG1 >> 17) & 0x3; }
+ Bool_t GetZeroSupp() const { return (fAltroCFG1 >> 19) & 0x1; }
+
+ UInt_t GetAltroCFG2() const { return fAltroCFG2; }
+ Bool_t GetNAltroBuffers() const { return (fAltroCFG2 >> 24) & 0x1; }
+ UChar_t GetNPretriggerSamples() const{ return (fAltroCFG2 >> 20) & 0xF; }
+ UShort_t GetNSamplesPerCh() const { return (fAltroCFG2 >> 10) & 0x3FF; }
+ Bool_t GetSparseRO() const { return (fAltroCFG2 >> 9) & 0x1; }
+ Double_t GetTSample() const;
+ Double_t GetL1Phase() const;
+ void PrintRCUTrailer() const;
+