CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
fed_header.h
Go to the documentation of this file.
1 /* NOTE: this file temporarily stolen from the XDAQ project
2  *
3  * fed_header.h
4  *
5  * $Header: /local/reps/CMSSW/CMSSW/DataFormats/FEDRawData/src/fed_header.h,v 1.2 2005/10/06 18:25:22 namapane Exp $
6  *
7  * This file contains the struct definition of the FED-header.
8  * The FED-header is inserted by the FED at the top of a data fragment
9  */
10 
11 
12 #ifndef _FED_HEADER_H
13 #define _FED_HEADER_H
14 
15 #ifdef __cplusplus
16 extern "C" {
17 #endif
18 
19 
20 /*************************************************************************
21  *
22  * data structures and associated typedefs
23  *
24  *************************************************************************/
25 
26 
27 /*
28  * FED header - in front of each FED block
29  */
30 
31 typedef struct fedh_struct {
32  unsigned int sourceid ;
33  unsigned int eventid;
34 } fedh_t ;
35 
36 
37 #define FED_HCTRLID_MASK 0xF0000000
38 #define FED_EVTY_MASK 0x0F000000
39 #define FED_LVL1_MASK 0x00FFFFFF
40 
41 #define FED_BXID_MASK 0xFFF00000
42 #define FED_SOID_MASK 0x000FFF00
43 #define FED_VERSION_MASK 0x000000F0
44 #define FED_MORE_HEADERS 0x00000008
45 
46 
47 #define FED_HCTRLID 0x50000000
48 
49 
50 #define FED_HCTRLID_SHIFT 28
51 #define FED_EVTY_SHIFT 24
52 #define FED_LVL1_SHIFT 0
53 
54 #define FED_BXID_SHIFT 20
55 #define FED_SOID_SHIFT 8
56 #define FED_VERSION_SHIFT 4
57 
58 #ifdef __cplusplus
59 }
60 #endif
61 
62 #endif /* _FED_HEADER_H */
63 
64 
unsigned int sourceid
Definition: fed_header.h:32
struct fedh_struct fedh_t
unsigned int eventid
Definition: fed_header.h:33