CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
zones.h
Go to the documentation of this file.
1 // This C++ header file was automatically generated
2 // by VPPC from a Verilog HDL project.
3 // VPPC web-page: http://www.phys.ufl.edu/~madorsky/vppc/
4 
5 // Author : madorsky
6 // Timestamp : Thu Mar 12 14:54:03 2015
7 
8 #ifndef __zones_h_file__
9 #define __zones_h_file__
10 #include "vppc_sim_lib.h"
11 
12 class zones
13 {
14  public:
15  zones(){built = false; glbl_gsr = true; defparam();}
16  void defparam();
17  void build();
18  bool built;
19  bool glbl_gsr;
20  unsigned station;
21  unsigned cscid;
22  // segments per chamber
23  unsigned seg_ch;
24  // bit widths of ph and th outputs, reduced precision
25 // have to be derived from pattern width on top level
26  unsigned bw_ph;
27  unsigned bw_th;
28  // bit widths of ph and th, full precision
29  unsigned bw_fph;
30  unsigned bw_fth;
31  // wiregroup input bit width (0..111)
32  unsigned bw_wg;
33  // bit width of dblstrip input (max 80 for ME234/1 with double-width strips)
34  unsigned bw_ds;
35  // width of halfstrip input
36  unsigned bw_hs;
37  // pattern half-width for stations 3,4
38  unsigned pat_w_st3; //4;
39  // pattern half-width for station 1
40  unsigned pat_w_st1;
41  // number of input bits for stations 3,4
42  unsigned full_pat_w_st3;
43  // number of input bits for st 1
44  unsigned full_pat_w_st1;
45  // width of zero padding for station copies
46  unsigned padding_w_st1;
47  unsigned padding_w_st3;
48  // full pattern widths (aka reduced pattern)
49  unsigned red_pat_w_st3;
50  unsigned red_pat_w_st1;
51  // number of folds for pattern detectors, do not set to 1
52  unsigned fold;
53  // number of th outputs for ME1/1
54  unsigned th_ch11;
55  unsigned bw_q;
56  unsigned bw_addr;
57  // strips per section, calculated so ph pattern would cover +/- 8 deg in st 1
58  unsigned ph_raw_w; // kludge to fix synth error, need to understand
59  unsigned th_raw_w;
60  // max possible drifttime
61  unsigned max_drift;
62  // bit widths of precise phi and eta outputs
63  unsigned bw_phi;
64  unsigned bw_eta;
65  // width of ph raw hits, max coverage +8 to cover possible chamber displacement
66  unsigned ph_hit_w; //80 + 8;
67  // for 20 deg chambers
68  unsigned ph_hit_w20;
69  // for 10 deg chambers
70  unsigned ph_hit_w10; //40 + 8;
71  // width of th raw hits, max coverage +8 to cover possible chamber displacement
72  unsigned th_hit_w;
73  unsigned endcap;
74  unsigned n_strips;
75  unsigned n_wg;
76  // theta range (take +1 because th_coverage contains max th value starting from 0)
77  unsigned th_coverage;
78  // phi range
79  unsigned ph_coverage; //80 : 40;
80  // number of th outputs takes ME1/1 th duplication into account
81  unsigned th_ch;
82  // is this chamber mounted in reverse direction?
83  unsigned ph_reverse;
84  unsigned th_mem_sz;
85  unsigned th_corr_mem_sz;
86  // multiplier bit width (phi + factor)
87  unsigned mult_bw;
88  // ph zone boundaries for chambers that cover more than one zone
89 // hardcoded boundaries must match boundaries in ph_th_match module
90  unsigned ph_zone_bnd1;
91  unsigned ph_zone_bnd2;
92  unsigned zone_overlap;
93  // sorter parameters
94  unsigned bwr; // rank width
95  unsigned bpow; // (1 << bpow) is count of input ranks
96  unsigned cnr; // internal rank count
97  unsigned cnrex; // actual input rank count, must be even
98 
103 
104 
105 
106  void init ();
107  void operator()
108  (
109  signal_& phzvl__io,
110  signal_& ph_hit__io,
111  signal_& ph_zone__io,
112  signal_& clk__io
113  );
114 };
115 #endif
unsigned cnrex
Definition: zones.h:97
signal_ ph_zone
Definition: zones.h:102
unsigned th_mem_sz
Definition: zones.h:84
unsigned endcap
Definition: zones.h:73
unsigned station
Definition: zones.h:20
unsigned ph_coverage
Definition: zones.h:79
bool built
Definition: zones.h:18
unsigned padding_w_st1
Definition: zones.h:46
unsigned ph_hit_w10
Definition: zones.h:70
unsigned bw_wg
Definition: zones.h:32
unsigned bw_q
Definition: zones.h:55
unsigned bwr
Definition: zones.h:94
unsigned th_raw_w
Definition: zones.h:59
unsigned cnr
Definition: zones.h:96
unsigned bw_fph
Definition: zones.h:29
unsigned th_corr_mem_sz
Definition: zones.h:85
unsigned padding_w_st3
Definition: zones.h:47
unsigned fold
Definition: zones.h:52
unsigned ph_hit_w
Definition: zones.h:66
unsigned ph_zone_bnd1
Definition: zones.h:90
unsigned bw_fth
Definition: zones.h:30
unsigned ph_hit_w20
Definition: zones.h:68
unsigned n_strips
Definition: zones.h:74
void build()
unsigned th_ch11
Definition: zones.h:54
unsigned max_drift
Definition: zones.h:61
unsigned bw_th
Definition: zones.h:27
unsigned full_pat_w_st1
Definition: zones.h:44
Definition: zones.h:12
unsigned bw_phi
Definition: zones.h:63
signal_ clk
Definition: zones.h:101
void defparam()
unsigned bw_ds
Definition: zones.h:34
unsigned th_coverage
Definition: zones.h:77
unsigned bpow
Definition: zones.h:95
signal_ phzvl
Definition: zones.h:99
unsigned red_pat_w_st1
Definition: zones.h:50
unsigned mult_bw
Definition: zones.h:87
unsigned th_ch
Definition: zones.h:81
unsigned full_pat_w_st3
Definition: zones.h:42
unsigned pat_w_st1
Definition: zones.h:40
unsigned ph_raw_w
Definition: zones.h:58
unsigned bw_eta
Definition: zones.h:64
unsigned n_wg
Definition: zones.h:75
zones()
Definition: zones.h:15
unsigned ph_zone_bnd2
Definition: zones.h:91
unsigned bw_hs
Definition: zones.h:36
unsigned bw_addr
Definition: zones.h:56
unsigned bw_ph
Definition: zones.h:26
void init()
unsigned cscid
Definition: zones.h:21
unsigned seg_ch
Definition: zones.h:23
unsigned zone_overlap
Definition: zones.h:92
unsigned ph_reverse
Definition: zones.h:83
bool glbl_gsr
Definition: zones.h:19
unsigned red_pat_w_st3
Definition: zones.h:49
signal_ ph_hit
Definition: zones.h:100
unsigned pat_w_st3
Definition: zones.h:38
unsigned th_hit_w
Definition: zones.h:72