Skip to content

Commit 89f84f3

Browse files
committed
Adding CE224285
1 parent ba4a433 commit 89f84f3

File tree

12 files changed

+1879
-0
lines changed

12 files changed

+1879
-0
lines changed
Lines changed: 264 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,264 @@
1+
/*******************************************************************************
2+
* File Name: cycfg_qspi_memslot.c
3+
*
4+
* Description:
5+
* Provides definitions of the SMIF-driver memory configuration.
6+
* This file was automatically generated and should not be modified.
7+
*
8+
********************************************************************************
9+
* Copyright 2017-2019 Cypress Semiconductor Corporation
10+
* SPDX-License-Identifier: Apache-2.0
11+
*
12+
* Licensed under the Apache License, Version 2.0 (the "License");
13+
* you may not use this file except in compliance with the License.
14+
* You may obtain a copy of the License at
15+
*
16+
* http://www.apache.org/licenses/LICENSE-2.0
17+
*
18+
* Unless required by applicable law or agreed to in writing, software
19+
* distributed under the License is distributed on an "AS IS" BASIS,
20+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
21+
* See the License for the specific language governing permissions and
22+
* limitations under the License.
23+
********************************************************************************/
24+
25+
#include "cycfg_qspi_memslot.h"
26+
27+
const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_readCmd =
28+
{
29+
/* The 8-bit command. 1 x I/O read command. */
30+
.command = 0xEBU,
31+
/* The width of the command transfer. */
32+
.cmdWidth = CY_SMIF_WIDTH_SINGLE,
33+
/* The width of the address transfer. */
34+
.addrWidth = CY_SMIF_WIDTH_QUAD,
35+
/* The 8-bit mode byte. This value is 0xFFFFFFFF when there is no mode present. */
36+
.mode = 0x01U,
37+
/* The width of the mode command transfer. */
38+
.modeWidth = CY_SMIF_WIDTH_QUAD,
39+
/* The number of dummy cycles. A zero value suggests no dummy cycles. */
40+
.dummyCycles = 4U,
41+
/* The width of the data transfer. */
42+
.dataWidth = CY_SMIF_WIDTH_QUAD
43+
};
44+
45+
const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_writeEnCmd =
46+
{
47+
/* The 8-bit command. 1 x I/O read command. */
48+
.command = 0x06U,
49+
/* The width of the command transfer. */
50+
.cmdWidth = CY_SMIF_WIDTH_SINGLE,
51+
/* The width of the address transfer. */
52+
.addrWidth = CY_SMIF_WIDTH_SINGLE,
53+
/* The 8-bit mode byte. This value is 0xFFFFFFFF when there is no mode present. */
54+
.mode = 0xFFFFFFFFU,
55+
/* The width of the mode command transfer. */
56+
.modeWidth = CY_SMIF_WIDTH_SINGLE,
57+
/* The number of dummy cycles. A zero value suggests no dummy cycles. */
58+
.dummyCycles = 0U,
59+
/* The width of the data transfer. */
60+
.dataWidth = CY_SMIF_WIDTH_SINGLE
61+
};
62+
63+
const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_writeDisCmd =
64+
{
65+
/* The 8-bit command. 1 x I/O read command. */
66+
.command = 0x04U,
67+
/* The width of the command transfer. */
68+
.cmdWidth = CY_SMIF_WIDTH_SINGLE,
69+
/* The width of the address transfer. */
70+
.addrWidth = CY_SMIF_WIDTH_SINGLE,
71+
/* The 8-bit mode byte. This value is 0xFFFFFFFF when there is no mode present. */
72+
.mode = 0xFFFFFFFFU,
73+
/* The width of the mode command transfer. */
74+
.modeWidth = CY_SMIF_WIDTH_SINGLE,
75+
/* The number of dummy cycles. A zero value suggests no dummy cycles. */
76+
.dummyCycles = 0U,
77+
/* The width of the data transfer. */
78+
.dataWidth = CY_SMIF_WIDTH_SINGLE
79+
};
80+
81+
const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_eraseCmd =
82+
{
83+
/* The 8-bit command. 1 x I/O read command. */
84+
.command = 0xD8U,
85+
/* The width of the command transfer. */
86+
.cmdWidth = CY_SMIF_WIDTH_SINGLE,
87+
/* The width of the address transfer. */
88+
.addrWidth = CY_SMIF_WIDTH_SINGLE,
89+
/* The 8-bit mode byte. This value is 0xFFFFFFFF when there is no mode present. */
90+
.mode = 0xFFFFFFFFU,
91+
/* The width of the mode command transfer. */
92+
.modeWidth = CY_SMIF_WIDTH_SINGLE,
93+
/* The number of dummy cycles. A zero value suggests no dummy cycles. */
94+
.dummyCycles = 0U,
95+
/* The width of the data transfer. */
96+
.dataWidth = CY_SMIF_WIDTH_SINGLE
97+
};
98+
99+
const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_chipEraseCmd =
100+
{
101+
/* The 8-bit command. 1 x I/O read command. */
102+
.command = 0x60U,
103+
/* The width of the command transfer. */
104+
.cmdWidth = CY_SMIF_WIDTH_SINGLE,
105+
/* The width of the address transfer. */
106+
.addrWidth = CY_SMIF_WIDTH_SINGLE,
107+
/* The 8-bit mode byte. This value is 0xFFFFFFFF when there is no mode present. */
108+
.mode = 0xFFFFFFFFU,
109+
/* The width of the mode command transfer. */
110+
.modeWidth = CY_SMIF_WIDTH_SINGLE,
111+
/* The number of dummy cycles. A zero value suggests no dummy cycles. */
112+
.dummyCycles = 0U,
113+
/* The width of the data transfer. */
114+
.dataWidth = CY_SMIF_WIDTH_SINGLE
115+
};
116+
117+
const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_programCmd =
118+
{
119+
/* The 8-bit command. 1 x I/O read command. */
120+
.command = 0x38U,
121+
/* The width of the command transfer. */
122+
.cmdWidth = CY_SMIF_WIDTH_SINGLE,
123+
/* The width of the address transfer. */
124+
.addrWidth = CY_SMIF_WIDTH_SINGLE,
125+
/* The 8-bit mode byte. This value is 0xFFFFFFFF when there is no mode present. */
126+
.mode = 0xFFFFFFFFU,
127+
/* The width of the mode command transfer. */
128+
.modeWidth = CY_SMIF_WIDTH_QUAD,
129+
/* The number of dummy cycles. A zero value suggests no dummy cycles. */
130+
.dummyCycles = 0U,
131+
/* The width of the data transfer. */
132+
.dataWidth = CY_SMIF_WIDTH_QUAD
133+
};
134+
135+
const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_readStsRegQeCmd =
136+
{
137+
/* The 8-bit command. 1 x I/O read command. */
138+
.command = 0x35U,
139+
/* The width of the command transfer. */
140+
.cmdWidth = CY_SMIF_WIDTH_SINGLE,
141+
/* The width of the address transfer. */
142+
.addrWidth = CY_SMIF_WIDTH_SINGLE,
143+
/* The 8-bit mode byte. This value is 0xFFFFFFFF when there is no mode present. */
144+
.mode = 0xFFFFFFFFU,
145+
/* The width of the mode command transfer. */
146+
.modeWidth = CY_SMIF_WIDTH_SINGLE,
147+
/* The number of dummy cycles. A zero value suggests no dummy cycles. */
148+
.dummyCycles = 0U,
149+
/* The width of the data transfer. */
150+
.dataWidth = CY_SMIF_WIDTH_SINGLE
151+
};
152+
153+
const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_readStsRegWipCmd =
154+
{
155+
/* The 8-bit command. 1 x I/O read command. */
156+
.command = 0x05U,
157+
/* The width of the command transfer. */
158+
.cmdWidth = CY_SMIF_WIDTH_SINGLE,
159+
/* The width of the address transfer. */
160+
.addrWidth = CY_SMIF_WIDTH_SINGLE,
161+
/* The 8-bit mode byte. This value is 0xFFFFFFFF when there is no mode present. */
162+
.mode = 0xFFFFFFFFU,
163+
/* The width of the mode command transfer. */
164+
.modeWidth = CY_SMIF_WIDTH_SINGLE,
165+
/* The number of dummy cycles. A zero value suggests no dummy cycles. */
166+
.dummyCycles = 0U,
167+
/* The width of the data transfer. */
168+
.dataWidth = CY_SMIF_WIDTH_SINGLE
169+
};
170+
171+
const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_writeStsRegQeCmd =
172+
{
173+
/* The 8-bit command. 1 x I/O read command. */
174+
.command = 0x01U,
175+
/* The width of the command transfer. */
176+
.cmdWidth = CY_SMIF_WIDTH_SINGLE,
177+
/* The width of the address transfer. */
178+
.addrWidth = CY_SMIF_WIDTH_SINGLE,
179+
/* The 8-bit mode byte. This value is 0xFFFFFFFF when there is no mode present. */
180+
.mode = 0xFFFFFFFFU,
181+
/* The width of the mode command transfer. */
182+
.modeWidth = CY_SMIF_WIDTH_SINGLE,
183+
/* The number of dummy cycles. A zero value suggests no dummy cycles. */
184+
.dummyCycles = 0U,
185+
/* The width of the data transfer. */
186+
.dataWidth = CY_SMIF_WIDTH_SINGLE
187+
};
188+
189+
const cy_stc_smif_mem_device_cfg_t deviceCfg_S25FL512S_SlaveSlot_0 =
190+
{
191+
/* Specifies the number of address bytes used by the memory slave device. */
192+
.numOfAddrBytes = 0x03U,
193+
/* The size of the memory. */
194+
.memSize = 0x04000000U,
195+
/* Specifies the Read command. */
196+
.readCmd = (cy_stc_smif_mem_cmd_t*)&S25FL512S_SlaveSlot_0_readCmd,
197+
/* Specifies the Write Enable command. */
198+
.writeEnCmd = (cy_stc_smif_mem_cmd_t*)&S25FL512S_SlaveSlot_0_writeEnCmd,
199+
/* Specifies the Write Disable command. */
200+
.writeDisCmd = (cy_stc_smif_mem_cmd_t*)&S25FL512S_SlaveSlot_0_writeDisCmd,
201+
/* Specifies the Erase command. */
202+
.eraseCmd = (cy_stc_smif_mem_cmd_t*)&S25FL512S_SlaveSlot_0_eraseCmd,
203+
/* Specifies the sector size of each erase. */
204+
.eraseSize = 0x00040000U,
205+
/* Specifies the Chip Erase command. */
206+
.chipEraseCmd = (cy_stc_smif_mem_cmd_t*)&S25FL512S_SlaveSlot_0_chipEraseCmd,
207+
/* Specifies the Program command. */
208+
.programCmd = (cy_stc_smif_mem_cmd_t*)&S25FL512S_SlaveSlot_0_programCmd,
209+
/* Specifies the page size for programming. */
210+
.programSize = 0x00000200U,
211+
/* Specifies the command to read the QE-containing status register. */
212+
.readStsRegQeCmd = (cy_stc_smif_mem_cmd_t*)&S25FL512S_SlaveSlot_0_readStsRegQeCmd,
213+
/* Specifies the command to read the WIP-containing status register. */
214+
.readStsRegWipCmd = (cy_stc_smif_mem_cmd_t*)&S25FL512S_SlaveSlot_0_readStsRegWipCmd,
215+
/* Specifies the command to write into the QE-containing status register. */
216+
.writeStsRegQeCmd = (cy_stc_smif_mem_cmd_t*)&S25FL512S_SlaveSlot_0_writeStsRegQeCmd,
217+
/* The mask for the status register. */
218+
.stsRegBusyMask = 0x01U,
219+
/* The mask for the status register. */
220+
.stsRegQuadEnableMask = 0x02U,
221+
/* The max time for the erase type-1 cycle-time in ms. */
222+
.eraseTime = 520U,
223+
/* The max time for the chip-erase cycle-time in ms. */
224+
.chipEraseTime = 134000U,
225+
/* The max time for the page-program cycle-time in us. */
226+
.programTime = 340U
227+
};
228+
229+
const cy_stc_smif_mem_config_t S25FL512S_SlaveSlot_0 =
230+
{
231+
/* Determines the slot number where the memory device is placed. */
232+
.slaveSelect = CY_SMIF_SLAVE_SELECT_0,
233+
/* Flags. */
234+
.flags = CY_SMIF_FLAG_MEMORY_MAPPED | CY_SMIF_FLAG_WR_EN,
235+
/* The data-line selection options for a slave device. */
236+
.dataSelect = CY_SMIF_DATA_SEL0,
237+
/* The base address the memory slave is mapped to in the PSoC memory map.
238+
Valid when the memory-mapped mode is enabled. */
239+
.baseAddress = 0x18000000U,
240+
/* The size allocated in the PSoC memory map, for the memory slave device.
241+
The size is allocated from the base address. Valid when the memory mapped mode is enabled. */
242+
.memMappedSize = 0x10000U,
243+
/* If this memory device is one of the devices in the dual quad SPI configuration.
244+
Valid when the memory mapped mode is enabled. */
245+
.dualQuadSlots = 0,
246+
/* The configuration of the device. */
247+
.deviceCfg = (cy_stc_smif_mem_device_cfg_t*)&deviceCfg_S25FL512S_SlaveSlot_0
248+
};
249+
250+
const cy_stc_smif_mem_config_t* const smifMemConfigs[] = {
251+
&S25FL512S_SlaveSlot_0
252+
};
253+
254+
const cy_stc_smif_block_config_t smifBlockConfig =
255+
{
256+
/* The number of SMIF memories defined. */
257+
.memCount = CY_SMIF_DEVICE_NUM,
258+
/* The pointer to the array of memory config structures of size memCount. */
259+
.memConfig = (cy_stc_smif_mem_config_t**)smifMemConfigs,
260+
/* The version of the SMIF driver. */
261+
.majorVersion = CY_SMIF_DRV_VERSION_MAJOR,
262+
/* The version of the SMIF driver. */
263+
.minorVersion = CY_SMIF_DRV_VERSION_MINOR
264+
};
Lines changed: 119 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,119 @@
1+
/*******************************************************************************
2+
* File Name: cycfg_qspi_memslot.h
3+
*
4+
* Description:
5+
* Provides declarations of the SMIF-driver memory configuration.
6+
* This file was automatically generated and should not be modified.
7+
*
8+
********************************************************************************
9+
* Copyright 2017-2019 Cypress Semiconductor Corporation
10+
* SPDX-License-Identifier: Apache-2.0
11+
*
12+
* Licensed under the Apache License, Version 2.0 (the "License");
13+
* you may not use this file except in compliance with the License.
14+
* You may obtain a copy of the License at
15+
*
16+
* http://www.apache.org/licenses/LICENSE-2.0
17+
*
18+
* Unless required by applicable law or agreed to in writing, software
19+
* distributed under the License is distributed on an "AS IS" BASIS,
20+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
21+
* See the License for the specific language governing permissions and
22+
* limitations under the License.
23+
********************************************************************************/
24+
25+
/*******************************************************************************
26+
27+
QSPI_CONFIG_START
28+
29+
<CySMIFConfiguration>
30+
<DevicePath>PSoC 6.xml</DevicePath>
31+
<SlotConfigs>
32+
<SlotConfig>
33+
<SlaveSlot>0</SlaveSlot>
34+
<PartNumber>S25FL512S</PartNumber>
35+
<MemoryMapped>true</MemoryMapped>
36+
<DualQuad>None</DualQuad>
37+
<StartAddress>0x18000000</StartAddress>
38+
<Size>0x10000</Size>
39+
<EndAddress>0x1800FFFF</EndAddress>
40+
<WriteEnable>true</WriteEnable>
41+
<Encrypt>false</Encrypt>
42+
<DataSelect>QUAD_SPI_DATA_0_3</DataSelect>
43+
<MemoryConfigsPath>S25FL512S</MemoryConfigsPath>
44+
<ConfigDataInFlash>true</ConfigDataInFlash>
45+
</SlotConfig>
46+
<SlotConfig>
47+
<SlaveSlot>1</SlaveSlot>
48+
<PartNumber>Not used</PartNumber>
49+
<MemoryMapped>false</MemoryMapped>
50+
<DualQuad>None</DualQuad>
51+
<StartAddress>0x18010000</StartAddress>
52+
<Size>0x10000</Size>
53+
<EndAddress>0x1801FFFF</EndAddress>
54+
<WriteEnable>false</WriteEnable>
55+
<Encrypt>false</Encrypt>
56+
<DataSelect>SPI_MOSI_MISO_DATA_0_1</DataSelect>
57+
<MemoryConfigsPath>default_memory.xml</MemoryConfigsPath>
58+
<ConfigDataInFlash>false</ConfigDataInFlash>
59+
</SlotConfig>
60+
<SlotConfig>
61+
<SlaveSlot>2</SlaveSlot>
62+
<PartNumber>Not used</PartNumber>
63+
<MemoryMapped>false</MemoryMapped>
64+
<DualQuad>None</DualQuad>
65+
<StartAddress>0x18020000</StartAddress>
66+
<Size>0x10000</Size>
67+
<EndAddress>0x1802FFFF</EndAddress>
68+
<WriteEnable>false</WriteEnable>
69+
<Encrypt>false</Encrypt>
70+
<DataSelect>SPI_MOSI_MISO_DATA_0_1</DataSelect>
71+
<MemoryConfigsPath>default_memory.xml</MemoryConfigsPath>
72+
<ConfigDataInFlash>false</ConfigDataInFlash>
73+
</SlotConfig>
74+
<SlotConfig>
75+
<SlaveSlot>3</SlaveSlot>
76+
<PartNumber>Not used</PartNumber>
77+
<MemoryMapped>false</MemoryMapped>
78+
<DualQuad>None</DualQuad>
79+
<StartAddress>0x18030000</StartAddress>
80+
<Size>0x10000</Size>
81+
<EndAddress>0x1803FFFF</EndAddress>
82+
<WriteEnable>false</WriteEnable>
83+
<Encrypt>false</Encrypt>
84+
<DataSelect>SPI_MOSI_MISO_DATA_0_1</DataSelect>
85+
<MemoryConfigsPath>default_memory.xml</MemoryConfigsPath>
86+
<ConfigDataInFlash>false</ConfigDataInFlash>
87+
</SlotConfig>
88+
</SlotConfigs>
89+
</CySMIFConfiguration>
90+
91+
QSPI_CONFIG_END
92+
93+
*******************************************************************************/
94+
95+
#ifndef CYCFG_QSPI_MEMSLOT_H
96+
#define CYCFG_QSPI_MEMSLOT_H
97+
#include "cy_smif_memslot.h"
98+
99+
#define CY_SMIF_DEVICE_NUM 1
100+
101+
extern const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_readCmd;
102+
extern const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_writeEnCmd;
103+
extern const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_writeDisCmd;
104+
extern const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_eraseCmd;
105+
extern const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_chipEraseCmd;
106+
extern const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_programCmd;
107+
extern const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_readStsRegQeCmd;
108+
extern const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_readStsRegWipCmd;
109+
extern const cy_stc_smif_mem_cmd_t S25FL512S_SlaveSlot_0_writeStsRegQeCmd;
110+
111+
extern const cy_stc_smif_mem_device_cfg_t deviceCfg_S25FL512S_SlaveSlot_0;
112+
113+
extern const cy_stc_smif_mem_config_t S25FL512S_SlaveSlot_0;
114+
extern const cy_stc_smif_mem_config_t* const smifMemConfigs[CY_SMIF_DEVICE_NUM];
115+
116+
extern const cy_stc_smif_block_config_t smifBlockConfig;
117+
118+
119+
#endif /*CY_SMIF_MEMCONFIG_H*/
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
set SMIF_BANKS {
2+
0 {addr 0x18000000 size 0x10000 psize 0x00000200 esize 0x00040000}
3+
}

0 commit comments

Comments
 (0)