source: XOpenSparcT1/trunk/sim/ddr2_model_parameters.vh @ 10

Revision 10, 108.8 KB checked in by pntsvt00, 13 years ago (diff)

versione sintetizzabile

Line 
1/****************************************************************************************
2*
3*   Disclaimer   This software code and all associated documentation, comments or other
4*  of Warranty:  information (collectively "Software") is provided "AS IS" without
5*                warranty of any kind. MICRON TECHNOLOGY, INC. ("MTI") EXPRESSLY
6*                DISCLAIMS ALL WARRANTIES EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
7*                TO, NONINFRINGEMENT OF THIRD PARTY RIGHTS, AND ANY IMPLIED WARRANTIES
8*                OF MERCHANTABILITY OR FITNESS FOR ANY PARTICULAR PURPOSE. MTI DOES NOT
9*                WARRANT THAT THE SOFTWARE WILL MEET YOUR REQUIREMENTS, OR THAT THE
10*                OPERATION OF THE SOFTWARE WILL BE UNINTERRUPTED OR ERROR-FREE.
11*                FURTHERMORE, MTI DOES NOT MAKE ANY REPRESENTATIONS REGARDING THE USE OR
12*                THE RESULTS OF THE USE OF THE SOFTWARE IN TERMS OF ITS CORRECTNESS,
13*                ACCURACY, RELIABILITY, OR OTHERWISE. THE ENTIRE RISK ARISING OUT OF USE
14*                OR PERFORMANCE OF THE SOFTWARE REMAINS WITH YOU. IN NO EVENT SHALL MTI,
15*                ITS AFFILIATED COMPANIES OR THEIR SUPPLIERS BE LIABLE FOR ANY DIRECT,
16*                INDIRECT, CONSEQUENTIAL, INCIDENTAL, OR SPECIAL DAMAGES (INCLUDING,
17*                WITHOUT LIMITATION, DAMAGES FOR LOSS OF PROFITS, BUSINESS INTERRUPTION,
18*                OR LOSS OF INFORMATION) ARISING OUT OF YOUR USE OF OR INABILITY TO USE
19*                THE SOFTWARE, EVEN IF MTI HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
20*                DAMAGES. Because some jurisdictions prohibit the exclusion or
21*                limitation of liability for consequential or incidental damages, the
22*                above limitation may not apply to you.
23*
24*                Copyright 2003 Micron Technology, Inc. All rights reserved.
25*
26****************************************************************************************/
27
28    // Timing parameters based on Speed Grade
29
30                                          // SYMBOL UNITS DESCRIPTION
31                                          // ------ ----- -----------
32`ifdef x256Mb
33
34    `ifdef sg187E
35        parameter TCK_MIN          =    1875; // tCK    ps    Minimum Clock Cycle Time
36        parameter TJIT_PER         =      90; // tJIT(per)  ps Period JItter
37        parameter TJIT_DUTY        =      75; // tJIT(duty) ps Half Period Jitter
38        parameter TJIT_CC          =     180; // tJIT(cc)   ps Cycle to Cycle jitter
39        parameter TERR_2PER        =     132; // tERR(nper) ps Accumulated Error (2-cycle)
40        parameter TERR_3PER        =     157; // tERR(nper) ps Accumulated Error (3-cycle)
41        parameter TERR_4PER        =     175; // tERR(nper) ps Accumulated Error (4-cycle)
42        parameter TERR_5PER        =     188; // tERR(nper) ps Accumulated Error (5-cycle)
43        parameter TERR_N1PER       =     250; // tERR(nper) ps Accumulated Error (6-10-cycle)
44        parameter TERR_N2PER       =     425; // tERR(nper) ps Accumulated Error (11-50-cycle)
45        parameter TQHS             =     250; // tQHS   ps    Data hold skew factor
46        parameter TAC              =     350; // tAC    ps    DQ output access time from CK/CK#
47        parameter TDS              =       0; // tDS    ps    DQ and DM input setup time relative to DQS
48        parameter TDH              =      75; // tDH    ps    DQ and DM input hold time relative to DQS
49        parameter TDQSCK           =     300; // tDQSCK ps    DQS output access time from CK/CK#
50        parameter TDQSQ            =     175; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
51        parameter TIS              =     125; // tIS    ps    Input Setup Time
52        parameter TIH              =     200; // tIH    ps    Input Hold Time
53        parameter TRC              =   54000; // tRC    ps    Active to Active/Auto Refresh command time
54        parameter TRCD             =   13125; // tRCD   ps    Active to Read/Write command time
55        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
56        parameter TRP              =   13125; // tRP    ps    Precharge command period
57        parameter TRPA             =   13125; // tRPA   ps    Precharge All period
58        parameter TXARDS           =      10; // tXARDS tCK   Exit low power active power down to a read command
59        parameter TXARD            =       3; // tXARD  tCK   Exit active power down to a read command
60        parameter TXP              =       3; // tXP    tCK   Exit power down to a non-read command
61        parameter TANPD            =       4; // tANPD  tCK   ODT to power-down entry latency
62        parameter TAXPD            =      11; // tAXPD  tCK   ODT power-down exit latency
63        parameter CL_TIME          =   13125; // CL     ps    Minimum CAS Latency
64    `else `ifdef sg25E
65        parameter TCK_MIN          =    2500; // tCK    ps    Minimum Clock Cycle Time
66        parameter TJIT_PER         =     100; // tJIT(per)  ps Period JItter
67        parameter TJIT_DUTY        =     100; // tJIT(duty) ps Half Period Jitter
68        parameter TJIT_CC          =     200; // tJIT(cc)   ps Cycle to Cycle jitter
69        parameter TERR_2PER        =     150; // tERR(nper) ps Accumulated Error (2-cycle)
70        parameter TERR_3PER        =     175; // tERR(nper) ps Accumulated Error (3-cycle)
71        parameter TERR_4PER        =     200; // tERR(nper) ps Accumulated Error (4-cycle)
72        parameter TERR_5PER        =     200; // tERR(nper) ps Accumulated Error (5-cycle)
73        parameter TERR_N1PER       =     300; // tERR(nper) ps Accumulated Error (6-10-cycle)
74        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
75        parameter TQHS             =     300; // tQHS   ps    Data hold skew factor
76        parameter TAC              =     400; // tAC    ps    DQ output access time from CK/CK#
77        parameter TDS              =      50; // tDS    ps    DQ and DM input setup time relative to DQS
78        parameter TDH              =     125; // tDH    ps    DQ and DM input hold time relative to DQS
79        parameter TDQSCK           =     350; // tDQSCK ps    DQS output access time from CK/CK#
80        parameter TDQSQ            =     200; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
81        parameter TIS              =     175; // tIS    ps    Input Setup Time
82        parameter TIH              =     250; // tIH    ps    Input Hold Time
83        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
84        parameter TRCD             =   12500; // tRCD   ps    Active to Read/Write command time
85        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
86        parameter TRP              =   12500; // tRP    ps    Precharge command period
87        parameter TRPA             =   12500; // tRPA   ps    Precharge All period
88        parameter TXARDS           =       8; // tXARDS tCK   Exit low power active power down to a read command
89        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
90        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
91        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
92        parameter TAXPD            =      10; // tAXPD  tCK   ODT power-down exit latency
93        parameter CL_TIME          =   12500; // CL     ps    Minimum CAS Latency
94    `else `ifdef sg25
95        parameter TCK_MIN          =    2500; // tCK    ps    Minimum Clock Cycle Time
96        parameter TJIT_PER         =     100; // tJIT(per)  ps Period JItter
97        parameter TJIT_DUTY        =     100; // tJIT(duty) ps Half Period Jitter
98        parameter TJIT_CC          =     200; // tJIT(cc)   ps Cycle to Cycle jitter
99        parameter TERR_2PER        =     150; // tERR(nper) ps Accumulated Error (2-cycle)
100        parameter TERR_3PER        =     175; // tERR(nper) ps Accumulated Error (3-cycle)
101        parameter TERR_4PER        =     200; // tERR(nper) ps Accumulated Error (4-cycle)
102        parameter TERR_5PER        =     200; // tERR(nper) ps Accumulated Error (5-cycle)
103        parameter TERR_N1PER       =     300; // tERR(nper) ps Accumulated Error (6-10-cycle)
104        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
105        parameter TQHS             =     300; // tQHS   ps    Data hold skew factor
106        parameter TAC              =     400; // tAC    ps    DQ output access time from CK/CK#
107        parameter TDS              =      50; // tDS    ps    DQ and DM input setup time relative to DQS
108        parameter TDH              =     125; // tDH    ps    DQ and DM input hold time relative to DQS
109        parameter TDQSCK           =     350; // tDQSCK ps    DQS output access time from CK/CK#
110        parameter TDQSQ            =     200; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
111        parameter TIS              =     175; // tIS    ps    Input Setup Time
112        parameter TIH              =     250; // tIH    ps    Input Hold Time
113        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
114        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
115        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
116        parameter TRP              =   15000; // tRP    ps    Precharge command period
117        parameter TRPA             =   15000; // tRPA   ps    Precharge All period
118        parameter TXARDS           =       8; // tXARDS tCK   Exit low power active power down to a read command
119        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
120        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
121        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
122        parameter TAXPD            =      10; // tAXPD  tCK   ODT power-down exit latency
123        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
124    `else `ifdef sg3E
125        parameter TCK_MIN          =    3000; // tCK    ps    Minimum Clock Cycle Time
126        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
127        parameter TJIT_DUTY        =     125; // tJIT(duty) ps Half Period Jitter
128        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
129        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
130        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
131        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
132        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
133        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
134        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
135        parameter TQHS             =     340; // tQHS   ps    Data hold skew factor
136        parameter TAC              =     450; // tAC    ps    DQ output access time from CK/CK#
137        parameter TDS              =     100; // tDS    ps    DQ and DM input setup time relative to DQS
138        parameter TDH              =     175; // tDH    ps    DQ and DM input hold time relative to DQS
139        parameter TDQSCK           =     400; // tDQSCK ps    DQS output access time from CK/CK#
140        parameter TDQSQ            =     240; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
141        parameter TIS              =     200; // tIS    ps    Input Setup Time
142        parameter TIH              =     275; // tIH    ps    Input Hold Time
143        parameter TRC              =   54000; // tRC    ps    Active to Active/Auto Refresh command time
144        parameter TRCD             =   12000; // tRCD   ps    Active to Read/Write command time
145        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
146        parameter TRP              =   12000; // tRP    ps    Precharge command period
147        parameter TRPA             =   12000; // tRPA   ps    Precharge All period
148        parameter TXARDS           =       7; // tXARDS tCK   Exit low power active power down to a read command
149        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
150        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
151        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
152        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
153        parameter CL_TIME          =   12000; // CL     ps    Minimum CAS Latency
154    `else `ifdef sg3
155        parameter TCK_MIN          =    3000; // tCK    ps    Minimum Clock Cycle Time
156        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
157        parameter TJIT_DUTY        =     125; // tJIT(duty) ps Half Period Jitter
158        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
159        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
160        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
161        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
162        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
163        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
164        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
165        parameter TQHS             =     340; // tQHS   ps    Data hold skew factor
166        parameter TAC              =     450; // tAC    ps    DQ output access time from CK/CK#
167        parameter TDS              =     100; // tDS    ps    DQ and DM input setup time relative to DQS
168        parameter TDH              =     175; // tDH    ps    DQ and DM input hold time relative to DQS
169        parameter TDQSCK           =     400; // tDQSCK ps    DQS output access time from CK/CK#
170        parameter TDQSQ            =     240; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
171        parameter TIS              =     200; // tIS    ps    Input Setup Time
172        parameter TIH              =     275; // tIH    ps    Input Hold Time
173        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
174        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
175        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
176        parameter TRP              =   15000; // tRP    ps    Precharge command period
177        parameter TRPA             =   15000; // tRPA   ps    Precharge All period
178        parameter TXARDS           =       7; // tXARDS tCK   Exit low power active power down to a read command
179        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
180        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
181        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
182        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
183        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
184    `else `ifdef sg37E
185        parameter TCK_MIN          =    3750; // tCK    ps    Minimum Clock Cycle Time
186        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
187        parameter TJIT_DUTY        =     125; // tJIT(duty) ps Half Period Jitter
188        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
189        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
190        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
191        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
192        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
193        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
194        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
195        parameter TQHS             =     400; // tQHS   ps    Data hold skew factor
196        parameter TAC              =     500; // tAC    ps    DQ output access time from CK/CK#
197        parameter TDS              =     100; // tDS    ps    DQ and DM input setup time relative to DQS
198        parameter TDH              =     225; // tDH    ps    DQ and DM input hold time relative to DQS
199        parameter TDQSCK           =     450; // tDQSCK ps    DQS output access time from CK/CK#
200        parameter TDQSQ            =     300; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
201        parameter TIS              =     250; // tIS    ps    Input Setup Time
202        parameter TIH              =     375; // tIH    ps    Input Hold Time
203        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
204        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
205        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
206        parameter TRP              =   15000; // tRP    ps    Precharge command period
207        parameter TRPA             =   15000; // tRPA   ps    Precharge All period
208        parameter TXARDS           =       6; // tXARDS tCK   Exit low power active power down to a read command
209        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
210        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
211        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
212        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
213        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
214    `else `define sg5E
215        parameter TCK_MIN          =    5000; // tCK    ps    Minimum Clock Cycle Time
216        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
217        parameter TJIT_DUTY        =     150; // tJIT(duty) ps Half Period Jitter
218        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
219        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
220        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
221        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
222        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
223        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
224        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
225        parameter TQHS             =     450; // tQHS   ps    Data hold skew factor
226        parameter TAC              =     600; // tAC    ps    DQ output access time from CK/CK#
227        parameter TDS              =     150; // tDS    ps    DQ and DM input setup time relative to DQS
228        parameter TDH              =     275; // tDH    ps    DQ and DM input hold time relative to DQS
229        parameter TDQSCK           =     500; // tDQSCK ps    DQS output access time from CK/CK#
230        parameter TDQSQ            =     350; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
231        parameter TIS              =     350; // tIS    ps    Input Setup Time
232        parameter TIH              =     475; // tIH    ps    Input Hold Time
233        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
234        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
235        parameter TWTR             =   10000; // tWTR   ps    Write to Read command delay
236        parameter TRP              =   15000; // tRP    ps    Precharge command period
237        parameter TRPA             =   15000; // tRPA   ps    Precharge All period
238        parameter TXARDS           =       6; // tXARDS tCK   Exit low power active power down to a read command
239        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
240        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
241        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
242        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
243        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
244    `endif `endif `endif `endif `endif `endif
245
246    `ifdef x16
247      `ifdef sg187E
248        parameter TFAW             =   45000; // tFAW  ps     Four Bank Activate window
249      `else `ifdef sg25E
250        parameter TFAW             =   45000; // tFAW  ps     Four Bank Activate window
251      `else `ifdef sg25
252        parameter TFAW             =   45000; // tFAW  ps     Four Bank Activate window
253      `else // sg3E, sg3, sg37E, sg5E
254        parameter TFAW             =   50000; // tFAW  ps     Four Bank Activate window
255      `endif `endif `endif
256    `else // x4, x8
257      `ifdef sg187E
258        parameter TFAW             =   35000; // tFAW  ps     Four Bank Activate window
259      `else `ifdef sg25E
260        parameter TFAW             =   35000; // tFAW  ps     Four Bank Activate window
261      `else `ifdef sg25
262        parameter TFAW             =   35000; // tFAW  ps     Four Bank Activate window
263      `else // sg3E, sg3, sg37E, sg5E
264        parameter TFAW             =   37500; // tFAW  ps     Four Bank Activate window
265      `endif `endif `endif
266    `endif
267
268        // Timing Parameters
269
270        // Mode Register
271        parameter AL_MIN           =       0; // AL     tCK   Minimum Additive Latency
272        parameter AL_MAX           =       6; // AL     tCK   Maximum Additive Latency
273        parameter CL_MIN           =       3; // CL     tCK   Minimum CAS Latency
274        parameter CL_MAX           =       7; // CL     tCK   Maximum CAS Latency
275        parameter WR_MIN           =       2; // WR     tCK   Minimum Write Recovery
276        parameter WR_MAX           =       8; // WR     tCK   Maximum Write Recovery
277        parameter BL_MIN           =       4; // BL     tCK   Minimum Burst Length
278        parameter BL_MAX           =       8; // BL     tCK   Minimum Burst Length
279        // Clock
280        parameter TCK_MAX          =    8000; // tCK    ps    Maximum Clock Cycle Time
281        parameter TCH_MIN          =    0.48; // tCH    tCK   Minimum Clock High-Level Pulse Width
282        parameter TCH_MAX          =    0.52; // tCH    tCK   Maximum Clock High-Level Pulse Width
283        parameter TCL_MIN          =    0.48; // tCL    tCK   Minimum Clock Low-Level Pulse Width
284        parameter TCL_MAX          =    0.52; // tCL    tCK   Maximum Clock Low-Level Pulse Width
285        // Data
286        parameter TLZ              =     TAC; // tLZ    ps    Data-out low-impedance window from CK/CK#
287        parameter THZ              =     TAC; // tHZ    ps    Data-out high impedance window from CK/CK#
288        parameter TDIPW            =    0.35; // tDIPW  tCK   DQ and DM input Pulse Width
289        // Data Strobe
290        parameter TDQSH            =    0.35; // tDQSH  tCK   DQS input High Pulse Width
291        parameter TDQSL            =    0.35; // tDQSL  tCK   DQS input Low Pulse Width
292        parameter TDSS             =    0.20; // tDSS   tCK   DQS falling edge to CLK rising (setup time)
293        parameter TDSH             =    0.20; // tDSH   tCK   DQS falling edge from CLK rising (hold time)
294        parameter TWPRE            =    0.35; // tWPRE  tCK   DQS Write Preamble
295        parameter TWPST            =    0.40; // tWPST  tCK   DQS Write Postamble
296        parameter TDQSS            =    0.25; // tDQSS  tCK   Rising clock edge to DQS/DQS# latching transition
297        // Command and Address
298        parameter TIPW             =     0.6; // tIPW   tCK   Control and Address input Pulse Width
299        parameter TCCD             =       2; // tCCD   tCK   Cas to Cas command delay
300        parameter TRAS_MIN         =   40000; // tRAS   ps    Minimum Active to Precharge command time
301        parameter TRAS_MAX         =70000000; // tRAS   ps    Maximum Active to Precharge command time
302        parameter TRTP             =    7500; // tRTP   ps    Read to Precharge command delay
303        parameter TWR              =   15000; // tWR    ps    Write recovery time
304        parameter TMRD             =       2; // tMRD   tCK   Load Mode Register command cycle time
305        parameter TDLLK            =     200; // tDLLK  tCK   DLL locking time
306        // Refresh
307        parameter TRFC_MIN         =   75000; // tRFC   ps    Refresh to Refresh Command interval minimum value
308        parameter TRFC_MAX         =70000000; // tRFC   ps    Refresh to Refresh Command Interval maximum value
309        // Self Refresh
310        parameter TXSNR   = TRFC_MIN + 10000; // tXSNR  ps    Exit self refesh to a non-read command
311        parameter TXSRD            =     200; // tXSRD  tCK   Exit self refresh to a read command
312        parameter TISXR            =     TIS; // tISXR  ps    CKE setup time during self refresh exit.
313        // ODT
314        parameter TAOND            =       2; // tAOND  tCK   ODT turn-on delay
315        parameter TAOFD            =     2.5; // tAOFD  tCK   ODT turn-off delay
316        parameter TAONPD           =    2000; // tAONPD ps    ODT turn-on (precharge power-down mode)
317        parameter TAOFPD           =    2000; // tAOFPD ps    ODT turn-off (precharge power-down mode)
318        parameter TMOD             =   12000; // tMOD   ps    ODT enable in EMR to ODT pin transition
319        // Power Down
320        parameter TCKE             =       3; // tCKE   tCK   CKE minimum high or low pulse width
321
322        // Size Parameters based on Part Width
323
324    `ifdef x4
325        parameter DM_BITS          =       1; // Number of Data Mask bits
326        parameter ROW_BITS         =      13; // Number of Address bits
327        parameter COL_BITS         =      11; // Number of Column bits
328        parameter DQ_BITS          =       4; // Number of Data bits
329        parameter DQS_BITS         =       1; // Number of Dqs bits
330        parameter TRRD             =    7500; // tRRD   Active bank a to Active bank b command time
331    `else `ifdef x8
332        parameter DM_BITS          =       1; // Number of Data Mask bits
333        parameter ROW_BITS         =      13; // Number of Address bits
334        parameter COL_BITS         =      10; // Number of Column bits
335        parameter DQ_BITS          =       8; // Number of Data bits
336        parameter DQS_BITS         =       1; // Number of Dqs bits
337        parameter TRRD             =    7500; // tRRD   Active bank a to Active bank b command time
338    `else `define x16
339        parameter DM_BITS          =       2; // Number of Data Mask bits
340        parameter ROW_BITS         =      13; // Number of Address bits
341        parameter COL_BITS         =       9; // Number of Column bits
342        parameter DQ_BITS          =      16; // Number of Data bits
343        parameter DQS_BITS         =       2; // Number of Dqs bits
344        parameter TRRD             =   10000; // tRRD   Active bank a to Active bank b command time
345    `endif `endif
346
347    `ifdef QUAD_RANK
348        `define DUAL_RANK // also define DUAL_RANK
349        parameter CS_BITS          =       4; // Number of Chip Select Bits
350        parameter RANKS            =       4; // Number of Chip Select Bits
351    `else `ifdef DUAL_RANK
352        parameter CS_BITS          =       2; // Number of Chip Select Bits
353        parameter RANKS            =       2; // Number of Chip Select Bits
354    `else
355        parameter CS_BITS          =       2; // Number of Chip Select Bits
356        parameter RANKS            =       1; // Number of Chip Select Bits
357    `endif `endif
358
359        // Size Parameters
360        parameter BA_BITS          =       2; // Set this parmaeter to control how many Bank Address bits
361        parameter ADDR_BITS        =      13; // Address Bits
362        parameter MEM_BITS         =      10; // Number of write data bursts can be stored in memory.  The default is 2^10=1024.
363        parameter AP               =      10; // the address bit that controls auto-precharge and precharge-all
364        parameter BL_BITS          =       3; // the number of bits required to count to MAX_BL
365        parameter BO_BITS          =       2; // the number of Burst Order Bits
366
367`else `ifdef x512Mb
368
369    `ifdef sg187E
370        parameter TCK_MIN          =    1875; // tCK    ps    Minimum Clock Cycle Time
371        parameter TJIT_PER         =      90; // tJIT(per)  ps Period JItter
372        parameter TJIT_DUTY        =      75; // tJIT(duty) ps Half Period Jitter
373        parameter TJIT_CC          =     180; // tJIT(cc)   ps Cycle to Cycle jitter
374        parameter TERR_2PER        =     132; // tERR(nper) ps Accumulated Error (2-cycle)
375        parameter TERR_3PER        =     157; // tERR(nper) ps Accumulated Error (3-cycle)
376        parameter TERR_4PER        =     175; // tERR(nper) ps Accumulated Error (4-cycle)
377        parameter TERR_5PER        =     188; // tERR(nper) ps Accumulated Error (5-cycle)
378        parameter TERR_N1PER       =     250; // tERR(nper) ps Accumulated Error (6-10-cycle)
379        parameter TERR_N2PER       =     425; // tERR(nper) ps Accumulated Error (11-50-cycle)
380        parameter TQHS             =     250; // tQHS   ps    Data hold skew factor
381        parameter TAC              =     350; // tAC    ps    DQ output access time from CK/CK#
382        parameter TDS              =       0; // tDS    ps    DQ and DM input setup time relative to DQS
383        parameter TDH              =      75; // tDH    ps    DQ and DM input hold time relative to DQS
384        parameter TDQSCK           =     300; // tDQSCK ps    DQS output access time from CK/CK#
385        parameter TDQSQ            =     175; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
386        parameter TIS              =     125; // tIS    ps    Input Setup Time
387        parameter TIH              =     200; // tIH    ps    Input Hold Time
388        parameter TRC              =   54000; // tRC    ps    Active to Active/Auto Refresh command time
389        parameter TRCD             =   13125; // tRCD   ps    Active to Read/Write command time
390        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
391        parameter TRP              =   13125; // tRP    ps    Precharge command period
392        parameter TRPA             =   13125; // tRPA   ps    Precharge All period
393        parameter TXARDS           =      10; // tXARDS tCK   Exit low power active power down to a read command
394        parameter TXARD            =       3; // tXARD  tCK   Exit active power down to a read command
395        parameter TXP              =       3; // tXP    tCK   Exit power down to a non-read command
396        parameter TANPD            =       4; // tANPD  tCK   ODT to power-down entry latency
397        parameter TAXPD            =      11; // tAXPD  tCK   ODT power-down exit latency
398        parameter CL_TIME          =   13125; // CL     ps    Minimum CAS Latency
399    `else `ifdef sg25E
400        parameter TCK_MIN          =    2500; // tCK    ps    Minimum Clock Cycle Time
401        parameter TJIT_PER         =     100; // tJIT(per)  ps Period JItter
402        parameter TJIT_DUTY        =     100; // tJIT(duty) ps Half Period Jitter
403        parameter TJIT_CC          =     200; // tJIT(cc)   ps Cycle to Cycle jitter
404        parameter TERR_2PER        =     150; // tERR(nper) ps Accumulated Error (2-cycle)
405        parameter TERR_3PER        =     175; // tERR(nper) ps Accumulated Error (3-cycle)
406        parameter TERR_4PER        =     200; // tERR(nper) ps Accumulated Error (4-cycle)
407        parameter TERR_5PER        =     200; // tERR(nper) ps Accumulated Error (5-cycle)
408        parameter TERR_N1PER       =     300; // tERR(nper) ps Accumulated Error (6-10-cycle)
409        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
410        parameter TQHS             =     300; // tQHS   ps    Data hold skew factor
411        parameter TAC              =     400; // tAC    ps    DQ output access time from CK/CK#
412        parameter TDS              =      50; // tDS    ps    DQ and DM input setup time relative to DQS
413        parameter TDH              =     125; // tDH    ps    DQ and DM input hold time relative to DQS
414        parameter TDQSCK           =     350; // tDQSCK ps    DQS output access time from CK/CK#
415        parameter TDQSQ            =     200; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
416        parameter TIS              =     175; // tIS    ps    Input Setup Time
417        parameter TIH              =     250; // tIH    ps    Input Hold Time
418        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
419        parameter TRCD             =   12500; // tRCD   ps    Active to Read/Write command time
420        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
421        parameter TRP              =   12500; // tRP    ps    Precharge command period
422        parameter TRPA             =   12500; // tRPA   ps    Precharge All period
423        parameter TXARDS           =       8; // tXARDS tCK   Exit low power active power down to a read command
424        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
425        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
426        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
427        parameter TAXPD            =      10; // tAXPD  tCK   ODT power-down exit latency
428        parameter CL_TIME          =   12500; // CL     ps    Minimum CAS Latency
429    `else `ifdef sg25
430        parameter TCK_MIN          =    2500; // tCK    ps    Minimum Clock Cycle Time
431        parameter TJIT_PER         =     100; // tJIT(per)  ps Period JItter
432        parameter TJIT_DUTY        =     100; // tJIT(duty) ps Half Period Jitter
433        parameter TJIT_CC          =     200; // tJIT(cc)   ps Cycle to Cycle jitter
434        parameter TERR_2PER        =     150; // tERR(nper) ps Accumulated Error (2-cycle)
435        parameter TERR_3PER        =     175; // tERR(nper) ps Accumulated Error (3-cycle)
436        parameter TERR_4PER        =     200; // tERR(nper) ps Accumulated Error (4-cycle)
437        parameter TERR_5PER        =     200; // tERR(nper) ps Accumulated Error (5-cycle)
438        parameter TERR_N1PER       =     300; // tERR(nper) ps Accumulated Error (6-10-cycle)
439        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
440        parameter TQHS             =     300; // tQHS   ps    Data hold skew factor
441        parameter TAC              =     400; // tAC    ps    DQ output access time from CK/CK#
442        parameter TDS              =      50; // tDS    ps    DQ and DM input setup time relative to DQS
443        parameter TDH              =     125; // tDH    ps    DQ and DM input hold time relative to DQS
444        parameter TDQSCK           =     350; // tDQSCK ps    DQS output access time from CK/CK#
445        parameter TDQSQ            =     200; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
446        parameter TIS              =     175; // tIS    ps    Input Setup Time
447        parameter TIH              =     250; // tIH    ps    Input Hold Time
448        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
449        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
450        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
451        parameter TRP              =   15000; // tRP    ps    Precharge command period
452        parameter TRPA             =   15000; // tRPA   ps    Precharge All period
453        parameter TXARDS           =       8; // tXARDS tCK   Exit low power active power down to a read command
454        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
455        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
456        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
457        parameter TAXPD            =      10; // tAXPD  tCK   ODT power-down exit latency
458        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
459    `else `ifdef sg3E
460        parameter TCK_MIN          =    3000; // tCK    ps    Minimum Clock Cycle Time
461        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
462        parameter TJIT_DUTY        =     125; // tJIT(duty) ps Half Period Jitter
463        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
464        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
465        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
466        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
467        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
468        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
469        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
470        parameter TQHS             =     340; // tQHS   ps    Data hold skew factor
471        parameter TAC              =     450; // tAC    ps    DQ output access time from CK/CK#
472        parameter TDS              =     100; // tDS    ps    DQ and DM input setup time relative to DQS
473        parameter TDH              =     175; // tDH    ps    DQ and DM input hold time relative to DQS
474        parameter TDQSCK           =     400; // tDQSCK ps    DQS output access time from CK/CK#
475        parameter TDQSQ            =     240; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
476        parameter TIS              =     200; // tIS    ps    Input Setup Time
477        parameter TIH              =     275; // tIH    ps    Input Hold Time
478        parameter TRC              =   54000; // tRC    ps    Active to Active/Auto Refresh command time
479        parameter TRCD             =   12000; // tRCD   ps    Active to Read/Write command time
480        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
481        parameter TRP              =   12000; // tRP    ps    Precharge command period
482        parameter TRPA             =   12000; // tRPA   ps    Precharge All period
483        parameter TXARDS           =       7; // tXARDS tCK   Exit low power active power down to a read command
484        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
485        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
486        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
487        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
488        parameter CL_TIME          =   12000; // CL     ps    Minimum CAS Latency
489    `else `ifdef sg3
490        parameter TCK_MIN          =    3000; // tCK    ps    Minimum Clock Cycle Time
491        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
492        parameter TJIT_DUTY        =     125; // tJIT(duty) ps Half Period Jitter
493        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
494        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
495        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
496        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
497        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
498        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
499        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
500        parameter TQHS             =     340; // tQHS   ps    Data hold skew factor
501        parameter TAC              =     450; // tAC    ps    DQ output access time from CK/CK#
502        parameter TDS              =     100; // tDS    ps    DQ and DM input setup time relative to DQS
503        parameter TDH              =     175; // tDH    ps    DQ and DM input hold time relative to DQS
504        parameter TDQSCK           =     400; // tDQSCK ps    DQS output access time from CK/CK#
505        parameter TDQSQ            =     240; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
506        parameter TIS              =     200; // tIS    ps    Input Setup Time
507        parameter TIH              =     275; // tIH    ps    Input Hold Time
508        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
509        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
510        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
511        parameter TRP              =   15000; // tRP    ps    Precharge command period
512        parameter TRPA             =   15000; // tRPA   ps    Precharge All period
513        parameter TXARDS           =       7; // tXARDS tCK   Exit low power active power down to a read command
514        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
515        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
516        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
517        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
518        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
519    `else `ifdef sg37E
520        parameter TCK_MIN          =    3750; // tCK    ps    Minimum Clock Cycle Time
521        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
522        parameter TJIT_DUTY        =     125; // tJIT(duty) ps Half Period Jitter
523        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
524        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
525        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
526        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
527        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
528        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
529        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
530        parameter TQHS             =     400; // tQHS   ps    Data hold skew factor
531        parameter TAC              =     500; // tAC    ps    DQ output access time from CK/CK#
532        parameter TDS              =     100; // tDS    ps    DQ and DM input setup time relative to DQS
533        parameter TDH              =     225; // tDH    ps    DQ and DM input hold time relative to DQS
534        parameter TDQSCK           =     450; // tDQSCK ps    DQS output access time from CK/CK#
535        parameter TDQSQ            =     300; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
536        parameter TIS              =     250; // tIS    ps    Input Setup Time
537        parameter TIH              =     375; // tIH    ps    Input Hold Time
538        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
539        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
540        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
541        parameter TRP              =   15000; // tRP    ps    Precharge command period
542        parameter TRPA             =   15000; // tRPA   ps    Precharge All period
543        parameter TXARDS           =       6; // tXARDS tCK   Exit low power active power down to a read command
544        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
545        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
546        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
547        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
548        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
549    `else `define sg5E
550        parameter TCK_MIN          =    5000; // tCK    ps    Minimum Clock Cycle Time
551        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
552        parameter TJIT_DUTY        =     150; // tJIT(duty) ps Half Period Jitter
553        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
554        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
555        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
556        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
557        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
558        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
559        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
560        parameter TQHS             =     450; // tQHS   ps    Data hold skew factor
561        parameter TAC              =     600; // tAC    ps    DQ output access time from CK/CK#
562        parameter TDS              =     150; // tDS    ps    DQ and DM input setup time relative to DQS
563        parameter TDH              =     275; // tDH    ps    DQ and DM input hold time relative to DQS
564        parameter TDQSCK           =     500; // tDQSCK ps    DQS output access time from CK/CK#
565        parameter TDQSQ            =     350; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
566        parameter TIS              =     350; // tIS    ps    Input Setup Time
567        parameter TIH              =     475; // tIH    ps    Input Hold Time
568        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
569        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
570        parameter TWTR             =   10000; // tWTR   ps    Write to Read command delay
571        parameter TRP              =   15000; // tRP    ps    Precharge command period
572        parameter TRPA             =   15000; // tRPA   ps    Precharge All period
573        parameter TXARDS           =       6; // tXARDS tCK   Exit low power active power down to a read command
574        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
575        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
576        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
577        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
578        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
579    `endif `endif `endif `endif `endif `endif
580
581    `ifdef x16
582      `ifdef sg187E
583        parameter TFAW             =   45000; // tFAW  ps     Four Bank Activate window
584      `else `ifdef sg25E
585        parameter TFAW             =   45000; // tFAW  ps     Four Bank Activate window
586      `else `ifdef sg25
587        parameter TFAW             =   45000; // tFAW  ps     Four Bank Activate window
588      `else // sg3E, sg3, sg37E, sg5E
589        parameter TFAW             =   50000; // tFAW  ps     Four Bank Activate window
590      `endif `endif `endif
591    `else // x4, x8
592      `ifdef sg187E
593        parameter TFAW             =   35000; // tFAW  ps     Four Bank Activate window
594      `else `ifdef sg25E
595        parameter TFAW             =   35000; // tFAW  ps     Four Bank Activate window
596      `else `ifdef sg25
597        parameter TFAW             =   35000; // tFAW  ps     Four Bank Activate window
598      `else // sg3E, sg3, sg37E, sg5E
599        parameter TFAW             =   37500; // tFAW  ps     Four Bank Activate window
600      `endif `endif `endif
601    `endif
602
603        // Timing Parameters
604
605        // Mode Register
606        parameter AL_MIN           =       0; // AL     tCK   Minimum Additive Latency
607        parameter AL_MAX           =       6; // AL     tCK   Maximum Additive Latency
608        parameter CL_MIN           =       3; // CL     tCK   Minimum CAS Latency
609        parameter CL_MAX           =       7; // CL     tCK   Maximum CAS Latency
610        parameter WR_MIN           =       2; // WR     tCK   Minimum Write Recovery
611        parameter WR_MAX           =       8; // WR     tCK   Maximum Write Recovery
612        parameter BL_MIN           =       4; // BL     tCK   Minimum Burst Length
613        parameter BL_MAX           =       8; // BL     tCK   Minimum Burst Length
614        // Clock
615        parameter TCK_MAX          =    8000; // tCK    ps    Maximum Clock Cycle Time
616        parameter TCH_MIN          =    0.48; // tCH    tCK   Minimum Clock High-Level Pulse Width
617        parameter TCH_MAX          =    0.52; // tCH    tCK   Maximum Clock High-Level Pulse Width
618        parameter TCL_MIN          =    0.48; // tCL    tCK   Minimum Clock Low-Level Pulse Width
619        parameter TCL_MAX          =    0.52; // tCL    tCK   Maximum Clock Low-Level Pulse Width
620        // Data
621        parameter TLZ              =     TAC; // tLZ    ps    Data-out low-impedance window from CK/CK#
622        parameter THZ              =     TAC; // tHZ    ps    Data-out high impedance window from CK/CK#
623        parameter TDIPW            =    0.35; // tDIPW  tCK   DQ and DM input Pulse Width
624        // Data Strobe
625        parameter TDQSH            =    0.35; // tDQSH  tCK   DQS input High Pulse Width
626        parameter TDQSL            =    0.35; // tDQSL  tCK   DQS input Low Pulse Width
627        parameter TDSS             =    0.20; // tDSS   tCK   DQS falling edge to CLK rising (setup time)
628        parameter TDSH             =    0.20; // tDSH   tCK   DQS falling edge from CLK rising (hold time)
629        parameter TWPRE            =    0.35; // tWPRE  tCK   DQS Write Preamble
630        parameter TWPST            =    0.40; // tWPST  tCK   DQS Write Postamble
631        parameter TDQSS            =    0.25; // tDQSS  tCK   Rising clock edge to DQS/DQS# latching transition
632        // Command and Address
633        parameter TIPW             =     0.6; // tIPW   tCK   Control and Address input Pulse Width
634        parameter TCCD             =       2; // tCCD   tCK   Cas to Cas command delay
635        parameter TRAS_MIN         =   40000; // tRAS   ps    Minimum Active to Precharge command time
636        parameter TRAS_MAX         =70000000; // tRAS   ps    Maximum Active to Precharge command time
637        parameter TRTP             =    7500; // tRTP   ps    Read to Precharge command delay
638        parameter TWR              =   15000; // tWR    ps    Write recovery time
639        parameter TMRD             =       2; // tMRD   tCK   Load Mode Register command cycle time
640        parameter TDLLK            =     200; // tDLLK  tCK   DLL locking time
641        // Refresh
642        parameter TRFC_MIN         =  105000; // tRFC   ps    Refresh to Refresh Command interval minimum value
643        parameter TRFC_MAX         =70000000; // tRFC   ps    Refresh to Refresh Command Interval maximum value
644        // Self Refresh
645        parameter TXSNR   = TRFC_MIN + 10000; // tXSNR  ps    Exit self refesh to a non-read command
646        parameter TXSRD            =     200; // tXSRD  tCK   Exit self refresh to a read command
647        parameter TISXR            =     TIS; // tISXR  ps    CKE setup time during self refresh exit.
648        // ODT
649        parameter TAOND            =       2; // tAOND  tCK   ODT turn-on delay
650        parameter TAOFD            =     2.5; // tAOFD  tCK   ODT turn-off delay
651        parameter TAONPD           =    2000; // tAONPD ps    ODT turn-on (precharge power-down mode)
652        parameter TAOFPD           =    2000; // tAOFPD ps    ODT turn-off (precharge power-down mode)
653        parameter TMOD             =   12000; // tMOD   ps    ODT enable in EMR to ODT pin transition
654        // Power Down
655        parameter TCKE             =       3; // tCKE   tCK   CKE minimum high or low pulse width
656
657        // Size Parameters based on Part Width
658
659    `ifdef x4
660        parameter ADDR_BITS        =      14; // Address Bits
661        parameter ROW_BITS         =      14; // Number of Address bits
662        parameter COL_BITS         =      11; // Number of Column bits
663        parameter DM_BITS          =       1; // Number of Data Mask bits
664        parameter DQ_BITS          =       4; // Number of Data bits
665        parameter DQS_BITS         =       1; // Number of Dqs bits
666        parameter TRRD             =    7500; // tRRD   Active bank a to Active bank b command time
667    `else `ifdef x8
668        parameter ADDR_BITS        =      14; // Address Bits
669        parameter ROW_BITS         =      14; // Number of Address bits
670        parameter COL_BITS         =      10; // Number of Column bits
671        parameter DM_BITS          =       1; // Number of Data Mask bits
672        parameter DQ_BITS          =       8; // Number of Data bits
673        parameter DQS_BITS         =       1; // Number of Dqs bits
674        parameter TRRD             =    7500; // tRRD   Active bank a to Active bank b command time
675    `else `define x16
676        parameter ADDR_BITS        =      13; // Address Bits
677        parameter ROW_BITS         =      13; // Number of Address bits
678        parameter COL_BITS         =      10; // Number of Column bits
679        parameter DM_BITS          =       2; // Number of Data Mask bits
680        parameter DQ_BITS          =      16; // Number of Data bits
681        parameter DQS_BITS         =       2; // Number of Dqs bits
682        parameter TRRD             =   10000; // tRRD   Active bank a to Active bank b command time
683    `endif `endif
684
685    `ifdef QUAD_RANK
686        `define DUAL_RANK // also define DUAL_RANK
687        parameter CS_BITS          =       4; // Number of Chip Select Bits
688        parameter RANKS            =       4; // Number of Chip Select Bits
689    `else `ifdef DUAL_RANK
690        parameter CS_BITS          =       2; // Number of Chip Select Bits
691        parameter RANKS            =       2; // Number of Chip Select Bits
692    `else
693        parameter CS_BITS          =       2; // Number of Chip Select Bits
694        parameter RANKS            =       1; // Number of Chip Select Bits
695    `endif `endif
696
697        // Size Parameters
698        parameter BA_BITS          =       2; // Set this parmaeter to control how many Bank Address bits
699        parameter MEM_BITS         =      10; // Number of write data bursts can be stored in memory.  The default is 2^10=1024.
700        parameter AP               =      10; // the address bit that controls auto-precharge and precharge-all
701        parameter BL_BITS          =       3; // the number of bits required to count to MAX_BL
702        parameter BO_BITS          =       2; // the number of Burst Order Bits
703
704`else `ifdef x1Gb
705
706    `ifdef sg187E
707        parameter TCK_MIN          =    1875; // tCK    ps    Minimum Clock Cycle Time
708        parameter TJIT_PER         =      90; // tJIT(per)  ps Period JItter
709        parameter TJIT_DUTY        =      75; // tJIT(duty) ps Half Period Jitter
710        parameter TJIT_CC          =     180; // tJIT(cc)   ps Cycle to Cycle jitter
711        parameter TERR_2PER        =     132; // tERR(nper) ps Accumulated Error (2-cycle)
712        parameter TERR_3PER        =     157; // tERR(nper) ps Accumulated Error (3-cycle)
713        parameter TERR_4PER        =     175; // tERR(nper) ps Accumulated Error (4-cycle)
714        parameter TERR_5PER        =     188; // tERR(nper) ps Accumulated Error (5-cycle)
715        parameter TERR_N1PER       =     250; // tERR(nper) ps Accumulated Error (6-10-cycle)
716        parameter TERR_N2PER       =     425; // tERR(nper) ps Accumulated Error (11-50-cycle)
717        parameter TQHS             =     250; // tQHS   ps    Data hold skew factor
718        parameter TAC              =     350; // tAC    ps    DQ output access time from CK/CK#
719        parameter TDS              =       0; // tDS    ps    DQ and DM input setup time relative to DQS
720        parameter TDH              =      75; // tDH    ps    DQ and DM input hold time relative to DQS
721        parameter TDQSCK           =     300; // tDQSCK ps    DQS output access time from CK/CK#
722        parameter TDQSQ            =     175; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
723        parameter TIS              =     125; // tIS    ps    Input Setup Time
724        parameter TIH              =     200; // tIH    ps    Input Hold Time
725        parameter TRC              =   54000; // tRC    ps    Active to Active/Auto Refresh command time
726        parameter TRCD             =   13125; // tRCD   ps    Active to Read/Write command time
727        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
728        parameter TRP              =   13125; // tRP    ps    Precharge command period
729        parameter TRPA             =   15000; // tRPA   ps    Precharge All period
730        parameter TXARDS           =      10; // tXARDS tCK   Exit low power active power down to a read command
731        parameter TXARD            =       3; // tXARD  tCK   Exit active power down to a read command
732        parameter TXP              =       3; // tXP    tCK   Exit power down to a non-read command
733        parameter TANPD            =       4; // tANPD  tCK   ODT to power-down entry latency
734        parameter TAXPD            =      11; // tAXPD  tCK   ODT power-down exit latency
735        parameter CL_TIME          =   13125; // CL     ps    Minimum CAS Latency
736    `else `ifdef sg25E
737        parameter TCK_MIN          =    2500; // tCK    ps    Minimum Clock Cycle Time
738        parameter TJIT_PER         =     100; // tJIT(per)  ps Period JItter
739        parameter TJIT_DUTY        =     100; // tJIT(duty) ps Half Period Jitter
740        parameter TJIT_CC          =     200; // tJIT(cc)   ps Cycle to Cycle jitter
741        parameter TERR_2PER        =     150; // tERR(nper) ps Accumulated Error (2-cycle)
742        parameter TERR_3PER        =     175; // tERR(nper) ps Accumulated Error (3-cycle)
743        parameter TERR_4PER        =     200; // tERR(nper) ps Accumulated Error (4-cycle)
744        parameter TERR_5PER        =     200; // tERR(nper) ps Accumulated Error (5-cycle)
745        parameter TERR_N1PER       =     300; // tERR(nper) ps Accumulated Error (6-10-cycle)
746        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
747        parameter TQHS             =     300; // tQHS   ps    Data hold skew factor
748        parameter TAC              =     400; // tAC    ps    DQ output access time from CK/CK#
749        parameter TDS              =      50; // tDS    ps    DQ and DM input setup time relative to DQS
750        parameter TDH              =     125; // tDH    ps    DQ and DM input hold time relative to DQS
751        parameter TDQSCK           =     350; // tDQSCK ps    DQS output access time from CK/CK#
752        parameter TDQSQ            =     200; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
753        parameter TIS              =     175; // tIS    ps    Input Setup Time
754        parameter TIH              =     250; // tIH    ps    Input Hold Time
755        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
756        parameter TRCD             =   12500; // tRCD   ps    Active to Read/Write command time
757        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
758        parameter TRP              =   12500; // tRP    ps    Precharge command period
759        parameter TRPA             =   15000; // tRPA   ps    Precharge All period
760        parameter TXARDS           =       8; // tXARDS tCK   Exit low power active power down to a read command
761        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
762        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
763        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
764        parameter TAXPD            =      10; // tAXPD  tCK   ODT power-down exit latency
765        parameter CL_TIME          =   12500; // CL     ps    Minimum CAS Latency
766    `else `ifdef sg25
767        parameter TCK_MIN          =    2500; // tCK    ps    Minimum Clock Cycle Time
768        parameter TJIT_PER         =     100; // tJIT(per)  ps Period JItter
769        parameter TJIT_DUTY        =     100; // tJIT(duty) ps Half Period Jitter
770        parameter TJIT_CC          =     200; // tJIT(cc)   ps Cycle to Cycle jitter
771        parameter TERR_2PER        =     150; // tERR(nper) ps Accumulated Error (2-cycle)
772        parameter TERR_3PER        =     175; // tERR(nper) ps Accumulated Error (3-cycle)
773        parameter TERR_4PER        =     200; // tERR(nper) ps Accumulated Error (4-cycle)
774        parameter TERR_5PER        =     200; // tERR(nper) ps Accumulated Error (5-cycle)
775        parameter TERR_N1PER       =     300; // tERR(nper) ps Accumulated Error (6-10-cycle)
776        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
777        parameter TQHS             =     300; // tQHS   ps    Data hold skew factor
778        parameter TAC              =     400; // tAC    ps    DQ output access time from CK/CK#
779        parameter TDS              =      50; // tDS    ps    DQ and DM input setup time relative to DQS
780        parameter TDH              =     125; // tDH    ps    DQ and DM input hold time relative to DQS
781        parameter TDQSCK           =     350; // tDQSCK ps    DQS output access time from CK/CK#
782        parameter TDQSQ            =     200; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
783        parameter TIS              =     175; // tIS    ps    Input Setup Time
784        parameter TIH              =     250; // tIH    ps    Input Hold Time
785        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
786        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
787        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
788        parameter TRP              =   15000; // tRP    ps    Precharge command period
789        parameter TRPA             =   17500; // tRPA   ps    Precharge All period
790        parameter TXARDS           =       8; // tXARDS tCK   Exit low power active power down to a read command
791        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
792        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
793        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
794        parameter TAXPD            =      10; // tAXPD  tCK   ODT power-down exit latency
795        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
796    `else `ifdef sg3E
797        parameter TCK_MIN          =    3000; // tCK    ps    Minimum Clock Cycle Time
798        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
799        parameter TJIT_DUTY        =     125; // tJIT(duty) ps Half Period Jitter
800        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
801        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
802        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
803        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
804        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
805        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
806        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
807        parameter TQHS             =     340; // tQHS   ps    Data hold skew factor
808        parameter TAC              =     450; // tAC    ps    DQ output access time from CK/CK#
809        parameter TDS              =     100; // tDS    ps    DQ and DM input setup time relative to DQS
810        parameter TDH              =     175; // tDH    ps    DQ and DM input hold time relative to DQS
811        parameter TDQSCK           =     400; // tDQSCK ps    DQS output access time from CK/CK#
812        parameter TDQSQ            =     240; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
813        parameter TIS              =     200; // tIS    ps    Input Setup Time
814        parameter TIH              =     275; // tIH    ps    Input Hold Time
815        parameter TRC              =   54000; // tRC    ps    Active to Active/Auto Refresh command time
816        parameter TRCD             =   12000; // tRCD   ps    Active to Read/Write command time
817        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
818        parameter TRP              =   12000; // tRP    ps    Precharge command period
819        parameter TRPA             =   15000; // tRPA   ps    Precharge All period
820        parameter TXARDS           =       7; // tXARDS tCK   Exit low power active power down to a read command
821        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
822        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
823        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
824        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
825        parameter CL_TIME          =   12000; // CL     ps    Minimum CAS Latency
826    `else `ifdef sg3
827        parameter TCK_MIN          =    3000; // tCK    ps    Minimum Clock Cycle Time
828        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
829        parameter TJIT_DUTY        =     125; // tJIT(duty) ps Half Period Jitter
830        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
831        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
832        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
833        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
834        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
835        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
836        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
837        parameter TQHS             =     340; // tQHS   ps    Data hold skew factor
838        parameter TAC              =     450; // tAC    ps    DQ output access time from CK/CK#
839        parameter TDS              =     100; // tDS    ps    DQ and DM input setup time relative to DQS
840        parameter TDH              =     175; // tDH    ps    DQ and DM input hold time relative to DQS
841        parameter TDQSCK           =     400; // tDQSCK ps    DQS output access time from CK/CK#
842        parameter TDQSQ            =     240; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
843        parameter TIS              =     200; // tIS    ps    Input Setup Time
844        parameter TIH              =     275; // tIH    ps    Input Hold Time
845        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
846        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
847        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
848        parameter TRP              =   15000; // tRP    ps    Precharge command period
849        parameter TRPA             =   18000; // tRPA   ps    Precharge All period
850        parameter TXARDS           =       7; // tXARDS tCK   Exit low power active power down to a read command
851        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
852        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
853        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
854        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
855        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
856    `else `ifdef sg37E
857        parameter TCK_MIN          =    3750; // tCK    ps    Minimum Clock Cycle Time
858        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
859        parameter TJIT_DUTY        =     125; // tJIT(duty) ps Half Period Jitter
860        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
861        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
862        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
863        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
864        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
865        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
866        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
867        parameter TQHS             =     400; // tQHS   ps    Data hold skew factor
868        parameter TAC              =     500; // tAC    ps    DQ output access time from CK/CK#
869        parameter TDS              =     100; // tDS    ps    DQ and DM input setup time relative to DQS
870        parameter TDH              =     225; // tDH    ps    DQ and DM input hold time relative to DQS
871        parameter TDQSCK           =     450; // tDQSCK ps    DQS output access time from CK/CK#
872        parameter TDQSQ            =     300; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
873        parameter TIS              =     250; // tIS    ps    Input Setup Time
874        parameter TIH              =     375; // tIH    ps    Input Hold Time
875        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
876        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
877        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
878        parameter TRP              =   15000; // tRP    ps    Precharge command period
879        parameter TRPA             =   18750; // tRPA   ps    Precharge All period
880        parameter TXARDS           =       6; // tXARDS tCK   Exit low power active power down to a read command
881        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
882        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
883        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
884        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
885        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
886    `else `define sg5E
887        parameter TCK_MIN          =    5000; // tCK    ps    Minimum Clock Cycle Time
888        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
889        parameter TJIT_DUTY        =     150; // tJIT(duty) ps Half Period Jitter
890        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
891        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
892        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
893        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
894        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
895        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
896        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
897        parameter TQHS             =     450; // tQHS   ps    Data hold skew factor
898        parameter TAC              =     600; // tAC    ps    DQ output access time from CK/CK#
899        parameter TDS              =     150; // tDS    ps    DQ and DM input setup time relative to DQS
900        parameter TDH              =     275; // tDH    ps    DQ and DM input hold time relative to DQS
901        parameter TDQSCK           =     500; // tDQSCK ps    DQS output access time from CK/CK#
902        parameter TDQSQ            =     350; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
903        parameter TIS              =     350; // tIS    ps    Input Setup Time
904        parameter TIH              =     475; // tIH    ps    Input Hold Time
905        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
906        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
907        parameter TWTR             =   10000; // tWTR   ps    Write to Read command delay
908        parameter TRP              =   15000; // tRP    ps    Precharge command period
909        parameter TRPA             =   20000; // tRPA   ps    Precharge All period
910        parameter TXARDS           =       6; // tXARDS tCK   Exit low power active power down to a read command
911        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
912        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
913        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
914        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
915        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
916    `endif `endif `endif `endif `endif `endif
917
918    `ifdef x16
919      `ifdef sg187E
920        parameter TFAW             =   45000; // tFAW  ps     Four Bank Activate window
921      `else `ifdef sg25E
922        parameter TFAW             =   45000; // tFAW  ps     Four Bank Activate window
923      `else `ifdef sg25
924        parameter TFAW             =   45000; // tFAW  ps     Four Bank Activate window
925      `else // sg3E, sg3, sg37E, sg5E
926        parameter TFAW             =   50000; // tFAW  ps     Four Bank Activate window
927      `endif `endif `endif
928    `else // x4, x8
929      `ifdef sg187E
930        parameter TFAW             =   35000; // tFAW  ps     Four Bank Activate window
931      `else `ifdef sg25E
932        parameter TFAW             =   35000; // tFAW  ps     Four Bank Activate window
933      `else `ifdef sg25
934        parameter TFAW             =   35000; // tFAW  ps     Four Bank Activate window
935      `else // sg3E, sg3, sg37E, sg5E
936        parameter TFAW             =   37500; // tFAW  ps     Four Bank Activate window
937      `endif `endif `endif
938    `endif
939
940        // Timing Parameters
941
942        // Mode Register
943        parameter AL_MIN           =       0; // AL     tCK   Minimum Additive Latency
944        parameter AL_MAX           =       6; // AL     tCK   Maximum Additive Latency
945        parameter CL_MIN           =       3; // CL     tCK   Minimum CAS Latency
946        parameter CL_MAX           =       7; // CL     tCK   Maximum CAS Latency
947        parameter WR_MIN           =       2; // WR     tCK   Minimum Write Recovery
948        parameter WR_MAX           =       8; // WR     tCK   Maximum Write Recovery
949        parameter BL_MIN           =       4; // BL     tCK   Minimum Burst Length
950        parameter BL_MAX           =       8; // BL     tCK   Minimum Burst Length
951        // Clock
952        parameter TCK_MAX          =    8000; // tCK    ps    Maximum Clock Cycle Time
953        parameter TCH_MIN          =    0.48; // tCH    tCK   Minimum Clock High-Level Pulse Width
954        parameter TCH_MAX          =    0.52; // tCH    tCK   Maximum Clock High-Level Pulse Width
955        parameter TCL_MIN          =    0.48; // tCL    tCK   Minimum Clock Low-Level Pulse Width
956        parameter TCL_MAX          =    0.52; // tCL    tCK   Maximum Clock Low-Level Pulse Width
957        // Data
958        parameter TLZ              =     TAC; // tLZ    ps    Data-out low-impedance window from CK/CK#
959        parameter THZ              =     TAC; // tHZ    ps    Data-out high impedance window from CK/CK#
960        parameter TDIPW            =    0.35; // tDIPW  tCK   DQ and DM input Pulse Width
961        // Data Strobe
962        parameter TDQSH            =    0.35; // tDQSH  tCK   DQS input High Pulse Width
963        parameter TDQSL            =    0.35; // tDQSL  tCK   DQS input Low Pulse Width
964        parameter TDSS             =    0.20; // tDSS   tCK   DQS falling edge to CLK rising (setup time)
965        parameter TDSH             =    0.20; // tDSH   tCK   DQS falling edge from CLK rising (hold time)
966        parameter TWPRE            =    0.35; // tWPRE  tCK   DQS Write Preamble
967        parameter TWPST            =    0.40; // tWPST  tCK   DQS Write Postamble
968        parameter TDQSS            =    0.25; // tDQSS  tCK   Rising clock edge to DQS/DQS# latching transition
969        // Command and Address
970        parameter TIPW             =     0.6; // tIPW   tCK   Control and Address input Pulse Width
971        parameter TCCD             =       2; // tCCD   tCK   Cas to Cas command delay
972        parameter TRAS_MIN         =   40000; // tRAS   ps    Minimum Active to Precharge command time
973        parameter TRAS_MAX         =70000000; // tRAS   ps    Maximum Active to Precharge command time
974        parameter TRTP             =    7500; // tRTP   ps    Read to Precharge command delay
975        parameter TWR              =   15000; // tWR    ps    Write recovery time
976        parameter TMRD             =       2; // tMRD   tCK   Load Mode Register command cycle time
977        parameter TDLLK            =     200; // tDLLK  tCK   DLL locking time
978        // Refresh
979        parameter TRFC_MIN         =  127500; // tRFC   ps    Refresh to Refresh Command interval minimum value
980        parameter TRFC_MAX         =70000000; // tRFC   ps    Refresh to Refresh Command Interval maximum value
981        // Self Refresh
982        parameter TXSNR   = TRFC_MIN + 10000; // tXSNR  ps    Exit self refesh to a non-read command
983        parameter TXSRD            =     200; // tXSRD  tCK   Exit self refresh to a read command
984        parameter TISXR            =     TIS; // tISXR  ps    CKE setup time during self refresh exit.
985        // ODT
986        parameter TAOND            =       2; // tAOND  tCK   ODT turn-on delay
987        parameter TAOFD            =     2.5; // tAOFD  tCK   ODT turn-off delay
988        parameter TAONPD           =    2000; // tAONPD ps    ODT turn-on (precharge power-down mode)
989        parameter TAOFPD           =    2000; // tAOFPD ps    ODT turn-off (precharge power-down mode)
990        parameter TMOD             =   12000; // tMOD   ps    ODT enable in EMR to ODT pin transition
991        // Power Down
992        parameter TCKE             =       3; // tCKE   tCK   CKE minimum high or low pulse width
993
994        // Size Parameters based on Part Width
995
996    `ifdef x4
997        parameter ADDR_BITS        =      14; // Address Bits
998        parameter ROW_BITS         =      14; // Number of Address bits
999        parameter COL_BITS         =      11; // Number of Column bits
1000        parameter DM_BITS          =       1; // Number of Data Mask bits
1001        parameter DQ_BITS          =       4; // Number of Data bits
1002        parameter DQS_BITS         =       1; // Number of Dqs bits
1003        parameter TRRD             =    7500; // tRRD   Active bank a to Active bank b command time
1004    `else `ifdef x8
1005        parameter ADDR_BITS        =      14; // Address Bits
1006        parameter ROW_BITS         =      14; // Number of Address bits
1007        parameter COL_BITS         =      10; // Number of Column bits
1008        parameter DM_BITS          =       1; // Number of Data Mask bits
1009        parameter DQ_BITS          =       8; // Number of Data bits
1010        parameter DQS_BITS         =       1; // Number of Dqs bits
1011        parameter TRRD             =    7500; // tRRD   Active bank a to Active bank b command time
1012    `else `define x16
1013        parameter ADDR_BITS        =      13; // Address Bits
1014        parameter ROW_BITS         =      13; // Number of Address bits
1015        parameter COL_BITS         =      10; // Number of Column bits
1016        parameter DM_BITS          =       2; // Number of Data Mask bits
1017        parameter DQ_BITS          =      16; // Number of Data bits
1018        parameter DQS_BITS         =       2; // Number of Dqs bits
1019        parameter TRRD             =   10000; // tRRD   Active bank a to Active bank b command time
1020    `endif `endif
1021
1022    `ifdef QUAD_RANK
1023        `define DUAL_RANK // also define DUAL_RANK
1024        parameter CS_BITS          =       4; // Number of Chip Select Bits
1025        parameter RANKS            =       4; // Number of Chip Select Bits
1026    `else `ifdef DUAL_RANK
1027        parameter CS_BITS          =       2; // Number of Chip Select Bits
1028        parameter RANKS            =       2; // Number of Chip Select Bits
1029    `else
1030        parameter CS_BITS          =       2; // Number of Chip Select Bits
1031        parameter RANKS            =       1; // Number of Chip Select Bits
1032    `endif `endif
1033
1034        // Size Parameters
1035        parameter BA_BITS          =       3; // Set this parmaeter to control how many Bank Address bits
1036        parameter MEM_BITS         =      10; // Number of write data bursts can be stored in memory.  The default is 2^10=1024.
1037        parameter AP               =      10; // the address bit that controls auto-precharge and precharge-all
1038        parameter BL_BITS          =       3; // the number of bits required to count to MAX_BL
1039        parameter BO_BITS          =       2; // the number of Burst Order Bits
1040
1041`else `define x2Gb
1042
1043    `ifdef sg187E
1044        parameter TCK_MIN          =    1875; // tCK    ps    Minimum Clock Cycle Time
1045        parameter TJIT_PER         =      90; // tJIT(per)  ps Period JItter
1046        parameter TJIT_DUTY        =      75; // tJIT(duty) ps Half Period Jitter
1047        parameter TJIT_CC          =     180; // tJIT(cc)   ps Cycle to Cycle jitter
1048        parameter TERR_2PER        =     132; // tERR(nper) ps Accumulated Error (2-cycle)
1049        parameter TERR_3PER        =     157; // tERR(nper) ps Accumulated Error (3-cycle)
1050        parameter TERR_4PER        =     175; // tERR(nper) ps Accumulated Error (4-cycle)
1051        parameter TERR_5PER        =     188; // tERR(nper) ps Accumulated Error (5-cycle)
1052        parameter TERR_N1PER       =     250; // tERR(nper) ps Accumulated Error (6-10-cycle)
1053        parameter TERR_N2PER       =     425; // tERR(nper) ps Accumulated Error (11-50-cycle)
1054        parameter TQHS             =     250; // tQHS   ps    Data hold skew factor
1055        parameter TAC              =     350; // tAC    ps    DQ output access time from CK/CK#
1056        parameter TDS              =       0; // tDS    ps    DQ and DM input setup time relative to DQS
1057        parameter TDH              =      75; // tDH    ps    DQ and DM input hold time relative to DQS
1058        parameter TDQSCK           =     300; // tDQSCK ps    DQS output access time from CK/CK#
1059        parameter TDQSQ            =     175; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
1060        parameter TIS              =     125; // tIS    ps    Input Setup Time
1061        parameter TIH              =     200; // tIH    ps    Input Hold Time
1062        parameter TRC              =   54000; // tRC    ps    Active to Active/Auto Refresh command time
1063        parameter TRCD             =   13125; // tRCD   ps    Active to Read/Write command time
1064        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
1065        parameter TRP              =   13125; // tRP    ps    Precharge command period
1066        parameter TRPA             =   15000; // tRPA   ps    Precharge All period
1067        parameter TXARDS           =      10; // tXARDS tCK   Exit low power active power down to a read command
1068        parameter TXARD            =       3; // tXARD  tCK   Exit active power down to a read command
1069        parameter TXP              =       3; // tXP    tCK   Exit power down to a non-read command
1070        parameter TANPD            =       4; // tANPD  tCK   ODT to power-down entry latency
1071        parameter TAXPD            =      11; // tAXPD  tCK   ODT power-down exit latency
1072        parameter CL_TIME          =   13125; // CL     ps    Minimum CAS Latency
1073    `else `ifdef sg25E
1074        parameter TCK_MIN          =    2500; // tCK    ps    Minimum Clock Cycle Time
1075        parameter TJIT_PER         =     100; // tJIT(per)  ps Period JItter
1076        parameter TJIT_DUTY        =     100; // tJIT(duty) ps Half Period Jitter
1077        parameter TJIT_CC          =     200; // tJIT(cc)   ps Cycle to Cycle jitter
1078        parameter TERR_2PER        =     150; // tERR(nper) ps Accumulated Error (2-cycle)
1079        parameter TERR_3PER        =     175; // tERR(nper) ps Accumulated Error (3-cycle)
1080        parameter TERR_4PER        =     200; // tERR(nper) ps Accumulated Error (4-cycle)
1081        parameter TERR_5PER        =     200; // tERR(nper) ps Accumulated Error (5-cycle)
1082        parameter TERR_N1PER       =     300; // tERR(nper) ps Accumulated Error (6-10-cycle)
1083        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
1084        parameter TQHS             =     300; // tQHS   ps    Data hold skew factor
1085        parameter TAC              =     400; // tAC    ps    DQ output access time from CK/CK#
1086        parameter TDS              =      50; // tDS    ps    DQ and DM input setup time relative to DQS
1087        parameter TDH              =     125; // tDH    ps    DQ and DM input hold time relative to DQS
1088        parameter TDQSCK           =     350; // tDQSCK ps    DQS output access time from CK/CK#
1089        parameter TDQSQ            =     200; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
1090        parameter TIS              =     175; // tIS    ps    Input Setup Time
1091        parameter TIH              =     250; // tIH    ps    Input Hold Time
1092        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
1093        parameter TRCD             =   12500; // tRCD   ps    Active to Read/Write command time
1094        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
1095        parameter TRP              =   12500; // tRP    ps    Precharge command period
1096        parameter TRPA             =   15000; // tRPA   ps    Precharge All period
1097        parameter TXARDS           =       8; // tXARDS tCK   Exit low power active power down to a read command
1098        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
1099        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
1100        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
1101        parameter TAXPD            =      10; // tAXPD  tCK   ODT power-down exit latency
1102        parameter CL_TIME          =   12500; // CL     ps    Minimum CAS Latency
1103    `else `ifdef sg25
1104        parameter TCK_MIN          =    2500; // tCK    ps    Minimum Clock Cycle Time
1105        parameter TJIT_PER         =     100; // tJIT(per)  ps Period JItter
1106        parameter TJIT_DUTY        =     100; // tJIT(duty) ps Half Period Jitter
1107        parameter TJIT_CC          =     200; // tJIT(cc)   ps Cycle to Cycle jitter
1108        parameter TERR_2PER        =     150; // tERR(nper) ps Accumulated Error (2-cycle)
1109        parameter TERR_3PER        =     175; // tERR(nper) ps Accumulated Error (3-cycle)
1110        parameter TERR_4PER        =     200; // tERR(nper) ps Accumulated Error (4-cycle)
1111        parameter TERR_5PER        =     200; // tERR(nper) ps Accumulated Error (5-cycle)
1112        parameter TERR_N1PER       =     300; // tERR(nper) ps Accumulated Error (6-10-cycle)
1113        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
1114        parameter TQHS             =     300; // tQHS   ps    Data hold skew factor
1115        parameter TAC              =     400; // tAC    ps    DQ output access time from CK/CK#
1116        parameter TDS              =      50; // tDS    ps    DQ and DM input setup time relative to DQS
1117        parameter TDH              =     125; // tDH    ps    DQ and DM input hold time relative to DQS
1118        parameter TDQSCK           =     350; // tDQSCK ps    DQS output access time from CK/CK#
1119        parameter TDQSQ            =     200; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
1120        parameter TIS              =     175; // tIS    ps    Input Setup Time
1121        parameter TIH              =     250; // tIH    ps    Input Hold Time
1122        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
1123        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
1124        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
1125        parameter TRP              =   15000; // tRP    ps    Precharge command period
1126        parameter TRPA             =   17500; // tRPA   ps    Precharge All period
1127        parameter TXARDS           =       8; // tXARDS tCK   Exit low power active power down to a read command
1128        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
1129        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
1130        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
1131        parameter TAXPD            =      10; // tAXPD  tCK   ODT power-down exit latency
1132        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
1133    `else `ifdef sg3E
1134        parameter TCK_MIN          =    3000; // tCK    ps    Minimum Clock Cycle Time
1135        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
1136        parameter TJIT_DUTY        =     125; // tJIT(duty) ps Half Period Jitter
1137        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
1138        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
1139        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
1140        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
1141        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
1142        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
1143        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
1144        parameter TQHS             =     340; // tQHS   ps    Data hold skew factor
1145        parameter TAC              =     450; // tAC    ps    DQ output access time from CK/CK#
1146        parameter TDS              =     100; // tDS    ps    DQ and DM input setup time relative to DQS
1147        parameter TDH              =     175; // tDH    ps    DQ and DM input hold time relative to DQS
1148        parameter TDQSCK           =     400; // tDQSCK ps    DQS output access time from CK/CK#
1149        parameter TDQSQ            =     240; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
1150        parameter TIS              =     200; // tIS    ps    Input Setup Time
1151        parameter TIH              =     275; // tIH    ps    Input Hold Time
1152        parameter TRC              =   54000; // tRC    ps    Active to Active/Auto Refresh command time
1153        parameter TRCD             =   12000; // tRCD   ps    Active to Read/Write command time
1154        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
1155        parameter TRP              =   12000; // tRP    ps    Precharge command period
1156        parameter TRPA             =   15000; // tRPA   ps    Precharge All period
1157        parameter TXARDS           =       7; // tXARDS tCK   Exit low power active power down to a read command
1158        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
1159        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
1160        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
1161        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
1162        parameter CL_TIME          =   12000; // CL     ps    Minimum CAS Latency
1163    `else `ifdef sg3
1164        parameter TCK_MIN          =    3000; // tCK    ps    Minimum Clock Cycle Time
1165        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
1166        parameter TJIT_DUTY        =     125; // tJIT(duty) ps Half Period Jitter
1167        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
1168        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
1169        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
1170        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
1171        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
1172        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
1173        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
1174        parameter TQHS             =     340; // tQHS   ps    Data hold skew factor
1175        parameter TAC              =     450; // tAC    ps    DQ output access time from CK/CK#
1176        parameter TDS              =     100; // tDS    ps    DQ and DM input setup time relative to DQS
1177        parameter TDH              =     175; // tDH    ps    DQ and DM input hold time relative to DQS
1178        parameter TDQSCK           =     400; // tDQSCK ps    DQS output access time from CK/CK#
1179        parameter TDQSQ            =     240; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
1180        parameter TIS              =     200; // tIS    ps    Input Setup Time
1181        parameter TIH              =     275; // tIH    ps    Input Hold Time
1182        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
1183        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
1184        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
1185        parameter TRP              =   15000; // tRP    ps    Precharge command period
1186        parameter TRPA             =   18000; // tRPA   ps    Precharge All period
1187        parameter TXARDS           =       7; // tXARDS tCK   Exit low power active power down to a read command
1188        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
1189        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
1190        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
1191        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
1192        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
1193    `else `ifdef sg37E
1194        parameter TCK_MIN          =    3750; // tCK    ps    Minimum Clock Cycle Time
1195        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
1196        parameter TJIT_DUTY        =     125; // tJIT(duty) ps Half Period Jitter
1197        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
1198        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
1199        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
1200        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
1201        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
1202        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
1203        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
1204        parameter TQHS             =     400; // tQHS   ps    Data hold skew factor
1205        parameter TAC              =     500; // tAC    ps    DQ output access time from CK/CK#
1206        parameter TDS              =     100; // tDS    ps    DQ and DM input setup time relative to DQS
1207        parameter TDH              =     225; // tDH    ps    DQ and DM input hold time relative to DQS
1208        parameter TDQSCK           =     450; // tDQSCK ps    DQS output access time from CK/CK#
1209        parameter TDQSQ            =     300; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
1210        parameter TIS              =     250; // tIS    ps    Input Setup Time
1211        parameter TIH              =     375; // tIH    ps    Input Hold Time
1212        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
1213        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
1214        parameter TWTR             =    7500; // tWTR   ps    Write to Read command delay
1215        parameter TRP              =   15000; // tRP    ps    Precharge command period
1216        parameter TRPA             =   18750; // tRPA   ps    Precharge All period
1217        parameter TXARDS           =       6; // tXARDS tCK   Exit low power active power down to a read command
1218        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
1219        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
1220        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
1221        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
1222        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
1223    `else `define sg5E
1224        parameter TCK_MIN          =    5000; // tCK    ps    Minimum Clock Cycle Time
1225        parameter TJIT_PER         =     125; // tJIT(per)  ps Period JItter
1226        parameter TJIT_DUTY        =     150; // tJIT(duty) ps Half Period Jitter
1227        parameter TJIT_CC          =     250; // tJIT(cc)   ps Cycle to Cycle jitter
1228        parameter TERR_2PER        =     175; // tERR(nper) ps Accumulated Error (2-cycle)
1229        parameter TERR_3PER        =     225; // tERR(nper) ps Accumulated Error (3-cycle)
1230        parameter TERR_4PER        =     250; // tERR(nper) ps Accumulated Error (4-cycle)
1231        parameter TERR_5PER        =     250; // tERR(nper) ps Accumulated Error (5-cycle)
1232        parameter TERR_N1PER       =     350; // tERR(nper) ps Accumulated Error (6-10-cycle)
1233        parameter TERR_N2PER       =     450; // tERR(nper) ps Accumulated Error (11-50-cycle)
1234        parameter TQHS             =     450; // tQHS   ps    Data hold skew factor
1235        parameter TAC              =     600; // tAC    ps    DQ output access time from CK/CK#
1236        parameter TDS              =     150; // tDS    ps    DQ and DM input setup time relative to DQS
1237        parameter TDH              =     275; // tDH    ps    DQ and DM input hold time relative to DQS
1238        parameter TDQSCK           =     500; // tDQSCK ps    DQS output access time from CK/CK#
1239        parameter TDQSQ            =     350; // tDQSQ  ps    DQS-DQ skew, DQS to last DQ valid, per group, per access
1240        parameter TIS              =     350; // tIS    ps    Input Setup Time
1241        parameter TIH              =     475; // tIH    ps    Input Hold Time
1242        parameter TRC              =   55000; // tRC    ps    Active to Active/Auto Refresh command time
1243        parameter TRCD             =   15000; // tRCD   ps    Active to Read/Write command time
1244        parameter TWTR             =   10000; // tWTR   ps    Write to Read command delay
1245        parameter TRP              =   15000; // tRP    ps    Precharge command period
1246        parameter TRPA             =   20000; // tRPA   ps    Precharge All period
1247        parameter TXARDS           =       6; // tXARDS tCK   Exit low power active power down to a read command
1248        parameter TXARD            =       2; // tXARD  tCK   Exit active power down to a read command
1249        parameter TXP              =       2; // tXP    tCK   Exit power down to a non-read command
1250        parameter TANPD            =       3; // tANPD  tCK   ODT to power-down entry latency
1251        parameter TAXPD            =       8; // tAXPD  tCK   ODT power-down exit latency
1252        parameter CL_TIME          =   15000; // CL     ps    Minimum CAS Latency
1253    `endif `endif `endif `endif `endif `endif
1254
1255    `ifdef x16
1256      `ifdef sg187E
1257        parameter TFAW             =   45000; // tFAW  ps     Four Bank Activate window
1258      `else `ifdef sg25E
1259        parameter TFAW             =   45000; // tFAW  ps     Four Bank Activate window
1260      `else `ifdef sg25
1261        parameter TFAW             =   45000; // tFAW  ps     Four Bank Activate window
1262      `else // sg3E, sg3, sg37E, sg5E
1263        parameter TFAW             =   50000; // tFAW  ps     Four Bank Activate window
1264      `endif `endif `endif
1265    `else // x4, x8
1266      `ifdef sg187E
1267        parameter TFAW             =   35000; // tFAW  ps     Four Bank Activate window
1268      `else `ifdef sg25E
1269        parameter TFAW             =   35000; // tFAW  ps     Four Bank Activate window
1270      `else `ifdef sg25
1271        parameter TFAW             =   35000; // tFAW  ps     Four Bank Activate window
1272      `else // sg3E, sg3, sg37E, sg5E
1273        parameter TFAW             =   37500; // tFAW  ps     Four Bank Activate window
1274      `endif `endif `endif
1275    `endif
1276
1277        // Timing Parameters
1278
1279        // Mode Register
1280        parameter AL_MIN           =       0; // AL     tCK   Minimum Additive Latency
1281        parameter AL_MAX           =       6; // AL     tCK   Maximum Additive Latency
1282        parameter CL_MIN           =       3; // CL     tCK   Minimum CAS Latency
1283        parameter CL_MAX           =       7; // CL     tCK   Maximum CAS Latency
1284        parameter WR_MIN           =       2; // WR     tCK   Minimum Write Recovery
1285        parameter WR_MAX           =       8; // WR     tCK   Maximum Write Recovery
1286        parameter BL_MIN           =       4; // BL     tCK   Minimum Burst Length
1287        parameter BL_MAX           =       8; // BL     tCK   Minimum Burst Length
1288        // Clock
1289        parameter TCK_MAX          =    8000; // tCK    ps    Maximum Clock Cycle Time
1290        parameter TCH_MIN          =    0.48; // tCH    tCK   Minimum Clock High-Level Pulse Width
1291        parameter TCH_MAX          =    0.52; // tCH    tCK   Maximum Clock High-Level Pulse Width
1292        parameter TCL_MIN          =    0.48; // tCL    tCK   Minimum Clock Low-Level Pulse Width
1293        parameter TCL_MAX          =    0.52; // tCL    tCK   Maximum Clock Low-Level Pulse Width
1294        // Data
1295        parameter TLZ              =     TAC; // tLZ    ps    Data-out low-impedance window from CK/CK#
1296        parameter THZ              =     TAC; // tHZ    ps    Data-out high impedance window from CK/CK#
1297        parameter TDIPW            =    0.35; // tDIPW  tCK   DQ and DM input Pulse Width
1298        // Data Strobe
1299        parameter TDQSH            =    0.35; // tDQSH  tCK   DQS input High Pulse Width
1300        parameter TDQSL            =    0.35; // tDQSL  tCK   DQS input Low Pulse Width
1301        parameter TDSS             =    0.20; // tDSS   tCK   DQS falling edge to CLK rising (setup time)
1302        parameter TDSH             =    0.20; // tDSH   tCK   DQS falling edge from CLK rising (hold time)
1303        parameter TWPRE            =    0.35; // tWPRE  tCK   DQS Write Preamble
1304        parameter TWPST            =    0.40; // tWPST  tCK   DQS Write Postamble
1305        parameter TDQSS            =    0.25; // tDQSS  tCK   Rising clock edge to DQS/DQS# latching transition
1306        // Command and Address
1307        parameter TIPW             =     0.6; // tIPW   tCK   Control and Address input Pulse Width
1308        parameter TCCD             =       2; // tCCD   tCK   Cas to Cas command delay
1309        parameter TRAS_MIN         =   40000; // tRAS   ps    Minimum Active to Precharge command time
1310        parameter TRAS_MAX         =70000000; // tRAS   ps    Maximum Active to Precharge command time
1311        parameter TRTP             =    7500; // tRTP   ps    Read to Precharge command delay
1312        parameter TWR              =   15000; // tWR    ps    Write recovery time
1313        parameter TMRD             =       2; // tMRD   tCK   Load Mode Register command cycle time
1314        parameter TDLLK            =     200; // tDLLK  tCK   DLL locking time
1315        // Refresh
1316        parameter TRFC_MIN         =  197500; // tRFC   ps    Refresh to Refresh Command interval minimum value
1317        parameter TRFC_MAX         =70000000; // tRFC   ps    Refresh to Refresh Command Interval maximum value
1318        // Self Refresh
1319        parameter TXSNR   = TRFC_MIN + 10000; // tXSNR  ps    Exit self refesh to a non-read command
1320        parameter TXSRD            =     200; // tXSRD  tCK   Exit self refresh to a read command
1321        parameter TISXR            =     TIS; // tISXR  ps    CKE setup time during self refresh exit.
1322        // ODT
1323        parameter TAOND            =       2; // tAOND  tCK   ODT turn-on delay
1324        parameter TAOFD            =     2.5; // tAOFD  tCK   ODT turn-off delay
1325        parameter TAONPD           =    2000; // tAONPD ps    ODT turn-on (precharge power-down mode)
1326        parameter TAOFPD           =    2000; // tAOFPD ps    ODT turn-off (precharge power-down mode)
1327        parameter TMOD             =   12000; // tMOD   ps    ODT enable in EMR to ODT pin transition
1328        // Power Down
1329        parameter TCKE             =       3; // tCKE   tCK   CKE minimum high or low pulse width
1330
1331        // Size Parameters based on Part Width
1332
1333    `ifdef x4
1334        parameter ADDR_BITS        =      15; // Address Bits
1335        parameter ROW_BITS         =      15; // Number of Address bits
1336        parameter COL_BITS         =      11; // Number of Column bits
1337        parameter DM_BITS          =       1; // Number of Data Mask bits
1338        parameter DQ_BITS          =       4; // Number of Data bits
1339        parameter DQS_BITS         =       1; // Number of Dqs bits
1340        parameter TRRD             =    7500; // tRRD   Active bank a to Active bank b command time
1341    `else `ifdef x8
1342        parameter ADDR_BITS        =      15; // Address Bits
1343        parameter ROW_BITS         =      15; // Number of Address bits
1344        parameter COL_BITS         =      10; // Number of Column bits
1345        parameter DM_BITS          =       1; // Number of Data Mask bits
1346        parameter DQ_BITS          =       8; // Number of Data bits
1347        parameter DQS_BITS         =       1; // Number of Dqs bits
1348        parameter TRRD             =    7500; // tRRD   Active bank a to Active bank b command time
1349    `else `define x16
1350        parameter ADDR_BITS        =      14; // Address Bits
1351        parameter ROW_BITS         =      14; // Number of Address bits
1352        parameter COL_BITS         =      10; // Number of Column bits
1353        parameter DM_BITS          =       2; // Number of Data Mask bits
1354        parameter DQ_BITS          =      16; // Number of Data bits
1355        parameter DQS_BITS         =       2; // Number of Dqs bits
1356        parameter TRRD             =   10000; // tRRD   Active bank a to Active bank b command time
1357    `endif `endif
1358
1359    `ifdef QUAD_RANK
1360        `define DUAL_RANK // also define DUAL_RANK
1361        parameter CS_BITS          =       4; // Number of Chip Select Bits
1362        parameter RANKS            =       4; // Number of Chip Select Bits
1363    `else `ifdef DUAL_RANK
1364        parameter CS_BITS          =       2; // Number of Chip Select Bits
1365        parameter RANKS            =       2; // Number of Chip Select Bits
1366    `else
1367        parameter CS_BITS          =       2; // Number of Chip Select Bits
1368        parameter RANKS            =       1; // Number of Chip Select Bits
1369    `endif `endif
1370
1371        // Size Parameters
1372        parameter BA_BITS          =       3; // Set this parmaeter to control how many Bank Address bits
1373        parameter MEM_BITS         =      10; // Number of write data bursts can be stored in memory.  The default is 2^10=1024.
1374        parameter AP               =      10; // the address bit that controls auto-precharge and precharge-all
1375        parameter BL_BITS          =       3; // the number of bits required to count to MAX_BL
1376        parameter BO_BITS          =       2; // the number of Burst Order Bits
1377
1378`endif `endif `endif
1379
1380    // Simulation parameters
1381    parameter STOP_ON_ERROR    =       1; // If set to 1, the model will halt on command sequence/major errors
1382    parameter DEBUG            =       1; // Turn on Debug messages
1383    parameter BUS_DELAY        =       0; // delay in nanoseconds
1384    parameter RANDOM_OUT_DELAY =       0; // If set to 1, the model will put a random amount of delay on DQ/DQS during reads
1385    parameter RANDOM_SEED      = 711689044; //seed value for random generator.
1386
1387    parameter RDQSEN_PRE       =       2; // DQS driving time prior to first read strobe
1388    parameter RDQSEN_PST       =       1; // DQS driving time after last read strobe
1389    parameter RDQS_PRE         =       2; // DQS low time prior to first read strobe
1390    parameter RDQS_PST         =       1; // DQS low time after last valid read strobe
1391    parameter RDQEN_PRE        =       0; // DQ/DM driving time prior to first read data
1392    parameter RDQEN_PST        =       0; // DQ/DM driving time after last read data
1393    parameter WDQS_PRE         =       1; // DQS half clock periods prior to first write strobe
1394    parameter WDQS_PST         =       1; // DQS half clock periods after last valid write strobe
Note: See TracBrowser for help on using the repository browser.