CMS 3D CMS Logo

CSCTFTBSPHeader.h

Go to the documentation of this file.
00001 #if !defined(CSCTFTBRAWFORMAT_CSCTFTBSPHEADER_H)
00002 #define CSCTFTBRAWFORMAT_CSCTFTBSPHEADER_H
00003 // -*- C++ -*-
00004 //
00005 // Package:     CSCTFTBRawData
00006 // Module:      CSCTFTBSPHeader
00007 // 
00008 // Description: Header file for SP Data Block Header
00009 //
00010 // Implementation:
00011 //     <Notes on implementation>
00012 //
00013 // Author:      Lindsey Gray
00014 // Created:     13.1.2005
00015 //
00016 // $Id: CSCTFTBSPHeader.h,v 1.1 2007/04/26 23:39:19 kkotov Exp $
00017 //
00018 // Revision History
00019 // $Log: CSCTFTBSPHeader.h,v $
00020 // Revision 1.1  2007/04/26 23:39:19  kkotov
00021 //
00022 // Moved old TB data format to a separate folder, attempted to unpack status digi
00023 //
00024 // Revision 1.2  2006/06/22 14:46:05  lgray
00025 // Forced commit of all code
00026 //
00027 // Revision 1.1  2006/06/22 00:34:18  lgray
00028 // Moved all data format classes here. Removed old Packages from nightly
00029 //
00030 // Revision 1.1  2006/02/22 23:15:49  lgray
00031 // First commit of test beam data format from UF
00032 //
00033 // Revision 1.1  2005/02/14 20:59:46  lgray
00034 // First Commit from UF
00035 //
00036 // Revision 1.6  2004/05/18 15:00:25  tfcvs
00037 // DEA: close to new SP data format
00038 //
00039 // Revision 1.5  2004/05/18 11:37:46  tfcvs
00040 // DEA: touch base
00041 //
00042 // Revision 1.4  2004/05/18 09:45:34  tfcvs
00043 // DEA: touch base
00044 //
00045 // Revision 1.3  2004/05/18 08:00:10  tfcvs
00046 // DEA: touch base
00047 //
00048 // Revision 1.2  2003/08/27 22:07:51  tfcvs
00049 // Added pretty-print - Rick
00050 //
00051 // Revision 1.1  2003/05/25 10:13:02  tfcvs
00052 // first working version -DEA
00053 //
00054 // Revision 1.7  2003/05/20 22:13:06  tfcvs
00055 // HS - Added Darin's changes
00056 //
00057 // Revision 1.6  2003/05/19 23:23:12  tfcvs
00058 // HS - Commit after some changes
00059 //
00060 // Revision 1.4  2003/05/19 15:47:18  tfcvs
00061 // HS - Some cleanup
00062 //
00063 // Revision 1.3  2003/05/19 00:25:56  tfcvs
00064 // DEA: committed, but may not compile
00065 //
00066 // Revision 1.2  2003/05/15 23:58:40  tfcvs
00067 // HS - Some cosmetics
00068 //
00069 //
00070 //
00071 
00072 // System include files
00073 #include <iostream>
00074 #include <string.h> //memset
00075 // Package include files
00076 
00077 // External package include files
00078 
00079 // STL classes
00080 
00081 // Forward declarations
00082 
00083 class CSCTFTBSPHeader 
00084 {
00085 
00086 // Friend classses and functions
00087 
00088 // Public part
00089    public:
00090         // Constants, enums and typedefs
00091 
00092         // Constructors and destructor
00093         CSCTFTBSPHeader();
00094 
00095         CSCTFTBSPHeader(const CSCTFTBSPHeader&);
00096 
00097         ~CSCTFTBSPHeader();
00098         
00099         CSCTFTBSPHeader operator=(const CSCTFTBSPHeader&);
00100         // Member functions
00101   
00102         // Const member functions
00103 
00105         bool check() const {return ((zero1_ == 0) && (zero2_ == 0));}
00106 
00108         static unsigned size() {return size_;};
00109 
00111         unsigned int synchError() const {return  synch_err_;}
00112 
00114         unsigned int getSEBit(unsigned int frontFPGA, unsigned int link) const;
00115 
00117         unsigned int getTrackMode(unsigned int trk) const;
00118 
00120         unsigned int getVPDTBit(unsigned int link) const;
00121 
00123         friend std::ostream & operator<<(std::ostream & stream, const CSCTFTBSPHeader &);
00124 // Protected part
00125    protected:
00126 
00127         // Protected member functions
00128 
00129         // Protected const member functions
00130 
00131 // Private part
00132    private:
00133 
00134         //frame 1
00135         unsigned synch_err_  :15;
00136         unsigned zero1_      :1; //always zero
00137         //frame 2
00138         unsigned mode1_      :4;
00139         unsigned mode2_      :4;
00140         unsigned mode3_      :4;
00141         unsigned MB1A_flag_  :1;
00142         unsigned MB1D_flag_  :1;
00143         unsigned zero2_      :2; //always zero
00144 
00145         // Constructors and destructor
00146 
00147         // Assignment operator(s)
00148 
00149         // Private member functions
00150 
00151         // Private const member functions
00152 
00153         // Data members
00154 
00155         // Static data members
00156         static const unsigned size_ = 2;
00157         // Inline function definitions
00158 
00159 };
00160 
00161 #endif

Generated on Tue Jun 9 17:34:27 2009 for CMSSW by  doxygen 1.5.4