STM32F413H-Discovery BSP User Manual
|
stm32f413h_discovery_sd.c
Go to the documentation of this file.
00001 /** 00002 ****************************************************************************** 00003 * @file stm32f413h_discovery_sd.c 00004 * @author MCD Application Team 00005 * @version V1.0.0 00006 * @date 27-January-2017 00007 * @brief This file includes the uSD card driver mounted on STM32F413H-DISCOVERY 00008 * board. 00009 ****************************************************************************** 00010 * @attention 00011 * 00012 * <h2><center>© COPYRIGHT(c) 2017 STMicroelectronics</center></h2> 00013 * 00014 * Redistribution and use in source and binary forms, with or without modification, 00015 * are permitted provided that the following conditions are met: 00016 * 1. Redistributions of source code must retain the above copyright notice, 00017 * this list of conditions and the following disclaimer. 00018 * 2. Redistributions in binary form must reproduce the above copyright notice, 00019 * this list of conditions and the following disclaimer in the documentation 00020 * and/or other materials provided with the distribution. 00021 * 3. Neither the name of STMicroelectronics nor the names of its contributors 00022 * may be used to endorse or promote products derived from this software 00023 * without specific prior written permission. 00024 * 00025 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 00026 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 00027 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 00028 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 00029 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 00030 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 00031 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 00032 * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 00033 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 00034 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 00035 * 00036 ****************************************************************************** 00037 */ 00038 00039 /* File Info : ----------------------------------------------------------------- 00040 User NOTES 00041 1. How To use this driver: 00042 -------------------------- 00043 - This driver is used to drive the micro SD external card mounted on STM32F413H-DISCOVERY 00044 board. 00045 - This driver does not need a specific component driver for the micro SD device 00046 to be included with. 00047 00048 2. Driver description: 00049 --------------------- 00050 + Initialization steps: 00051 o Initialize the micro SD card using the BSP_SD_Init() function. This 00052 function includes the MSP layer hardware resources initialization and the 00053 SDIO interface configuration to interface with the external micro SD. It 00054 also includes the micro SD initialization sequence. 00055 o To check the SD card presence you can use the function BSP_SD_IsDetected() which 00056 returns the detection status 00057 o If SD presence detection interrupt mode is desired, you must configure the 00058 SD detection interrupt mode by calling the function BSP_SD_ITConfig(). The interrupt 00059 is generated as an external interrupt whenever the micro SD card is 00060 plugged/unplugged in/from the board. 00061 o The function BSP_SD_GetCardInfo() is used to get the micro SD card information 00062 which is stored in the structure "HAL_SD_CardInfoTypeDef". 00063 00064 + Micro SD card operations 00065 o The micro SD card can be accessed with read/write block(s) operations once 00066 it is ready for access. The access can be performed whether using the polling 00067 mode by calling the functions BSP_SD_ReadBlocks()/BSP_SD_WriteBlocks(), or by DMA 00068 transfer using the functions BSP_SD_ReadBlocks_DMA()/BSP_SD_WriteBlocks_DMA() 00069 o The DMA transfer complete is used with interrupt mode. Once the SD transfer 00070 is complete, the SD interrupt is handled using the function BSP_SD_IRQHandler(), 00071 the DMA Tx/Rx transfer complete are handled using the functions 00072 BSP_SD_DMA_Tx_IRQHandler()/BSP_SD_DMA_Rx_IRQHandler(). The corresponding user callbacks 00073 are implemented by the user at application level. 00074 o The SD erase block(s) is performed using the function BSP_SD_Erase() with specifying 00075 the number of blocks to erase. 00076 o The SD runtime status is returned when calling the function BSP_SD_GetCardState(). 00077 00078 ------------------------------------------------------------------------------*/ 00079 00080 /* Includes ------------------------------------------------------------------*/ 00081 #include "stm32f413h_discovery_sd.h" 00082 00083 /** @addtogroup BSP 00084 * @{ 00085 */ 00086 00087 /** @addtogroup STM32F413H_DISCOVERY 00088 * @{ 00089 */ 00090 00091 /** @defgroup STM32F413H_DISCOVERY_SD STM32F413H_DISCOVERY SD 00092 * @{ 00093 */ 00094 00095 /** @defgroup STM32F413H_DISCOVERY_SD_Private_Variables STM32F413H DISCOVERY SD Private Variables 00096 * @{ 00097 */ 00098 SD_HandleTypeDef uSdHandle; 00099 00100 /** 00101 * @} 00102 */ 00103 00104 /** @defgroup STM32F413H_DISCOVERY_SD_Private_Functions STM32F413H DISCOVERY SD Private Functions 00105 * @{ 00106 */ 00107 00108 /** 00109 * @brief Initializes the SD card device. 00110 * @retval SD status 00111 */ 00112 uint8_t BSP_SD_Init(void) 00113 { 00114 uint8_t sd_state = MSD_OK; 00115 00116 /* uSD device interface configuration */ 00117 uSdHandle.Instance = SDIO; 00118 00119 uSdHandle.Init.ClockEdge = SDIO_CLOCK_EDGE_RISING; 00120 uSdHandle.Init.ClockBypass = SDIO_CLOCK_BYPASS_DISABLE; 00121 uSdHandle.Init.ClockPowerSave = SDIO_CLOCK_POWER_SAVE_DISABLE; 00122 uSdHandle.Init.BusWide = SDIO_BUS_WIDE_1B; 00123 uSdHandle.Init.HardwareFlowControl = SDIO_HARDWARE_FLOW_CONTROL_ENABLE; 00124 uSdHandle.Init.ClockDiv = SDIO_TRANSFER_CLK_DIV; 00125 00126 /* Msp SD Detect pin initialization */ 00127 BSP_SD_Detect_MspInit(&uSdHandle, NULL); 00128 00129 /* Check if SD card is present */ 00130 if(BSP_SD_IsDetected() != SD_PRESENT) 00131 { 00132 return MSD_ERROR_SD_NOT_PRESENT; 00133 } 00134 00135 /* Msp SD initialization */ 00136 BSP_SD_MspInit(&uSdHandle, NULL); 00137 00138 /* HAL SD initialization */ 00139 if(HAL_SD_Init(&uSdHandle) != HAL_OK) 00140 { 00141 sd_state = MSD_ERROR; 00142 } 00143 00144 /* Configure SD Bus width */ 00145 if(sd_state == MSD_OK) 00146 { 00147 /* Enable wide operation */ 00148 if(HAL_SD_ConfigWideBusOperation(&uSdHandle, SDIO_BUS_WIDE_4B) != HAL_OK) 00149 { 00150 sd_state = MSD_ERROR; 00151 } 00152 else 00153 { 00154 sd_state = MSD_OK; 00155 } 00156 } 00157 00158 return sd_state; 00159 } 00160 00161 /** 00162 * @brief DeInitializes the SD card device. 00163 * @retval SD status 00164 */ 00165 uint8_t BSP_SD_DeInit(void) 00166 { 00167 uint8_t sd_state = MSD_OK; 00168 00169 uSdHandle.Instance = SDIO; 00170 00171 /* HAL SD deinitialization */ 00172 if(HAL_SD_DeInit(&uSdHandle) != HAL_OK) 00173 { 00174 sd_state = MSD_ERROR; 00175 } 00176 00177 /* Msp SD deinitialization */ 00178 uSdHandle.Instance = SDIO; 00179 BSP_SD_MspDeInit(&uSdHandle, NULL); 00180 00181 return sd_state; 00182 } 00183 00184 /** 00185 * @brief Configures Interrupt mode for SD detection pin. 00186 * @retval Returns MSD_OK 00187 */ 00188 uint8_t BSP_SD_ITConfig(void) 00189 { 00190 GPIO_InitTypeDef gpio_init_structure; 00191 00192 /* Configure Interrupt mode for SD detection pin */ 00193 gpio_init_structure.Pin = SD_DETECT_PIN; 00194 gpio_init_structure.Pull = GPIO_PULLUP; 00195 gpio_init_structure.Speed = GPIO_SPEED_FAST; 00196 gpio_init_structure.Mode = GPIO_MODE_IT_RISING_FALLING; 00197 HAL_GPIO_Init(SD_DETECT_GPIO_PORT, &gpio_init_structure); 00198 00199 /* Enable and set SD detect EXTI Interrupt to the lowest priority */ 00200 HAL_NVIC_SetPriority((IRQn_Type)(SD_DETECT_EXTI_IRQn), 0x0F, 0x00); 00201 HAL_NVIC_EnableIRQ((IRQn_Type)(SD_DETECT_EXTI_IRQn)); 00202 00203 return MSD_OK; 00204 } 00205 00206 /** 00207 * @brief Detects if SD card is correctly plugged in the memory slot or not. 00208 * @retval Returns if SD is detected or not 00209 */ 00210 uint8_t BSP_SD_IsDetected(void) 00211 { 00212 __IO uint8_t status = SD_PRESENT; 00213 00214 /* Check SD card detect pin */ 00215 if (HAL_GPIO_ReadPin(SD_DETECT_GPIO_PORT, SD_DETECT_PIN) == GPIO_PIN_SET) 00216 { 00217 status = SD_NOT_PRESENT; 00218 } 00219 00220 return status; 00221 } 00222 00223 /** 00224 * @brief Reads block(s) from a specified address in an SD card, in polling mode. 00225 * @param pData: Pointer to the buffer that will contain the data to transmit 00226 * @param ReadAddr: Address from where data is to be read 00227 * @param NumOfBlocks: Number of SD blocks to read 00228 * @param Timeout: Timeout for read operation 00229 * @retval SD status 00230 */ 00231 uint8_t BSP_SD_ReadBlocks(uint32_t *pData, uint32_t ReadAddr, uint32_t NumOfBlocks, uint32_t Timeout) 00232 { 00233 if(HAL_SD_ReadBlocks(&uSdHandle, (uint8_t *)pData, ReadAddr, NumOfBlocks, Timeout) != HAL_OK) 00234 { 00235 return MSD_ERROR; 00236 } 00237 else 00238 { 00239 return MSD_OK; 00240 } 00241 } 00242 00243 /** 00244 * @brief Writes block(s) to a specified address in an SD card, in polling mode. 00245 * @param pData: Pointer to the buffer that will contain the data to transmit 00246 * @param WriteAddr: Address from where data is to be written 00247 * @param NumOfBlocks: Number of SD blocks to write 00248 * @param Timeout: Timeout for write operation 00249 * @retval SD status 00250 */ 00251 uint8_t BSP_SD_WriteBlocks(uint32_t *pData, uint32_t WriteAddr, uint32_t NumOfBlocks, uint32_t Timeout) 00252 { 00253 if(HAL_SD_WriteBlocks(&uSdHandle, (uint8_t *)pData, WriteAddr, NumOfBlocks, Timeout) != HAL_OK) 00254 { 00255 return MSD_ERROR; 00256 } 00257 else 00258 { 00259 return MSD_OK; 00260 } 00261 } 00262 00263 /** 00264 * @brief Reads block(s) from a specified address in an SD card, in DMA mode. 00265 * @param pData: Pointer to the buffer that will contain the data to transmit 00266 * @param ReadAddr: Address from where data is to be read 00267 * @param NumOfBlocks: Number of SD blocks to read 00268 * @retval SD status 00269 */ 00270 uint8_t BSP_SD_ReadBlocks_DMA(uint32_t *pData, uint32_t ReadAddr, uint32_t NumOfBlocks) 00271 { 00272 /* Read block(s) in DMA transfer mode */ 00273 if(HAL_SD_ReadBlocks_DMA(&uSdHandle, (uint8_t *)pData, ReadAddr, NumOfBlocks) != HAL_OK) 00274 { 00275 return MSD_ERROR; 00276 } 00277 else 00278 { 00279 return MSD_OK; 00280 } 00281 } 00282 00283 /** 00284 * @brief Writes block(s) to a specified address in an SD card, in DMA mode. 00285 * @param pData: Pointer to the buffer that will contain the data to transmit 00286 * @param WriteAddr: Address from where data is to be written 00287 * @param NumOfBlocks: Number of SD blocks to write 00288 * @retval SD status 00289 */ 00290 uint8_t BSP_SD_WriteBlocks_DMA(uint32_t *pData, uint32_t WriteAddr, uint32_t NumOfBlocks) 00291 { 00292 /* Write block(s) in DMA transfer mode */ 00293 if(HAL_SD_WriteBlocks_DMA(&uSdHandle, (uint8_t *)pData, WriteAddr, NumOfBlocks) != HAL_OK) 00294 { 00295 return MSD_ERROR; 00296 } 00297 else 00298 { 00299 return MSD_OK; 00300 } 00301 } 00302 00303 /** 00304 * @brief Erases the specified memory area of the given SD card. 00305 * @param StartAddr: Start byte address 00306 * @param EndAddr: End byte address 00307 * @retval SD status 00308 */ 00309 uint8_t BSP_SD_Erase(uint32_t StartAddr, uint32_t EndAddr) 00310 { 00311 if(HAL_SD_Erase(&uSdHandle, StartAddr, EndAddr) != HAL_OK) 00312 { 00313 return MSD_ERROR; 00314 } 00315 else 00316 { 00317 return MSD_OK; 00318 } 00319 } 00320 00321 /** 00322 * @brief Initializes the SD MSP. 00323 * @param hsd: SD handle 00324 * @param Params : pointer on additional configuration parameters, can be NULL. 00325 */ 00326 __weak void BSP_SD_MspInit(SD_HandleTypeDef *hsd, void *Params) 00327 { 00328 static DMA_HandleTypeDef dma_rx_handle; 00329 static DMA_HandleTypeDef dma_tx_handle; 00330 GPIO_InitTypeDef gpio_init_structure; 00331 00332 /* Prevent unused argument(s) compilation warning */ 00333 UNUSED(Params); 00334 00335 /* Enable SDIO clock */ 00336 __HAL_RCC_SDIO_CLK_ENABLE(); 00337 00338 /* Enable DMA2 clocks */ 00339 __DMAx_TxRx_CLK_ENABLE(); 00340 00341 /* Enable GPIOs clock */ 00342 __HAL_RCC_GPIOC_CLK_ENABLE(); 00343 __HAL_RCC_GPIOA_CLK_ENABLE(); 00344 00345 /* Common GPIO configuration */ 00346 gpio_init_structure.Mode = GPIO_MODE_AF_PP; 00347 gpio_init_structure.Pull = GPIO_PULLUP; 00348 gpio_init_structure.Speed = GPIO_SPEED_HIGH; 00349 gpio_init_structure.Alternate = GPIO_AF12_SDIO; 00350 00351 /* GPIOC configuration: SD_D[0..3] and SD_clk */ 00352 gpio_init_structure.Pin = GPIO_PIN_8 | GPIO_PIN_9 | GPIO_PIN_10 | GPIO_PIN_11 | GPIO_PIN_12; 00353 00354 HAL_GPIO_Init(GPIOC, &gpio_init_structure); 00355 00356 /* GPIOA configuration: SD cmd */ 00357 gpio_init_structure.Pin = GPIO_PIN_6; 00358 HAL_GPIO_Init(GPIOA, &gpio_init_structure); 00359 00360 /* NVIC configuration for SDIO interrupts */ 00361 HAL_NVIC_SetPriority(SDIO_IRQn, 0x0E, 0x00); 00362 HAL_NVIC_EnableIRQ(SDIO_IRQn); 00363 00364 /* Configure DMA Rx parameters */ 00365 dma_rx_handle.Init.Channel = SD_DMAx_Rx_CHANNEL; 00366 dma_rx_handle.Init.Direction = DMA_PERIPH_TO_MEMORY; 00367 dma_rx_handle.Init.PeriphInc = DMA_PINC_DISABLE; 00368 dma_rx_handle.Init.MemInc = DMA_MINC_ENABLE; 00369 dma_rx_handle.Init.PeriphDataAlignment = DMA_PDATAALIGN_WORD; 00370 dma_rx_handle.Init.MemDataAlignment = DMA_MDATAALIGN_WORD; 00371 dma_rx_handle.Init.Mode = DMA_PFCTRL; 00372 dma_rx_handle.Init.Priority = DMA_PRIORITY_VERY_HIGH; 00373 dma_rx_handle.Init.FIFOMode = DMA_FIFOMODE_ENABLE; 00374 dma_rx_handle.Init.FIFOThreshold = DMA_FIFO_THRESHOLD_FULL; 00375 dma_rx_handle.Init.MemBurst = DMA_MBURST_INC4; 00376 dma_rx_handle.Init.PeriphBurst = DMA_PBURST_INC4; 00377 00378 dma_rx_handle.Instance = SD_DMAx_Rx_STREAM; 00379 00380 /* Associate the DMA handle */ 00381 __HAL_LINKDMA(hsd, hdmarx, dma_rx_handle); 00382 00383 /* Deinitialize the stream for new transfer */ 00384 HAL_DMA_DeInit(&dma_rx_handle); 00385 00386 /* Configure the DMA stream */ 00387 HAL_DMA_Init(&dma_rx_handle); 00388 00389 /* Configure DMA Tx parameters */ 00390 dma_tx_handle.Init.Channel = SD_DMAx_Tx_CHANNEL; 00391 dma_tx_handle.Init.Direction = DMA_MEMORY_TO_PERIPH; 00392 dma_tx_handle.Init.PeriphInc = DMA_PINC_DISABLE; 00393 dma_tx_handle.Init.MemInc = DMA_MINC_ENABLE; 00394 dma_tx_handle.Init.PeriphDataAlignment = DMA_PDATAALIGN_WORD; 00395 dma_tx_handle.Init.MemDataAlignment = DMA_MDATAALIGN_WORD; 00396 dma_tx_handle.Init.Mode = DMA_PFCTRL; 00397 dma_tx_handle.Init.Priority = DMA_PRIORITY_VERY_HIGH; 00398 dma_tx_handle.Init.FIFOMode = DMA_FIFOMODE_ENABLE; 00399 dma_tx_handle.Init.FIFOThreshold = DMA_FIFO_THRESHOLD_FULL; 00400 dma_tx_handle.Init.MemBurst = DMA_MBURST_INC4; 00401 dma_tx_handle.Init.PeriphBurst = DMA_PBURST_INC4; 00402 00403 dma_tx_handle.Instance = SD_DMAx_Tx_STREAM; 00404 00405 /* Associate the DMA handle */ 00406 __HAL_LINKDMA(hsd, hdmatx, dma_tx_handle); 00407 00408 /* Deinitialize the stream for new transfer */ 00409 HAL_DMA_DeInit(&dma_tx_handle); 00410 00411 /* Configure the DMA stream */ 00412 HAL_DMA_Init(&dma_tx_handle); 00413 00414 /* NVIC configuration for DMA transfer complete interrupt */ 00415 HAL_NVIC_SetPriority(SD_DMAx_Rx_IRQn, 0x0F, 0x00); 00416 HAL_NVIC_EnableIRQ(SD_DMAx_Rx_IRQn); 00417 00418 /* NVIC configuration for DMA transfer complete interrupt */ 00419 HAL_NVIC_SetPriority(SD_DMAx_Tx_IRQn, 0x0F, 0x00); 00420 HAL_NVIC_EnableIRQ(SD_DMAx_Tx_IRQn); 00421 } 00422 00423 /** 00424 * @brief Initializes the SD Detect pin MSP. 00425 * @param hsd: SD handle 00426 * @param Params : pointer on additional configuration parameters, can be NULL. 00427 */ 00428 __weak void BSP_SD_Detect_MspInit(SD_HandleTypeDef *hsd, void *Params) 00429 { 00430 GPIO_InitTypeDef gpio_init_structure; 00431 00432 /* Prevent unused argument(s) compilation warning */ 00433 UNUSED(Params); 00434 00435 SD_DETECT_GPIO_CLK_ENABLE(); 00436 00437 /* GPIO configuration in input for uSD_Detect signal */ 00438 gpio_init_structure.Pin = SD_DETECT_PIN; 00439 gpio_init_structure.Mode = GPIO_MODE_INPUT; 00440 gpio_init_structure.Pull = GPIO_PULLUP; 00441 gpio_init_structure.Speed = GPIO_SPEED_HIGH; 00442 HAL_GPIO_Init(SD_DETECT_GPIO_PORT, &gpio_init_structure); 00443 } 00444 00445 /** 00446 * @brief DeInitializes the SD MSP. 00447 * @param hsd: SD handle 00448 * @param Params : pointer on additional configuration parameters, can be NULL. 00449 */ 00450 __weak void BSP_SD_MspDeInit(SD_HandleTypeDef *hsd, void *Params) 00451 { 00452 static DMA_HandleTypeDef dma_rx_handle; 00453 static DMA_HandleTypeDef dma_tx_handle; 00454 00455 /* Prevent unused argument(s) compilation warning */ 00456 UNUSED(Params); 00457 00458 /* Disable NVIC for DMA transfer complete interrupts */ 00459 HAL_NVIC_DisableIRQ(SD_DMAx_Rx_IRQn); 00460 HAL_NVIC_DisableIRQ(SD_DMAx_Tx_IRQn); 00461 00462 /* Deinitialize the stream for new transfer */ 00463 dma_rx_handle.Instance = SD_DMAx_Rx_STREAM; 00464 HAL_DMA_DeInit(&dma_rx_handle); 00465 00466 /* Deinitialize the stream for new transfer */ 00467 dma_tx_handle.Instance = SD_DMAx_Tx_STREAM; 00468 HAL_DMA_DeInit(&dma_tx_handle); 00469 00470 /* Disable NVIC for SDIO interrupts */ 00471 HAL_NVIC_DisableIRQ(SDIO_IRQn); 00472 00473 /* DeInit GPIO pins can be done in the application 00474 (by surcharging this __weak function) */ 00475 00476 /* Disable SDIO clock */ 00477 __HAL_RCC_SDIO_CLK_DISABLE(); 00478 00479 /* GPIO pins clock and DMA clocks can be shut down in the application 00480 by surcharging this __weak function */ 00481 } 00482 00483 /** 00484 * @brief Gets the current SD card data status. 00485 * @retval Data transfer state. 00486 * This value can be one of the following values: 00487 * @arg SD_TRANSFER_OK: No data transfer is acting 00488 * @arg SD_TRANSFER_BUSY: Data transfer is acting 00489 */ 00490 uint8_t BSP_SD_GetCardState(void) 00491 { 00492 return((HAL_SD_GetCardState(&uSdHandle) == HAL_SD_CARD_TRANSFER ) ? SD_TRANSFER_OK : SD_TRANSFER_BUSY); 00493 } 00494 00495 00496 /** 00497 * @brief Get SD information about specific SD card. 00498 * @param CardInfo: Pointer to HAL_SD_CardInfoTypedef structure 00499 */ 00500 void BSP_SD_GetCardInfo(HAL_SD_CardInfoTypeDef *CardInfo) 00501 { 00502 /* Get SD card Information */ 00503 HAL_SD_GetCardInfo(&uSdHandle, CardInfo); 00504 } 00505 00506 /** 00507 * @brief SD Abort callbacks 00508 * @param hsd: SD handle 00509 */ 00510 void HAL_SD_AbortCallback(SD_HandleTypeDef *hsd) 00511 { 00512 BSP_SD_AbortCallback(); 00513 } 00514 00515 /** 00516 * @brief Tx Transfer completed callbacks 00517 * @param hsd: SD handle 00518 */ 00519 void HAL_SD_TxCpltCallback(SD_HandleTypeDef *hsd) 00520 { 00521 BSP_SD_WriteCpltCallback(); 00522 } 00523 00524 /** 00525 * @brief Rx Transfer completed callbacks 00526 * @param hsd: SD handle 00527 */ 00528 void HAL_SD_RxCpltCallback(SD_HandleTypeDef *hsd) 00529 { 00530 BSP_SD_ReadCpltCallback(); 00531 } 00532 00533 /** 00534 * @brief BSP SD Abort callbacks 00535 */ 00536 __weak void BSP_SD_AbortCallback(void) 00537 { 00538 00539 } 00540 00541 /** 00542 * @brief BSP Tx Transfer completed callbacks 00543 */ 00544 __weak void BSP_SD_WriteCpltCallback(void) 00545 { 00546 00547 } 00548 00549 /** 00550 * @brief BSP Rx Transfer completed callbacks 00551 */ 00552 __weak void BSP_SD_ReadCpltCallback(void) 00553 { 00554 00555 } 00556 00557 /** 00558 * @} 00559 */ 00560 00561 /** 00562 * @} 00563 */ 00564 00565 /** 00566 * @} 00567 */ 00568 00569 /** 00570 * @} 00571 */ 00572 00573 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
Generated on Thu Jan 26 2017 16:30:37 for STM32F413H-Discovery BSP User Manual by
