]> git.uio.no Git - u/mrichter/AliRoot.git/blame - ITS/AliITSCompressRawDataSDD.h
bug fix
[u/mrichter/AliRoot.git] / ITS / AliITSCompressRawDataSDD.h
CommitLineData
7765ca40 1#ifndef ALIITSCOMPRESSRAWDATASDD_H
2#define ALIITSCOMPRESSRAWDATASDD_H
3
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
6
7/* $Id$ */
8
9#include<TObject.h>
10#include<TString.h>
f7bcb379 11#include"AliRawReader.h"
12
7765ca40 13///////////////////////////////////////////////////////////////////
14// //
15// Class to decode the SDD Raw Data from the CarlosRX format to //
16// a compressed format consisting in a word of 32 bit per cell //
17// Origin: F.Prino, Torino, prino@to.infn.it //
18// //
19///////////////////////////////////////////////////////////////////
20
21class AliITSCompressRawDataSDD : public TObject {
22
23 public:
f7bcb379 24 AliITSCompressRawDataSDD();
f7bcb379 25 ~AliITSCompressRawDataSDD();
f7bcb379 26 void SetRawReader(AliRawReader* rd){
27 fRawReader=rd;
28 }
29 void SetPointerToData(UChar_t* pt){
30 fPointerToData=pt;
31 }
32 void SetSize(UInt_t siz){
33 fSizeInMemory=siz;
34 }
35
f7bcb379 36 UInt_t CompressEvent(UChar_t* inputPtr);
7765ca40 37
de075dae 38 static UInt_t MakeDataWord(Int_t carlos, Int_t side, Int_t anode, Int_t tb, Int_t adc){
39 UInt_t word= (carlos<<27) + (side<<26) + (anode<<18) + (tb<<10) + adc;
40 return word;
41 }
42
43 static UInt_t MakeEndOfModuleWord(Int_t carlos){
44 UInt_t word= (15<<28) + carlos;
45 return word;
46 }
47
48 static UInt_t MakeJitterWord(Int_t jitter){
49 UInt_t word= (8<<28) + jitter;
50 return word;
51 }
52
7765ca40 53 protected:
f7bcb379 54
55 private:
56 AliITSCompressRawDataSDD(const AliITSCompressRawDataSDD& /*c*/);
57
58 AliITSCompressRawDataSDD& operator=(const AliITSCompressRawDataSDD& /*c*/);
59
60
61 AliRawReader* fRawReader; // pointer to raw reader
62 UChar_t* fPointerToData; // pointer to the start of data in memory
63 UInt_t fSizeInMemory; // free space in memory in Bytes
7765ca40 64
65 ClassDef(AliITSCompressRawDataSDD, 0)
66};
67
68#endif