-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathflash_write_buffer.vhd
261 lines (248 loc) · 16.6 KB
/
flash_write_buffer.vhd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
-- VHDL netlist generated by SCUBA Diamond (64-bit) 3.10.2.115
-- Module Version: 7.5
--C:\lscc\diamond\3.10_x64\ispfpga\bin\nt64\scuba.exe -w -n flash_write_buffer -lang vhdl -synth synplify -bus_exp 7 -bb -arch xo2c00 -type bram -wp 11 -rp 1010 -data_width 16 -rdata_width 16 -num_rows 64 -cascade -1 -mem_init0 -writemodeA NORMAL -writemodeB NORMAL
-- Sat Jul 21 13:14:05 2018
library IEEE;
use IEEE.std_logic_1164.all;
-- synopsys translate_off
library MACHXO2;
use MACHXO2.components.all;
-- synopsys translate_on
entity flash_write_buffer is
port (
DataInA: in std_logic_vector(15 downto 0);
DataInB: in std_logic_vector(15 downto 0);
AddressA: in std_logic_vector(5 downto 0);
AddressB: in std_logic_vector(5 downto 0);
ClockA: in std_logic;
ClockB: in std_logic;
ClockEnA: in std_logic;
ClockEnB: in std_logic;
WrA: in std_logic;
WrB: in std_logic;
ResetA: in std_logic;
ResetB: in std_logic;
QA: out std_logic_vector(15 downto 0);
QB: out std_logic_vector(15 downto 0));
end flash_write_buffer;
architecture Structure of flash_write_buffer is
-- internal signal declarations
signal scuba_vhi: std_logic;
signal scuba_vlo: std_logic;
-- local component declarations
component VHI
port (Z: out std_logic);
end component;
component VLO
port (Z: out std_logic);
end component;
component DP8KC
generic (INIT_DATA : in String; INITVAL_1F : in String;
INITVAL_1E : in String; INITVAL_1D : in String;
INITVAL_1C : in String; INITVAL_1B : in String;
INITVAL_1A : in String; INITVAL_19 : in String;
INITVAL_18 : in String; INITVAL_17 : in String;
INITVAL_16 : in String; INITVAL_15 : in String;
INITVAL_14 : in String; INITVAL_13 : in String;
INITVAL_12 : in String; INITVAL_11 : in String;
INITVAL_10 : in String; INITVAL_0F : in String;
INITVAL_0E : in String; INITVAL_0D : in String;
INITVAL_0C : in String; INITVAL_0B : in String;
INITVAL_0A : in String; INITVAL_09 : in String;
INITVAL_08 : in String; INITVAL_07 : in String;
INITVAL_06 : in String; INITVAL_05 : in String;
INITVAL_04 : in String; INITVAL_03 : in String;
INITVAL_02 : in String; INITVAL_01 : in String;
INITVAL_00 : in String; ASYNC_RESET_RELEASE : in String;
RESETMODE : in String; GSR : in String;
WRITEMODE_B : in String; WRITEMODE_A : in String;
CSDECODE_B : in String; CSDECODE_A : in String;
REGMODE_B : in String; REGMODE_A : in String;
DATA_WIDTH_B : in Integer; DATA_WIDTH_A : in Integer);
port (DIA8: in std_logic; DIA7: in std_logic;
DIA6: in std_logic; DIA5: in std_logic;
DIA4: in std_logic; DIA3: in std_logic;
DIA2: in std_logic; DIA1: in std_logic;
DIA0: in std_logic; ADA12: in std_logic;
ADA11: in std_logic; ADA10: in std_logic;
ADA9: in std_logic; ADA8: in std_logic;
ADA7: in std_logic; ADA6: in std_logic;
ADA5: in std_logic; ADA4: in std_logic;
ADA3: in std_logic; ADA2: in std_logic;
ADA1: in std_logic; ADA0: in std_logic; CEA: in std_logic;
OCEA: in std_logic; CLKA: in std_logic; WEA: in std_logic;
CSA2: in std_logic; CSA1: in std_logic;
CSA0: in std_logic; RSTA: in std_logic;
DIB8: in std_logic; DIB7: in std_logic;
DIB6: in std_logic; DIB5: in std_logic;
DIB4: in std_logic; DIB3: in std_logic;
DIB2: in std_logic; DIB1: in std_logic;
DIB0: in std_logic; ADB12: in std_logic;
ADB11: in std_logic; ADB10: in std_logic;
ADB9: in std_logic; ADB8: in std_logic;
ADB7: in std_logic; ADB6: in std_logic;
ADB5: in std_logic; ADB4: in std_logic;
ADB3: in std_logic; ADB2: in std_logic;
ADB1: in std_logic; ADB0: in std_logic; CEB: in std_logic;
OCEB: in std_logic; CLKB: in std_logic; WEB: in std_logic;
CSB2: in std_logic; CSB1: in std_logic;
CSB0: in std_logic; RSTB: in std_logic;
DOA8: out std_logic; DOA7: out std_logic;
DOA6: out std_logic; DOA5: out std_logic;
DOA4: out std_logic; DOA3: out std_logic;
DOA2: out std_logic; DOA1: out std_logic;
DOA0: out std_logic; DOB8: out std_logic;
DOB7: out std_logic; DOB6: out std_logic;
DOB5: out std_logic; DOB4: out std_logic;
DOB3: out std_logic; DOB2: out std_logic;
DOB1: out std_logic; DOB0: out std_logic);
end component;
attribute MEM_LPC_FILE : string;
attribute MEM_INIT_FILE : string;
attribute MEM_LPC_FILE of flash_write_buffer_0_0_1 : label is "flash_write_buffer.lpc";
attribute MEM_INIT_FILE of flash_write_buffer_0_0_1 : label is "INIT_ALL_0s";
attribute MEM_LPC_FILE of flash_write_buffer_0_1_0 : label is "flash_write_buffer.lpc";
attribute MEM_INIT_FILE of flash_write_buffer_0_1_0 : label is "INIT_ALL_0s";
attribute NGD_DRC_MASK : integer;
attribute NGD_DRC_MASK of Structure : architecture is 1;
begin
-- component instantiation statements
flash_write_buffer_0_0_1: DP8KC
generic map (INIT_DATA=> "STATIC", ASYNC_RESET_RELEASE=> "SYNC",
INITVAL_1F=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_1E=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_1D=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_1C=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_1B=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_1A=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_19=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_18=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_17=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_16=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_15=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_14=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_13=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_12=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_11=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_10=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_0F=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_0E=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_0D=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_0C=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_0B=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_0A=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_09=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_08=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_07=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_06=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_05=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_04=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_03=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_02=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_01=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_00=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
CSDECODE_B=> "0b000", CSDECODE_A=> "0b000", WRITEMODE_B=> "NORMAL",
WRITEMODE_A=> "NORMAL", GSR=> "ENABLED", RESETMODE=> "ASYNC",
REGMODE_B=> "NOREG", REGMODE_A=> "NOREG", DATA_WIDTH_B=> 9,
DATA_WIDTH_A=> 9)
port map (DIA8=>DataInA(8), DIA7=>DataInA(7), DIA6=>DataInA(6),
DIA5=>DataInA(5), DIA4=>DataInA(4), DIA3=>DataInA(3),
DIA2=>DataInA(2), DIA1=>DataInA(1), DIA0=>DataInA(0),
ADA12=>scuba_vlo, ADA11=>scuba_vlo, ADA10=>scuba_vlo,
ADA9=>scuba_vlo, ADA8=>AddressA(5), ADA7=>AddressA(4),
ADA6=>AddressA(3), ADA5=>AddressA(2), ADA4=>AddressA(1),
ADA3=>AddressA(0), ADA2=>scuba_vlo, ADA1=>scuba_vlo,
ADA0=>scuba_vhi, CEA=>ClockEnA, OCEA=>ClockEnA, CLKA=>ClockA,
WEA=>WrA, CSA2=>scuba_vlo, CSA1=>scuba_vlo, CSA0=>scuba_vlo,
RSTA=>ResetA, DIB8=>DataInB(8), DIB7=>DataInB(7),
DIB6=>DataInB(6), DIB5=>DataInB(5), DIB4=>DataInB(4),
DIB3=>DataInB(3), DIB2=>DataInB(2), DIB1=>DataInB(1),
DIB0=>DataInB(0), ADB12=>scuba_vlo, ADB11=>scuba_vlo,
ADB10=>scuba_vlo, ADB9=>scuba_vlo, ADB8=>AddressB(5),
ADB7=>AddressB(4), ADB6=>AddressB(3), ADB5=>AddressB(2),
ADB4=>AddressB(1), ADB3=>AddressB(0), ADB2=>scuba_vlo,
ADB1=>scuba_vlo, ADB0=>scuba_vhi, CEB=>ClockEnB,
OCEB=>ClockEnB, CLKB=>ClockB, WEB=>WrB, CSB2=>scuba_vlo,
CSB1=>scuba_vlo, CSB0=>scuba_vlo, RSTB=>ResetB, DOA8=>QA(8),
DOA7=>QA(7), DOA6=>QA(6), DOA5=>QA(5), DOA4=>QA(4),
DOA3=>QA(3), DOA2=>QA(2), DOA1=>QA(1), DOA0=>QA(0),
DOB8=>QB(8), DOB7=>QB(7), DOB6=>QB(6), DOB5=>QB(5),
DOB4=>QB(4), DOB3=>QB(3), DOB2=>QB(2), DOB1=>QB(1),
DOB0=>QB(0));
scuba_vhi_inst: VHI
port map (Z=>scuba_vhi);
scuba_vlo_inst: VLO
port map (Z=>scuba_vlo);
flash_write_buffer_0_1_0: DP8KC
generic map (INIT_DATA=> "STATIC", ASYNC_RESET_RELEASE=> "SYNC",
INITVAL_1F=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_1E=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_1D=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_1C=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_1B=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_1A=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_19=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_18=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_17=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_16=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_15=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_14=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_13=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_12=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_11=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_10=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_0F=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_0E=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_0D=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_0C=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_0B=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_0A=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_09=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_08=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_07=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_06=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_05=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_04=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_03=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_02=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_01=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
INITVAL_00=> "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000",
CSDECODE_B=> "0b000", CSDECODE_A=> "0b000", WRITEMODE_B=> "NORMAL",
WRITEMODE_A=> "NORMAL", GSR=> "ENABLED", RESETMODE=> "ASYNC",
REGMODE_B=> "NOREG", REGMODE_A=> "NOREG", DATA_WIDTH_B=> 9,
DATA_WIDTH_A=> 9)
port map (DIA8=>scuba_vlo, DIA7=>scuba_vlo, DIA6=>DataInA(15),
DIA5=>DataInA(14), DIA4=>DataInA(13), DIA3=>DataInA(12),
DIA2=>DataInA(11), DIA1=>DataInA(10), DIA0=>DataInA(9),
ADA12=>scuba_vlo, ADA11=>scuba_vlo, ADA10=>scuba_vlo,
ADA9=>scuba_vlo, ADA8=>AddressA(5), ADA7=>AddressA(4),
ADA6=>AddressA(3), ADA5=>AddressA(2), ADA4=>AddressA(1),
ADA3=>AddressA(0), ADA2=>scuba_vlo, ADA1=>scuba_vlo,
ADA0=>scuba_vhi, CEA=>ClockEnA, OCEA=>ClockEnA, CLKA=>ClockA,
WEA=>WrA, CSA2=>scuba_vlo, CSA1=>scuba_vlo, CSA0=>scuba_vlo,
RSTA=>ResetA, DIB8=>scuba_vlo, DIB7=>scuba_vlo,
DIB6=>DataInB(15), DIB5=>DataInB(14), DIB4=>DataInB(13),
DIB3=>DataInB(12), DIB2=>DataInB(11), DIB1=>DataInB(10),
DIB0=>DataInB(9), ADB12=>scuba_vlo, ADB11=>scuba_vlo,
ADB10=>scuba_vlo, ADB9=>scuba_vlo, ADB8=>AddressB(5),
ADB7=>AddressB(4), ADB6=>AddressB(3), ADB5=>AddressB(2),
ADB4=>AddressB(1), ADB3=>AddressB(0), ADB2=>scuba_vlo,
ADB1=>scuba_vlo, ADB0=>scuba_vhi, CEB=>ClockEnB,
OCEB=>ClockEnB, CLKB=>ClockB, WEB=>WrB, CSB2=>scuba_vlo,
CSB1=>scuba_vlo, CSB0=>scuba_vlo, RSTB=>ResetB, DOA8=>open,
DOA7=>open, DOA6=>QA(15), DOA5=>QA(14), DOA4=>QA(13),
DOA3=>QA(12), DOA2=>QA(11), DOA1=>QA(10), DOA0=>QA(9),
DOB8=>open, DOB7=>open, DOB6=>QB(15), DOB5=>QB(14),
DOB4=>QB(13), DOB3=>QB(12), DOB2=>QB(11), DOB1=>QB(10),
DOB0=>QB(9));
end Structure;
-- synopsys translate_off
library MACHXO2;
configuration Structure_CON of flash_write_buffer is
for Structure
for all:VHI use entity MACHXO2.VHI(V); end for;
for all:VLO use entity MACHXO2.VLO(V); end for;
for all:DP8KC use entity MACHXO2.DP8KC(V); end for;
end for;
end Structure_CON;
-- synopsys translate_on