Use DMA for SCSI and SD card transfers for a massive performance boost.
[SCSI2SD-V6.git] / software / SCSI2SD / SCSI2SD.cydsn / Generated_Source / PSoC5 / SDCard.h
1 /*******************************************************************************\r
2 * File Name: SDCard.h\r
3 * Version 2.40\r
4 *\r
5 * Description:\r
6 *  Contains the function prototypes, constants and register definition\r
7 *  of the SPI Master Component.\r
8 *\r
9 * Note:\r
10 *  None\r
11 *\r
12 ********************************************************************************\r
13 * Copyright 2008-2012, Cypress Semiconductor Corporation.  All rights reserved.\r
14 * You may use this file only in accordance with the license, terms, conditions,\r
15 * disclaimers, and limitations in the end user license agreement accompanying\r
16 * the software package with which this file was provided.\r
17 *******************************************************************************/\r
18 \r
19 #if !defined(CY_SPIM_SDCard_H)\r
20 #define CY_SPIM_SDCard_H\r
21 \r
22 #include "cytypes.h"\r
23 #include "cyfitter.h"\r
24 #include "CyLib.h"\r
25 \r
26 /* Check to see if required defines such as CY_PSOC5A are available */\r
27 /* They are defined starting with cy_boot v3.0 */\r
28 #if !defined (CY_PSOC5A)\r
29     #error Component SPI_Master_v2_40 requires cy_boot v3.0 or later\r
30 #endif /* (CY_PSOC5A) */\r
31 \r
32 \r
33 /***************************************\r
34 *   Conditional Compilation Parameters\r
35 ***************************************/\r
36 \r
37 #define SDCard_INTERNAL_CLOCK             (0u)\r
38 \r
39 #if(0u != SDCard_INTERNAL_CLOCK)\r
40     #include "SDCard_IntClock.h"\r
41 #endif /* (0u != SDCard_INTERNAL_CLOCK) */\r
42 \r
43 #define SDCard_MODE                       (1u)\r
44 #define SDCard_DATA_WIDTH                 (8u)\r
45 #define SDCard_MODE_USE_ZERO              (1u)\r
46 #define SDCard_BIDIRECTIONAL_MODE         (0u)\r
47 \r
48 /* Internal interrupt handling */\r
49 #define SDCard_TX_BUFFER_SIZE             (4u)\r
50 #define SDCard_RX_BUFFER_SIZE             (4u)\r
51 #define SDCard_INTERNAL_TX_INT_ENABLED    (0u)\r
52 #define SDCard_INTERNAL_RX_INT_ENABLED    (0u)\r
53 \r
54 #define SDCard_SINGLE_REG_SIZE            (8u)\r
55 #define SDCard_USE_SECOND_DATAPATH        (SDCard_DATA_WIDTH > SDCard_SINGLE_REG_SIZE)\r
56 \r
57 #define SDCard_FIFO_SIZE                  (4u)\r
58 #define SDCard_TX_SOFTWARE_BUF_ENABLED    ((0u != SDCard_INTERNAL_TX_INT_ENABLED) && \\r
59                                                      (SDCard_TX_BUFFER_SIZE > SDCard_FIFO_SIZE))\r
60 \r
61 #define SDCard_RX_SOFTWARE_BUF_ENABLED    ((0u != SDCard_INTERNAL_RX_INT_ENABLED) && \\r
62                                                      (SDCard_RX_BUFFER_SIZE > SDCard_FIFO_SIZE))\r
63 \r
64 \r
65 /***************************************\r
66 *        Data Struct Definition\r
67 ***************************************/\r
68 \r
69 /* Sleep Mode API Support */\r
70 typedef struct\r
71 {\r
72     uint8 enableState;\r
73     uint8 cntrPeriod;\r
74     #if(CY_UDB_V0)\r
75         uint8 saveSrTxIntMask;\r
76         uint8 saveSrRxIntMask;\r
77     #endif /* (CY_UDB_V0) */\r
78 \r
79 } SDCard_BACKUP_STRUCT;\r
80 \r
81 \r
82 /***************************************\r
83 *        Function Prototypes\r
84 ***************************************/\r
85 \r
86 void  SDCard_Init(void)                           ;\r
87 void  SDCard_Enable(void)                         ;\r
88 void  SDCard_Start(void)                          ;\r
89 void  SDCard_Stop(void)                           ;\r
90 \r
91 void  SDCard_EnableTxInt(void)                    ;\r
92 void  SDCard_EnableRxInt(void)                    ;\r
93 void  SDCard_DisableTxInt(void)                   ;\r
94 void  SDCard_DisableRxInt(void)                   ;\r
95 \r
96 void  SDCard_Sleep(void)                          ;\r
97 void  SDCard_Wakeup(void)                         ;\r
98 void  SDCard_SaveConfig(void)                     ;\r
99 void  SDCard_RestoreConfig(void)                  ;\r
100 \r
101 void  SDCard_SetTxInterruptMode(uint8 intSrc)     ;\r
102 void  SDCard_SetRxInterruptMode(uint8 intSrc)     ;\r
103 uint8 SDCard_ReadTxStatus(void)                   ;\r
104 uint8 SDCard_ReadRxStatus(void)                   ;\r
105 void  SDCard_WriteTxData(uint8 txData)  \\r
106                                                             ;\r
107 uint8 SDCard_ReadRxData(void) \\r
108                                                             ;\r
109 uint8 SDCard_GetRxBufferSize(void)                ;\r
110 uint8 SDCard_GetTxBufferSize(void)                ;\r
111 void  SDCard_ClearRxBuffer(void)                  ;\r
112 void  SDCard_ClearTxBuffer(void)                  ;\r
113 void  SDCard_ClearFIFO(void)                              ;\r
114 void  SDCard_PutArray(const uint8 buffer[], uint8 byteCount) \\r
115                                                             ;\r
116 \r
117 #if(0u != SDCard_BIDIRECTIONAL_MODE)\r
118     void  SDCard_TxEnable(void)                   ;\r
119     void  SDCard_TxDisable(void)                  ;\r
120 #endif /* (0u != SDCard_BIDIRECTIONAL_MODE) */\r
121 \r
122 CY_ISR_PROTO(SDCard_TX_ISR);\r
123 CY_ISR_PROTO(SDCard_RX_ISR);\r
124 \r
125 \r
126 /**********************************\r
127 *   Variable with external linkage\r
128 **********************************/\r
129 \r
130 extern uint8 SDCard_initVar;\r
131 \r
132 \r
133 /***************************************\r
134 *           API Constants\r
135 ***************************************/\r
136 \r
137 #define SDCard_TX_ISR_NUMBER     ((uint8) (SDCard_TxInternalInterrupt__INTC_NUMBER))\r
138 #define SDCard_RX_ISR_NUMBER     ((uint8) (SDCard_RxInternalInterrupt__INTC_NUMBER))\r
139 \r
140 #define SDCard_TX_ISR_PRIORITY   ((uint8) (SDCard_TxInternalInterrupt__INTC_PRIOR_NUM))\r
141 #define SDCard_RX_ISR_PRIORITY   ((uint8) (SDCard_RxInternalInterrupt__INTC_PRIOR_NUM))\r
142 \r
143 \r
144 /***************************************\r
145 *    Initial Parameter Constants\r
146 ***************************************/\r
147 \r
148 #define SDCard_INT_ON_SPI_DONE    ((uint8) (0u   << SDCard_STS_SPI_DONE_SHIFT))\r
149 #define SDCard_INT_ON_TX_EMPTY    ((uint8) (0u   << SDCard_STS_TX_FIFO_EMPTY_SHIFT))\r
150 #define SDCard_INT_ON_TX_NOT_FULL ((uint8) (1u << \\r
151                                                                            SDCard_STS_TX_FIFO_NOT_FULL_SHIFT))\r
152 #define SDCard_INT_ON_BYTE_COMP   ((uint8) (0u  << SDCard_STS_BYTE_COMPLETE_SHIFT))\r
153 #define SDCard_INT_ON_SPI_IDLE    ((uint8) (0u   << SDCard_STS_SPI_IDLE_SHIFT))\r
154 \r
155 /* Disable TX_NOT_FULL if software buffer is used */\r
156 #define SDCard_INT_ON_TX_NOT_FULL_DEF ((SDCard_TX_SOFTWARE_BUF_ENABLED) ? \\r
157                                                                         (0u) : (SDCard_INT_ON_TX_NOT_FULL))\r
158 \r
159 /* TX interrupt mask */\r
160 #define SDCard_TX_INIT_INTERRUPTS_MASK    (SDCard_INT_ON_SPI_DONE  | \\r
161                                                      SDCard_INT_ON_TX_EMPTY  | \\r
162                                                      SDCard_INT_ON_TX_NOT_FULL_DEF | \\r
163                                                      SDCard_INT_ON_BYTE_COMP | \\r
164                                                      SDCard_INT_ON_SPI_IDLE)\r
165 \r
166 #define SDCard_INT_ON_RX_FULL         ((uint8) (0u << \\r
167                                                                           SDCard_STS_RX_FIFO_FULL_SHIFT))\r
168 #define SDCard_INT_ON_RX_NOT_EMPTY    ((uint8) (1u << \\r
169                                                                           SDCard_STS_RX_FIFO_NOT_EMPTY_SHIFT))\r
170 #define SDCard_INT_ON_RX_OVER         ((uint8) (0u << \\r
171                                                                           SDCard_STS_RX_FIFO_OVERRUN_SHIFT))\r
172 \r
173 /* RX interrupt mask */\r
174 #define SDCard_RX_INIT_INTERRUPTS_MASK    (SDCard_INT_ON_RX_FULL      | \\r
175                                                      SDCard_INT_ON_RX_NOT_EMPTY | \\r
176                                                      SDCard_INT_ON_RX_OVER)\r
177 /* Nubmer of bits to receive/transmit */\r
178 #define SDCard_BITCTR_INIT            (((uint8) (SDCard_DATA_WIDTH << 1u)) - 1u)\r
179 \r
180 \r
181 /***************************************\r
182 *             Registers\r
183 ***************************************/\r
184 \r
185 #if(CY_PSOC3 || CY_PSOC5)\r
186     #define SDCard_TXDATA_REG (* (reg8 *) \\r
187                                                 SDCard_BSPIM_sR8_Dp_u0__F0_REG)\r
188     #define SDCard_TXDATA_PTR (  (reg8 *) \\r
189                                                 SDCard_BSPIM_sR8_Dp_u0__F0_REG)\r
190     #define SDCard_RXDATA_REG (* (reg8 *) \\r
191                                                 SDCard_BSPIM_sR8_Dp_u0__F1_REG)\r
192     #define SDCard_RXDATA_PTR (  (reg8 *) \\r
193                                                 SDCard_BSPIM_sR8_Dp_u0__F1_REG)\r
194 #else   /* PSOC4 */\r
195     #if(SDCard_USE_SECOND_DATAPATH)\r
196         #define SDCard_TXDATA_REG (* (reg16 *) \\r
197                                           SDCard_BSPIM_sR8_Dp_u0__16BIT_F0_REG)\r
198         #define SDCard_TXDATA_PTR (  (reg16 *) \\r
199                                           SDCard_BSPIM_sR8_Dp_u0__16BIT_F0_REG)\r
200         #define SDCard_RXDATA_REG (* (reg16 *) \\r
201                                           SDCard_BSPIM_sR8_Dp_u0__16BIT_F1_REG)\r
202         #define SDCard_RXDATA_PTR         (  (reg16 *) \\r
203                                           SDCard_BSPIM_sR8_Dp_u0__16BIT_F1_REG)\r
204     #else\r
205         #define SDCard_TXDATA_REG (* (reg8 *) \\r
206                                                 SDCard_BSPIM_sR8_Dp_u0__F0_REG)\r
207         #define SDCard_TXDATA_PTR (  (reg8 *) \\r
208                                                 SDCard_BSPIM_sR8_Dp_u0__F0_REG)\r
209         #define SDCard_RXDATA_REG (* (reg8 *) \\r
210                                                 SDCard_BSPIM_sR8_Dp_u0__F1_REG)\r
211         #define SDCard_RXDATA_PTR (  (reg8 *) \\r
212                                                 SDCard_BSPIM_sR8_Dp_u0__F1_REG)\r
213     #endif /* (SDCard_USE_SECOND_DATAPATH) */\r
214 #endif     /* (CY_PSOC3 || CY_PSOC5) */\r
215 \r
216 #define SDCard_AUX_CONTROL_DP0_REG (* (reg8 *) \\r
217                                         SDCard_BSPIM_sR8_Dp_u0__DP_AUX_CTL_REG)\r
218 #define SDCard_AUX_CONTROL_DP0_PTR (  (reg8 *) \\r
219                                         SDCard_BSPIM_sR8_Dp_u0__DP_AUX_CTL_REG)\r
220 \r
221 #if(SDCard_USE_SECOND_DATAPATH)\r
222     #define SDCard_AUX_CONTROL_DP1_REG  (* (reg8 *) \\r
223                                         SDCard_BSPIM_sR8_Dp_u1__DP_AUX_CTL_REG)\r
224     #define SDCard_AUX_CONTROL_DP1_PTR  (  (reg8 *) \\r
225                                         SDCard_BSPIM_sR8_Dp_u1__DP_AUX_CTL_REG)\r
226 #endif /* (SDCard_USE_SECOND_DATAPATH) */\r
227 \r
228 #define SDCard_COUNTER_PERIOD_REG     (* (reg8 *) SDCard_BSPIM_BitCounter__PERIOD_REG)\r
229 #define SDCard_COUNTER_PERIOD_PTR     (  (reg8 *) SDCard_BSPIM_BitCounter__PERIOD_REG)\r
230 #define SDCard_COUNTER_CONTROL_REG    (* (reg8 *) SDCard_BSPIM_BitCounter__CONTROL_AUX_CTL_REG)\r
231 #define SDCard_COUNTER_CONTROL_PTR    (  (reg8 *) SDCard_BSPIM_BitCounter__CONTROL_AUX_CTL_REG)\r
232 \r
233 #define SDCard_TX_STATUS_REG          (* (reg8 *) SDCard_BSPIM_TxStsReg__STATUS_REG)\r
234 #define SDCard_TX_STATUS_PTR          (  (reg8 *) SDCard_BSPIM_TxStsReg__STATUS_REG)\r
235 #define SDCard_RX_STATUS_REG          (* (reg8 *) SDCard_BSPIM_RxStsReg__STATUS_REG)\r
236 #define SDCard_RX_STATUS_PTR          (  (reg8 *) SDCard_BSPIM_RxStsReg__STATUS_REG)\r
237 \r
238 #define SDCard_CONTROL_REG            (* (reg8 *) \\r
239                                       SDCard_BSPIM_BidirMode_SyncCtl_CtrlReg__CONTROL_REG)\r
240 #define SDCard_CONTROL_PTR            (  (reg8 *) \\r
241                                       SDCard_BSPIM_BidirMode_SyncCtl_CtrlReg__CONTROL_REG)\r
242 \r
243 #define SDCard_TX_STATUS_MASK_REG     (* (reg8 *) SDCard_BSPIM_TxStsReg__MASK_REG)\r
244 #define SDCard_TX_STATUS_MASK_PTR     (  (reg8 *) SDCard_BSPIM_TxStsReg__MASK_REG)\r
245 #define SDCard_RX_STATUS_MASK_REG     (* (reg8 *) SDCard_BSPIM_RxStsReg__MASK_REG)\r
246 #define SDCard_RX_STATUS_MASK_PTR     (  (reg8 *) SDCard_BSPIM_RxStsReg__MASK_REG)\r
247 \r
248 #define SDCard_TX_STATUS_ACTL_REG     (* (reg8 *) SDCard_BSPIM_TxStsReg__STATUS_AUX_CTL_REG)\r
249 #define SDCard_TX_STATUS_ACTL_PTR     (  (reg8 *) SDCard_BSPIM_TxStsReg__STATUS_AUX_CTL_REG)\r
250 #define SDCard_RX_STATUS_ACTL_REG     (* (reg8 *) SDCard_BSPIM_RxStsReg__STATUS_AUX_CTL_REG)\r
251 #define SDCard_RX_STATUS_ACTL_PTR     (  (reg8 *) SDCard_BSPIM_RxStsReg__STATUS_AUX_CTL_REG)\r
252 \r
253 #if(SDCard_USE_SECOND_DATAPATH)\r
254     #define SDCard_AUX_CONTROLDP1     (SDCard_AUX_CONTROL_DP1_REG)\r
255 #endif /* (SDCard_USE_SECOND_DATAPATH) */\r
256 \r
257 \r
258 /***************************************\r
259 *       Register Constants\r
260 ***************************************/\r
261 \r
262 /* Status Register Definitions */\r
263 #define SDCard_STS_SPI_DONE_SHIFT             (0x00u)\r
264 #define SDCard_STS_TX_FIFO_EMPTY_SHIFT        (0x01u)\r
265 #define SDCard_STS_TX_FIFO_NOT_FULL_SHIFT     (0x02u)\r
266 #define SDCard_STS_BYTE_COMPLETE_SHIFT        (0x03u)\r
267 #define SDCard_STS_SPI_IDLE_SHIFT             (0x04u)\r
268 #define SDCard_STS_RX_FIFO_FULL_SHIFT         (0x04u)\r
269 #define SDCard_STS_RX_FIFO_NOT_EMPTY_SHIFT    (0x05u)\r
270 #define SDCard_STS_RX_FIFO_OVERRUN_SHIFT      (0x06u)\r
271 \r
272 #define SDCard_STS_SPI_DONE           ((uint8) (0x01u << SDCard_STS_SPI_DONE_SHIFT))\r
273 #define SDCard_STS_TX_FIFO_EMPTY      ((uint8) (0x01u << SDCard_STS_TX_FIFO_EMPTY_SHIFT))\r
274 #define SDCard_STS_TX_FIFO_NOT_FULL   ((uint8) (0x01u << SDCard_STS_TX_FIFO_NOT_FULL_SHIFT))\r
275 #define SDCard_STS_BYTE_COMPLETE      ((uint8) (0x01u << SDCard_STS_BYTE_COMPLETE_SHIFT))\r
276 #define SDCard_STS_SPI_IDLE           ((uint8) (0x01u << SDCard_STS_SPI_IDLE_SHIFT))\r
277 #define SDCard_STS_RX_FIFO_FULL       ((uint8) (0x01u << SDCard_STS_RX_FIFO_FULL_SHIFT))\r
278 #define SDCard_STS_RX_FIFO_NOT_EMPTY  ((uint8) (0x01u << SDCard_STS_RX_FIFO_NOT_EMPTY_SHIFT))\r
279 #define SDCard_STS_RX_FIFO_OVERRUN    ((uint8) (0x01u << SDCard_STS_RX_FIFO_OVERRUN_SHIFT))\r
280 \r
281 /* TX and RX masks for clear on read bits */\r
282 #define SDCard_TX_STS_CLR_ON_RD_BYTES_MASK    (0x09u)\r
283 #define SDCard_RX_STS_CLR_ON_RD_BYTES_MASK    (0x40u)\r
284 \r
285 /* StatusI Register Interrupt Enable Control Bits */\r
286 /* As defined by the Register map for the AUX Control Register */\r
287 #define SDCard_INT_ENABLE     (0x10u) /* Enable interrupt from statusi */\r
288 #define SDCard_TX_FIFO_CLR    (0x01u) /* F0 - TX FIFO */\r
289 #define SDCard_RX_FIFO_CLR    (0x02u) /* F1 - RX FIFO */\r
290 #define SDCard_FIFO_CLR       (SDCard_TX_FIFO_CLR | SDCard_RX_FIFO_CLR)\r
291 \r
292 /* Bit Counter (7-bit) Control Register Bit Definitions */\r
293 /* As defined by the Register map for the AUX Control Register */\r
294 #define SDCard_CNTR_ENABLE    (0x20u) /* Enable CNT7 */\r
295 \r
296 /* Bi-Directional mode control bit */\r
297 #define SDCard_CTRL_TX_SIGNAL_EN  (0x01u)\r
298 \r
299 /* Datapath Auxillary Control Register definitions */\r
300 #define SDCard_AUX_CTRL_FIFO0_CLR         (0x01u)\r
301 #define SDCard_AUX_CTRL_FIFO1_CLR         (0x02u)\r
302 #define SDCard_AUX_CTRL_FIFO0_LVL         (0x04u)\r
303 #define SDCard_AUX_CTRL_FIFO1_LVL         (0x08u)\r
304 #define SDCard_STATUS_ACTL_INT_EN_MASK    (0x10u)\r
305 \r
306 /* Component disabled */\r
307 #define SDCard_DISABLED   (0u)\r
308 \r
309 \r
310 /***************************************\r
311 *       Macros\r
312 ***************************************/\r
313 \r
314 /* Returns true if componentn enabled */\r
315 #define SDCard_IS_ENABLED (0u != (SDCard_TX_STATUS_ACTL_REG & SDCard_INT_ENABLE))\r
316 \r
317 /* Retuns TX status register */\r
318 #define SDCard_GET_STATUS_TX(swTxSts) ( (uint8)(SDCard_TX_STATUS_REG | \\r
319                                                           ((swTxSts) & SDCard_TX_STS_CLR_ON_RD_BYTES_MASK)) )\r
320 /* Retuns RX status register */\r
321 #define SDCard_GET_STATUS_RX(swRxSts) ( (uint8)(SDCard_RX_STATUS_REG | \\r
322                                                           ((swRxSts) & SDCard_RX_STS_CLR_ON_RD_BYTES_MASK)) )\r
323 \r
324 \r
325 /***************************************\r
326 *       Obsolete definitions\r
327 ***************************************/\r
328 \r
329 /* Following definitions are for version compatibility.\r
330 *  They are obsolete in SPIM v2_30.\r
331 *  Please do not use it in new projects\r
332 */\r
333 \r
334 #define SDCard_WriteByte   SDCard_WriteTxData\r
335 #define SDCard_ReadByte    SDCard_ReadRxData\r
336 void  SDCard_SetInterruptMode(uint8 intSrc)       ;\r
337 uint8 SDCard_ReadStatus(void)                     ;\r
338 void  SDCard_EnableInt(void)                      ;\r
339 void  SDCard_DisableInt(void)                     ;\r
340 \r
341 /* Obsolete register names. Not to be used in new designs */\r
342 #define SDCard_TXDATA                 (SDCard_TXDATA_REG)\r
343 #define SDCard_RXDATA                 (SDCard_RXDATA_REG)\r
344 #define SDCard_AUX_CONTROLDP0         (SDCard_AUX_CONTROL_DP0_REG)\r
345 #define SDCard_TXBUFFERREAD           (SDCard_txBufferRead)\r
346 #define SDCard_TXBUFFERWRITE          (SDCard_txBufferWrite)\r
347 #define SDCard_RXBUFFERREAD           (SDCard_rxBufferRead)\r
348 #define SDCard_RXBUFFERWRITE          (SDCard_rxBufferWrite)\r
349 \r
350 #define SDCard_COUNTER_PERIOD         (SDCard_COUNTER_PERIOD_REG)\r
351 #define SDCard_COUNTER_CONTROL        (SDCard_COUNTER_CONTROL_REG)\r
352 #define SDCard_STATUS                 (SDCard_TX_STATUS_REG)\r
353 #define SDCard_CONTROL                (SDCard_CONTROL_REG)\r
354 #define SDCard_STATUS_MASK            (SDCard_TX_STATUS_MASK_REG)\r
355 #define SDCard_STATUS_ACTL            (SDCard_TX_STATUS_ACTL_REG)\r
356 \r
357 #define SDCard_INIT_INTERRUPTS_MASK  (SDCard_INT_ON_SPI_DONE     | \\r
358                                                 SDCard_INT_ON_TX_EMPTY     | \\r
359                                                 SDCard_INT_ON_TX_NOT_FULL_DEF  | \\r
360                                                 SDCard_INT_ON_RX_FULL      | \\r
361                                                 SDCard_INT_ON_RX_NOT_EMPTY | \\r
362                                                 SDCard_INT_ON_RX_OVER      | \\r
363                                                 SDCard_INT_ON_BYTE_COMP)\r
364                                                 \r
365 /* Following definitions are for version Compatibility.\r
366 *  They are obsolete in SPIM v2_40.\r
367 *  Please do not use it in new projects\r
368 */\r
369 \r
370 #define SDCard_DataWidth                  (SDCard_DATA_WIDTH)\r
371 #define SDCard_InternalClockUsed          (SDCard_INTERNAL_CLOCK)\r
372 #define SDCard_InternalTxInterruptEnabled (SDCard_INTERNAL_TX_INT_ENABLED)\r
373 #define SDCard_InternalRxInterruptEnabled (SDCard_INTERNAL_RX_INT_ENABLED)\r
374 #define SDCard_ModeUseZero                (SDCard_MODE_USE_ZERO)\r
375 #define SDCard_BidirectionalMode          (SDCard_BIDIRECTIONAL_MODE)\r
376 #define SDCard_Mode                       (SDCard_MODE)\r
377 #define SDCard_DATAWIDHT                  (SDCard_DATA_WIDTH)\r
378 #define SDCard_InternalInterruptEnabled   (0u)\r
379 \r
380 #define SDCard_TXBUFFERSIZE   (SDCard_TX_BUFFER_SIZE)\r
381 #define SDCard_RXBUFFERSIZE   (SDCard_RX_BUFFER_SIZE)\r
382 \r
383 #define SDCard_TXBUFFER       SDCard_txBuffer\r
384 #define SDCard_RXBUFFER       SDCard_rxBuffer\r
385 \r
386 #endif /* (CY_SPIM_SDCard_H) */\r
387 \r
388 \r
389 /* [] END OF FILE */\r