Fork of the official mbed C/C SDK provides the software platform and libraries to build your applications for RenBED.

Dependents:   1-RenBuggyTimed RenBED_RGB RenBED_RGB_PWM RenBED_RGB

Fork of mbed by mbed official

Committer:
elijahorr
Date:
Thu Apr 14 07:28:54 2016 +0000
Revision:
121:672067c3ada4
Parent:
112:6f327212ef96
.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
Kojto 112:6f327212ef96 1 /**
Kojto 112:6f327212ef96 2 ******************************************************************************
Kojto 112:6f327212ef96 3 * @file stm32f4xx_hal_sd.h
Kojto 112:6f327212ef96 4 * @author MCD Application Team
Kojto 112:6f327212ef96 5 * @version V1.4.1
Kojto 112:6f327212ef96 6 * @date 09-October-2015
Kojto 112:6f327212ef96 7 * @brief Header file of SD HAL module.
Kojto 112:6f327212ef96 8 ******************************************************************************
Kojto 112:6f327212ef96 9 * @attention
Kojto 112:6f327212ef96 10 *
Kojto 112:6f327212ef96 11 * <h2><center>&copy; COPYRIGHT(c) 2015 STMicroelectronics</center></h2>
Kojto 112:6f327212ef96 12 *
Kojto 112:6f327212ef96 13 * Redistribution and use in source and binary forms, with or without modification,
Kojto 112:6f327212ef96 14 * are permitted provided that the following conditions are met:
Kojto 112:6f327212ef96 15 * 1. Redistributions of source code must retain the above copyright notice,
Kojto 112:6f327212ef96 16 * this list of conditions and the following disclaimer.
Kojto 112:6f327212ef96 17 * 2. Redistributions in binary form must reproduce the above copyright notice,
Kojto 112:6f327212ef96 18 * this list of conditions and the following disclaimer in the documentation
Kojto 112:6f327212ef96 19 * and/or other materials provided with the distribution.
Kojto 112:6f327212ef96 20 * 3. Neither the name of STMicroelectronics nor the names of its contributors
Kojto 112:6f327212ef96 21 * may be used to endorse or promote products derived from this software
Kojto 112:6f327212ef96 22 * without specific prior written permission.
Kojto 112:6f327212ef96 23 *
Kojto 112:6f327212ef96 24 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
Kojto 112:6f327212ef96 25 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
Kojto 112:6f327212ef96 26 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
Kojto 112:6f327212ef96 27 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
Kojto 112:6f327212ef96 28 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
Kojto 112:6f327212ef96 29 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
Kojto 112:6f327212ef96 30 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
Kojto 112:6f327212ef96 31 * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
Kojto 112:6f327212ef96 32 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
Kojto 112:6f327212ef96 33 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Kojto 112:6f327212ef96 34 *
Kojto 112:6f327212ef96 35 ******************************************************************************
Kojto 112:6f327212ef96 36 */
Kojto 112:6f327212ef96 37
Kojto 112:6f327212ef96 38 /* Define to prevent recursive inclusion -------------------------------------*/
Kojto 112:6f327212ef96 39 #ifndef __STM32F4xx_HAL_SD_H
Kojto 112:6f327212ef96 40 #define __STM32F4xx_HAL_SD_H
Kojto 112:6f327212ef96 41
Kojto 112:6f327212ef96 42 #ifdef __cplusplus
Kojto 112:6f327212ef96 43 extern "C" {
Kojto 112:6f327212ef96 44 #endif
Kojto 112:6f327212ef96 45 #if defined(STM32F405xx) || defined(STM32F415xx) || defined(STM32F407xx) || defined(STM32F417xx) || \
Kojto 112:6f327212ef96 46 defined(STM32F427xx) || defined(STM32F437xx) || defined(STM32F429xx) || defined(STM32F439xx) || \
Kojto 112:6f327212ef96 47 defined(STM32F401xC) || defined(STM32F401xE) || defined(STM32F411xE) || defined(STM32F446xx) || \
Kojto 112:6f327212ef96 48 defined(STM32F469xx) || defined(STM32F479xx)
Kojto 112:6f327212ef96 49 /* Includes ------------------------------------------------------------------*/
Kojto 112:6f327212ef96 50 #include "stm32f4xx_ll_sdmmc.h"
Kojto 112:6f327212ef96 51
Kojto 112:6f327212ef96 52 /** @addtogroup STM32F4xx_HAL_Driver
Kojto 112:6f327212ef96 53 * @{
Kojto 112:6f327212ef96 54 */
Kojto 112:6f327212ef96 55
Kojto 112:6f327212ef96 56 /** @defgroup SD SD
Kojto 112:6f327212ef96 57 * @brief SD HAL module driver
Kojto 112:6f327212ef96 58 * @{
Kojto 112:6f327212ef96 59 */
Kojto 112:6f327212ef96 60
Kojto 112:6f327212ef96 61 /* Exported types ------------------------------------------------------------*/
Kojto 112:6f327212ef96 62 /** @defgroup SD_Exported_Types SD Exported Types
Kojto 112:6f327212ef96 63 * @{
Kojto 112:6f327212ef96 64 */
Kojto 112:6f327212ef96 65
Kojto 112:6f327212ef96 66 /** @defgroup SD_Exported_Types_Group1 SD Handle Structure definition
Kojto 112:6f327212ef96 67 * @{
Kojto 112:6f327212ef96 68 */
Kojto 112:6f327212ef96 69 #define SD_InitTypeDef SDIO_InitTypeDef
Kojto 112:6f327212ef96 70 #define SD_TypeDef SDIO_TypeDef
Kojto 112:6f327212ef96 71
Kojto 112:6f327212ef96 72 typedef struct
Kojto 112:6f327212ef96 73 {
Kojto 112:6f327212ef96 74 SD_TypeDef *Instance; /*!< SDIO register base address */
Kojto 112:6f327212ef96 75
Kojto 112:6f327212ef96 76 SD_InitTypeDef Init; /*!< SD required parameters */
Kojto 112:6f327212ef96 77
Kojto 112:6f327212ef96 78 HAL_LockTypeDef Lock; /*!< SD locking object */
Kojto 112:6f327212ef96 79
Kojto 112:6f327212ef96 80 uint32_t CardType; /*!< SD card type */
Kojto 112:6f327212ef96 81
Kojto 112:6f327212ef96 82 uint32_t RCA; /*!< SD relative card address */
Kojto 112:6f327212ef96 83
Kojto 112:6f327212ef96 84 uint32_t CSD[4]; /*!< SD card specific data table */
Kojto 112:6f327212ef96 85
Kojto 112:6f327212ef96 86 uint32_t CID[4]; /*!< SD card identification number table */
Kojto 112:6f327212ef96 87
Kojto 112:6f327212ef96 88 __IO uint32_t SdTransferCplt; /*!< SD transfer complete flag in non blocking mode */
Kojto 112:6f327212ef96 89
Kojto 112:6f327212ef96 90 __IO uint32_t SdTransferErr; /*!< SD transfer error flag in non blocking mode */
Kojto 112:6f327212ef96 91
Kojto 112:6f327212ef96 92 __IO uint32_t DmaTransferCplt; /*!< SD DMA transfer complete flag */
Kojto 112:6f327212ef96 93
Kojto 112:6f327212ef96 94 __IO uint32_t SdOperation; /*!< SD transfer operation (read/write) */
Kojto 112:6f327212ef96 95
Kojto 112:6f327212ef96 96 DMA_HandleTypeDef *hdmarx; /*!< SD Rx DMA handle parameters */
Kojto 112:6f327212ef96 97
Kojto 112:6f327212ef96 98 DMA_HandleTypeDef *hdmatx; /*!< SD Tx DMA handle parameters */
Kojto 112:6f327212ef96 99
Kojto 112:6f327212ef96 100 }SD_HandleTypeDef;
Kojto 112:6f327212ef96 101 /**
Kojto 112:6f327212ef96 102 * @}
Kojto 112:6f327212ef96 103 */
Kojto 112:6f327212ef96 104
Kojto 112:6f327212ef96 105 /** @defgroup SD_Exported_Types_Group2 Card Specific Data: CSD Register
Kojto 112:6f327212ef96 106 * @{
Kojto 112:6f327212ef96 107 */
Kojto 112:6f327212ef96 108 typedef struct
Kojto 112:6f327212ef96 109 {
Kojto 112:6f327212ef96 110 __IO uint8_t CSDStruct; /*!< CSD structure */
Kojto 112:6f327212ef96 111 __IO uint8_t SysSpecVersion; /*!< System specification version */
Kojto 112:6f327212ef96 112 __IO uint8_t Reserved1; /*!< Reserved */
Kojto 112:6f327212ef96 113 __IO uint8_t TAAC; /*!< Data read access time 1 */
Kojto 112:6f327212ef96 114 __IO uint8_t NSAC; /*!< Data read access time 2 in CLK cycles */
Kojto 112:6f327212ef96 115 __IO uint8_t MaxBusClkFrec; /*!< Max. bus clock frequency */
Kojto 112:6f327212ef96 116 __IO uint16_t CardComdClasses; /*!< Card command classes */
Kojto 112:6f327212ef96 117 __IO uint8_t RdBlockLen; /*!< Max. read data block length */
Kojto 112:6f327212ef96 118 __IO uint8_t PartBlockRead; /*!< Partial blocks for read allowed */
Kojto 112:6f327212ef96 119 __IO uint8_t WrBlockMisalign; /*!< Write block misalignment */
Kojto 112:6f327212ef96 120 __IO uint8_t RdBlockMisalign; /*!< Read block misalignment */
Kojto 112:6f327212ef96 121 __IO uint8_t DSRImpl; /*!< DSR implemented */
Kojto 112:6f327212ef96 122 __IO uint8_t Reserved2; /*!< Reserved */
Kojto 112:6f327212ef96 123 __IO uint32_t DeviceSize; /*!< Device Size */
Kojto 112:6f327212ef96 124 __IO uint8_t MaxRdCurrentVDDMin; /*!< Max. read current @ VDD min */
Kojto 112:6f327212ef96 125 __IO uint8_t MaxRdCurrentVDDMax; /*!< Max. read current @ VDD max */
Kojto 112:6f327212ef96 126 __IO uint8_t MaxWrCurrentVDDMin; /*!< Max. write current @ VDD min */
Kojto 112:6f327212ef96 127 __IO uint8_t MaxWrCurrentVDDMax; /*!< Max. write current @ VDD max */
Kojto 112:6f327212ef96 128 __IO uint8_t DeviceSizeMul; /*!< Device size multiplier */
Kojto 112:6f327212ef96 129 __IO uint8_t EraseGrSize; /*!< Erase group size */
Kojto 112:6f327212ef96 130 __IO uint8_t EraseGrMul; /*!< Erase group size multiplier */
Kojto 112:6f327212ef96 131 __IO uint8_t WrProtectGrSize; /*!< Write protect group size */
Kojto 112:6f327212ef96 132 __IO uint8_t WrProtectGrEnable; /*!< Write protect group enable */
Kojto 112:6f327212ef96 133 __IO uint8_t ManDeflECC; /*!< Manufacturer default ECC */
Kojto 112:6f327212ef96 134 __IO uint8_t WrSpeedFact; /*!< Write speed factor */
Kojto 112:6f327212ef96 135 __IO uint8_t MaxWrBlockLen; /*!< Max. write data block length */
Kojto 112:6f327212ef96 136 __IO uint8_t WriteBlockPaPartial; /*!< Partial blocks for write allowed */
Kojto 112:6f327212ef96 137 __IO uint8_t Reserved3; /*!< Reserved */
Kojto 112:6f327212ef96 138 __IO uint8_t ContentProtectAppli; /*!< Content protection application */
Kojto 112:6f327212ef96 139 __IO uint8_t FileFormatGrouop; /*!< File format group */
Kojto 112:6f327212ef96 140 __IO uint8_t CopyFlag; /*!< Copy flag (OTP) */
Kojto 112:6f327212ef96 141 __IO uint8_t PermWrProtect; /*!< Permanent write protection */
Kojto 112:6f327212ef96 142 __IO uint8_t TempWrProtect; /*!< Temporary write protection */
Kojto 112:6f327212ef96 143 __IO uint8_t FileFormat; /*!< File format */
Kojto 112:6f327212ef96 144 __IO uint8_t ECC; /*!< ECC code */
Kojto 112:6f327212ef96 145 __IO uint8_t CSD_CRC; /*!< CSD CRC */
Kojto 112:6f327212ef96 146 __IO uint8_t Reserved4; /*!< Always 1 */
Kojto 112:6f327212ef96 147
Kojto 112:6f327212ef96 148 }HAL_SD_CSDTypedef;
Kojto 112:6f327212ef96 149 /**
Kojto 112:6f327212ef96 150 * @}
Kojto 112:6f327212ef96 151 */
Kojto 112:6f327212ef96 152
Kojto 112:6f327212ef96 153 /** @defgroup SD_Exported_Types_Group3 Card Identification Data: CID Register
Kojto 112:6f327212ef96 154 * @{
Kojto 112:6f327212ef96 155 */
Kojto 112:6f327212ef96 156 typedef struct
Kojto 112:6f327212ef96 157 {
Kojto 112:6f327212ef96 158 __IO uint8_t ManufacturerID; /*!< Manufacturer ID */
Kojto 112:6f327212ef96 159 __IO uint16_t OEM_AppliID; /*!< OEM/Application ID */
Kojto 112:6f327212ef96 160 __IO uint32_t ProdName1; /*!< Product Name part1 */
Kojto 112:6f327212ef96 161 __IO uint8_t ProdName2; /*!< Product Name part2 */
Kojto 112:6f327212ef96 162 __IO uint8_t ProdRev; /*!< Product Revision */
Kojto 112:6f327212ef96 163 __IO uint32_t ProdSN; /*!< Product Serial Number */
Kojto 112:6f327212ef96 164 __IO uint8_t Reserved1; /*!< Reserved1 */
Kojto 112:6f327212ef96 165 __IO uint16_t ManufactDate; /*!< Manufacturing Date */
Kojto 112:6f327212ef96 166 __IO uint8_t CID_CRC; /*!< CID CRC */
Kojto 112:6f327212ef96 167 __IO uint8_t Reserved2; /*!< Always 1 */
Kojto 112:6f327212ef96 168
Kojto 112:6f327212ef96 169 }HAL_SD_CIDTypedef;
Kojto 112:6f327212ef96 170 /**
Kojto 112:6f327212ef96 171 * @}
Kojto 112:6f327212ef96 172 */
Kojto 112:6f327212ef96 173
Kojto 112:6f327212ef96 174 /** @defgroup SD_Exported_Types_Group4 SD Card Status returned by ACMD13
Kojto 112:6f327212ef96 175 * @{
Kojto 112:6f327212ef96 176 */
Kojto 112:6f327212ef96 177 typedef struct
Kojto 112:6f327212ef96 178 {
Kojto 112:6f327212ef96 179 __IO uint8_t DAT_BUS_WIDTH; /*!< Shows the currently defined data bus width */
Kojto 112:6f327212ef96 180 __IO uint8_t SECURED_MODE; /*!< Card is in secured mode of operation */
Kojto 112:6f327212ef96 181 __IO uint16_t SD_CARD_TYPE; /*!< Carries information about card type */
Kojto 112:6f327212ef96 182 __IO uint32_t SIZE_OF_PROTECTED_AREA; /*!< Carries information about the capacity of protected area */
Kojto 112:6f327212ef96 183 __IO uint8_t SPEED_CLASS; /*!< Carries information about the speed class of the card */
Kojto 112:6f327212ef96 184 __IO uint8_t PERFORMANCE_MOVE; /*!< Carries information about the card's performance move */
Kojto 112:6f327212ef96 185 __IO uint8_t AU_SIZE; /*!< Carries information about the card's allocation unit size */
Kojto 112:6f327212ef96 186 __IO uint16_t ERASE_SIZE; /*!< Determines the number of AUs to be erased in one operation */
Kojto 112:6f327212ef96 187 __IO uint8_t ERASE_TIMEOUT; /*!< Determines the timeout for any number of AU erase */
Kojto 112:6f327212ef96 188 __IO uint8_t ERASE_OFFSET; /*!< Carries information about the erase offset */
Kojto 112:6f327212ef96 189
Kojto 112:6f327212ef96 190 }HAL_SD_CardStatusTypedef;
Kojto 112:6f327212ef96 191 /**
Kojto 112:6f327212ef96 192 * @}
Kojto 112:6f327212ef96 193 */
Kojto 112:6f327212ef96 194
Kojto 112:6f327212ef96 195 /** @defgroup SD_Exported_Types_Group5 SD Card information structure
Kojto 112:6f327212ef96 196 * @{
Kojto 112:6f327212ef96 197 */
Kojto 112:6f327212ef96 198 typedef struct
Kojto 112:6f327212ef96 199 {
Kojto 112:6f327212ef96 200 HAL_SD_CSDTypedef SD_csd; /*!< SD card specific data register */
Kojto 112:6f327212ef96 201 HAL_SD_CIDTypedef SD_cid; /*!< SD card identification number register */
Kojto 112:6f327212ef96 202 uint64_t CardCapacity; /*!< Card capacity */
Kojto 112:6f327212ef96 203 uint32_t CardBlockSize; /*!< Card block size */
Kojto 112:6f327212ef96 204 uint16_t RCA; /*!< SD relative card address */
Kojto 112:6f327212ef96 205 uint8_t CardType; /*!< SD card type */
Kojto 112:6f327212ef96 206
Kojto 112:6f327212ef96 207 }HAL_SD_CardInfoTypedef;
Kojto 112:6f327212ef96 208 /**
Kojto 112:6f327212ef96 209 * @}
Kojto 112:6f327212ef96 210 */
Kojto 112:6f327212ef96 211
Kojto 112:6f327212ef96 212 /** @defgroup SD_Exported_Types_Group6 SD Error status enumeration Structure definition
Kojto 112:6f327212ef96 213 * @{
Kojto 112:6f327212ef96 214 */
Kojto 112:6f327212ef96 215 typedef enum
Kojto 112:6f327212ef96 216 {
Kojto 112:6f327212ef96 217 /**
Kojto 112:6f327212ef96 218 * @brief SD specific error defines
Kojto 112:6f327212ef96 219 */
Kojto 112:6f327212ef96 220 SD_CMD_CRC_FAIL = (1), /*!< Command response received (but CRC check failed) */
Kojto 112:6f327212ef96 221 SD_DATA_CRC_FAIL = (2), /*!< Data block sent/received (CRC check failed) */
Kojto 112:6f327212ef96 222 SD_CMD_RSP_TIMEOUT = (3), /*!< Command response timeout */
Kojto 112:6f327212ef96 223 SD_DATA_TIMEOUT = (4), /*!< Data timeout */
Kojto 112:6f327212ef96 224 SD_TX_UNDERRUN = (5), /*!< Transmit FIFO underrun */
Kojto 112:6f327212ef96 225 SD_RX_OVERRUN = (6), /*!< Receive FIFO overrun */
Kojto 112:6f327212ef96 226 SD_START_BIT_ERR = (7), /*!< Start bit not detected on all data signals in wide bus mode */
Kojto 112:6f327212ef96 227 SD_CMD_OUT_OF_RANGE = (8), /*!< Command's argument was out of range. */
Kojto 112:6f327212ef96 228 SD_ADDR_MISALIGNED = (9), /*!< Misaligned address */
Kojto 112:6f327212ef96 229 SD_BLOCK_LEN_ERR = (10), /*!< Transferred block length is not allowed for the card or the number of transferred bytes does not match the block length */
Kojto 112:6f327212ef96 230 SD_ERASE_SEQ_ERR = (11), /*!< An error in the sequence of erase command occurs. */
Kojto 112:6f327212ef96 231 SD_BAD_ERASE_PARAM = (12), /*!< An invalid selection for erase groups */
Kojto 112:6f327212ef96 232 SD_WRITE_PROT_VIOLATION = (13), /*!< Attempt to program a write protect block */
Kojto 112:6f327212ef96 233 SD_LOCK_UNLOCK_FAILED = (14), /*!< Sequence or password error has been detected in unlock command or if there was an attempt to access a locked card */
Kojto 112:6f327212ef96 234 SD_COM_CRC_FAILED = (15), /*!< CRC check of the previous command failed */
Kojto 112:6f327212ef96 235 SD_ILLEGAL_CMD = (16), /*!< Command is not legal for the card state */
Kojto 112:6f327212ef96 236 SD_CARD_ECC_FAILED = (17), /*!< Card internal ECC was applied but failed to correct the data */
Kojto 112:6f327212ef96 237 SD_CC_ERROR = (18), /*!< Internal card controller error */
Kojto 112:6f327212ef96 238 SD_GENERAL_UNKNOWN_ERROR = (19), /*!< General or unknown error */
Kojto 112:6f327212ef96 239 SD_STREAM_READ_UNDERRUN = (20), /*!< The card could not sustain data transfer in stream read operation. */
Kojto 112:6f327212ef96 240 SD_STREAM_WRITE_OVERRUN = (21), /*!< The card could not sustain data programming in stream mode */
Kojto 112:6f327212ef96 241 SD_CID_CSD_OVERWRITE = (22), /*!< CID/CSD overwrite error */
Kojto 112:6f327212ef96 242 SD_WP_ERASE_SKIP = (23), /*!< Only partial address space was erased */
Kojto 112:6f327212ef96 243 SD_CARD_ECC_DISABLED = (24), /*!< Command has been executed without using internal ECC */
Kojto 112:6f327212ef96 244 SD_ERASE_RESET = (25), /*!< Erase sequence was cleared before executing because an out of erase sequence command was received */
Kojto 112:6f327212ef96 245 SD_AKE_SEQ_ERROR = (26), /*!< Error in sequence of authentication. */
Kojto 112:6f327212ef96 246 SD_INVALID_VOLTRANGE = (27),
Kojto 112:6f327212ef96 247 SD_ADDR_OUT_OF_RANGE = (28),
Kojto 112:6f327212ef96 248 SD_SWITCH_ERROR = (29),
Kojto 112:6f327212ef96 249 SD_SDIO_DISABLED = (30),
Kojto 112:6f327212ef96 250 SD_SDIO_FUNCTION_BUSY = (31),
Kojto 112:6f327212ef96 251 SD_SDIO_FUNCTION_FAILED = (32),
Kojto 112:6f327212ef96 252 SD_SDIO_UNKNOWN_FUNCTION = (33),
Kojto 112:6f327212ef96 253
Kojto 112:6f327212ef96 254 /**
Kojto 112:6f327212ef96 255 * @brief Standard error defines
Kojto 112:6f327212ef96 256 */
Kojto 112:6f327212ef96 257 SD_INTERNAL_ERROR = (34),
Kojto 112:6f327212ef96 258 SD_NOT_CONFIGURED = (35),
Kojto 112:6f327212ef96 259 SD_REQUEST_PENDING = (36),
Kojto 112:6f327212ef96 260 SD_REQUEST_NOT_APPLICABLE = (37),
Kojto 112:6f327212ef96 261 SD_INVALID_PARAMETER = (38),
Kojto 112:6f327212ef96 262 SD_UNSUPPORTED_FEATURE = (39),
Kojto 112:6f327212ef96 263 SD_UNSUPPORTED_HW = (40),
Kojto 112:6f327212ef96 264 SD_ERROR = (41),
Kojto 112:6f327212ef96 265 SD_OK = (0)
Kojto 112:6f327212ef96 266
Kojto 112:6f327212ef96 267 }HAL_SD_ErrorTypedef;
Kojto 112:6f327212ef96 268 /**
Kojto 112:6f327212ef96 269 * @}
Kojto 112:6f327212ef96 270 */
Kojto 112:6f327212ef96 271
Kojto 112:6f327212ef96 272 /** @defgroup SD_Exported_Types_Group7 SD Transfer state enumeration structure
Kojto 112:6f327212ef96 273 * @{
Kojto 112:6f327212ef96 274 */
Kojto 112:6f327212ef96 275 typedef enum
Kojto 112:6f327212ef96 276 {
Kojto 112:6f327212ef96 277 SD_TRANSFER_OK = 0, /*!< Transfer success */
Kojto 112:6f327212ef96 278 SD_TRANSFER_BUSY = 1, /*!< Transfer is occurring */
Kojto 112:6f327212ef96 279 SD_TRANSFER_ERROR = 2 /*!< Transfer failed */
Kojto 112:6f327212ef96 280
Kojto 112:6f327212ef96 281 }HAL_SD_TransferStateTypedef;
Kojto 112:6f327212ef96 282 /**
Kojto 112:6f327212ef96 283 * @}
Kojto 112:6f327212ef96 284 */
Kojto 112:6f327212ef96 285
Kojto 112:6f327212ef96 286 /** @defgroup SD_Exported_Types_Group8 SD Card State enumeration structure
Kojto 112:6f327212ef96 287 * @{
Kojto 112:6f327212ef96 288 */
Kojto 112:6f327212ef96 289 typedef enum
Kojto 112:6f327212ef96 290 {
Kojto 112:6f327212ef96 291 SD_CARD_READY = ((uint32_t)0x00000001), /*!< Card state is ready */
Kojto 112:6f327212ef96 292 SD_CARD_IDENTIFICATION = ((uint32_t)0x00000002), /*!< Card is in identification state */
Kojto 112:6f327212ef96 293 SD_CARD_STANDBY = ((uint32_t)0x00000003), /*!< Card is in standby state */
Kojto 112:6f327212ef96 294 SD_CARD_TRANSFER = ((uint32_t)0x00000004), /*!< Card is in transfer state */
Kojto 112:6f327212ef96 295 SD_CARD_SENDING = ((uint32_t)0x00000005), /*!< Card is sending an operation */
Kojto 112:6f327212ef96 296 SD_CARD_RECEIVING = ((uint32_t)0x00000006), /*!< Card is receiving operation information */
Kojto 112:6f327212ef96 297 SD_CARD_PROGRAMMING = ((uint32_t)0x00000007), /*!< Card is in programming state */
Kojto 112:6f327212ef96 298 SD_CARD_DISCONNECTED = ((uint32_t)0x00000008), /*!< Card is disconnected */
Kojto 112:6f327212ef96 299 SD_CARD_ERROR = ((uint32_t)0x000000FF) /*!< Card is in error state */
Kojto 112:6f327212ef96 300
Kojto 112:6f327212ef96 301 }HAL_SD_CardStateTypedef;
Kojto 112:6f327212ef96 302 /**
Kojto 112:6f327212ef96 303 * @}
Kojto 112:6f327212ef96 304 */
Kojto 112:6f327212ef96 305
Kojto 112:6f327212ef96 306 /** @defgroup SD_Exported_Types_Group9 SD Operation enumeration structure
Kojto 112:6f327212ef96 307 * @{
Kojto 112:6f327212ef96 308 */
Kojto 112:6f327212ef96 309 typedef enum
Kojto 112:6f327212ef96 310 {
Kojto 112:6f327212ef96 311 SD_READ_SINGLE_BLOCK = 0, /*!< Read single block operation */
Kojto 112:6f327212ef96 312 SD_READ_MULTIPLE_BLOCK = 1, /*!< Read multiple blocks operation */
Kojto 112:6f327212ef96 313 SD_WRITE_SINGLE_BLOCK = 2, /*!< Write single block operation */
Kojto 112:6f327212ef96 314 SD_WRITE_MULTIPLE_BLOCK = 3 /*!< Write multiple blocks operation */
Kojto 112:6f327212ef96 315
Kojto 112:6f327212ef96 316 }HAL_SD_OperationTypedef;
Kojto 112:6f327212ef96 317 /**
Kojto 112:6f327212ef96 318 * @}
Kojto 112:6f327212ef96 319 */
Kojto 112:6f327212ef96 320
Kojto 112:6f327212ef96 321 /**
Kojto 112:6f327212ef96 322 * @}
Kojto 112:6f327212ef96 323 */
Kojto 112:6f327212ef96 324
Kojto 112:6f327212ef96 325 /* Exported constants --------------------------------------------------------*/
Kojto 112:6f327212ef96 326 /** @defgroup SD_Exported_Constants SD Exported Constants
Kojto 112:6f327212ef96 327 * @{
Kojto 112:6f327212ef96 328 */
Kojto 112:6f327212ef96 329
Kojto 112:6f327212ef96 330 /**
Kojto 112:6f327212ef96 331 * @brief SD Commands Index
Kojto 112:6f327212ef96 332 */
Kojto 112:6f327212ef96 333 #define SD_CMD_GO_IDLE_STATE ((uint8_t)0) /*!< Resets the SD memory card. */
Kojto 112:6f327212ef96 334 #define SD_CMD_SEND_OP_COND ((uint8_t)1) /*!< Sends host capacity support information and activates the card's initialization process. */
Kojto 112:6f327212ef96 335 #define SD_CMD_ALL_SEND_CID ((uint8_t)2) /*!< Asks any card connected to the host to send the CID numbers on the CMD line. */
Kojto 112:6f327212ef96 336 #define SD_CMD_SET_REL_ADDR ((uint8_t)3) /*!< Asks the card to publish a new relative address (RCA). */
Kojto 112:6f327212ef96 337 #define SD_CMD_SET_DSR ((uint8_t)4) /*!< Programs the DSR of all cards. */
Kojto 112:6f327212ef96 338 #define SD_CMD_SDIO_SEN_OP_COND ((uint8_t)5) /*!< Sends host capacity support information (HCS) and asks the accessed card to send its
Kojto 112:6f327212ef96 339 operating condition register (OCR) content in the response on the CMD line. */
Kojto 112:6f327212ef96 340 #define SD_CMD_HS_SWITCH ((uint8_t)6) /*!< Checks switchable function (mode 0) and switch card function (mode 1). */
Kojto 112:6f327212ef96 341 #define SD_CMD_SEL_DESEL_CARD ((uint8_t)7) /*!< Selects the card by its own relative address and gets deselected by any other address */
Kojto 112:6f327212ef96 342 #define SD_CMD_HS_SEND_EXT_CSD ((uint8_t)8) /*!< Sends SD Memory Card interface condition, which includes host supply voltage information
Kojto 112:6f327212ef96 343 and asks the card whether card supports voltage. */
Kojto 112:6f327212ef96 344 #define SD_CMD_SEND_CSD ((uint8_t)9) /*!< Addressed card sends its card specific data (CSD) on the CMD line. */
Kojto 112:6f327212ef96 345 #define SD_CMD_SEND_CID ((uint8_t)10) /*!< Addressed card sends its card identification (CID) on the CMD line. */
Kojto 112:6f327212ef96 346 #define SD_CMD_READ_DAT_UNTIL_STOP ((uint8_t)11) /*!< SD card doesn't support it. */
Kojto 112:6f327212ef96 347 #define SD_CMD_STOP_TRANSMISSION ((uint8_t)12) /*!< Forces the card to stop transmission. */
Kojto 112:6f327212ef96 348 #define SD_CMD_SEND_STATUS ((uint8_t)13) /*!< Addressed card sends its status register. */
Kojto 112:6f327212ef96 349 #define SD_CMD_HS_BUSTEST_READ ((uint8_t)14)
Kojto 112:6f327212ef96 350 #define SD_CMD_GO_INACTIVE_STATE ((uint8_t)15) /*!< Sends an addressed card into the inactive state. */
Kojto 112:6f327212ef96 351 #define SD_CMD_SET_BLOCKLEN ((uint8_t)16) /*!< Sets the block length (in bytes for SDSC) for all following block commands
Kojto 112:6f327212ef96 352 (read, write, lock). Default block length is fixed to 512 Bytes. Not effective
Kojto 112:6f327212ef96 353 for SDHS and SDXC. */
Kojto 112:6f327212ef96 354 #define SD_CMD_READ_SINGLE_BLOCK ((uint8_t)17) /*!< Reads single block of size selected by SET_BLOCKLEN in case of SDSC, and a block of
Kojto 112:6f327212ef96 355 fixed 512 bytes in case of SDHC and SDXC. */
Kojto 112:6f327212ef96 356 #define SD_CMD_READ_MULT_BLOCK ((uint8_t)18) /*!< Continuously transfers data blocks from card to host until interrupted by
Kojto 112:6f327212ef96 357 STOP_TRANSMISSION command. */
Kojto 112:6f327212ef96 358 #define SD_CMD_HS_BUSTEST_WRITE ((uint8_t)19) /*!< 64 bytes tuning pattern is sent for SDR50 and SDR104. */
Kojto 112:6f327212ef96 359 #define SD_CMD_WRITE_DAT_UNTIL_STOP ((uint8_t)20) /*!< Speed class control command. */
Kojto 112:6f327212ef96 360 #define SD_CMD_SET_BLOCK_COUNT ((uint8_t)23) /*!< Specify block count for CMD18 and CMD25. */
Kojto 112:6f327212ef96 361 #define SD_CMD_WRITE_SINGLE_BLOCK ((uint8_t)24) /*!< Writes single block of size selected by SET_BLOCKLEN in case of SDSC, and a block of
Kojto 112:6f327212ef96 362 fixed 512 bytes in case of SDHC and SDXC. */
Kojto 112:6f327212ef96 363 #define SD_CMD_WRITE_MULT_BLOCK ((uint8_t)25) /*!< Continuously writes blocks of data until a STOP_TRANSMISSION follows. */
Kojto 112:6f327212ef96 364 #define SD_CMD_PROG_CID ((uint8_t)26) /*!< Reserved for manufacturers. */
Kojto 112:6f327212ef96 365 #define SD_CMD_PROG_CSD ((uint8_t)27) /*!< Programming of the programmable bits of the CSD. */
Kojto 112:6f327212ef96 366 #define SD_CMD_SET_WRITE_PROT ((uint8_t)28) /*!< Sets the write protection bit of the addressed group. */
Kojto 112:6f327212ef96 367 #define SD_CMD_CLR_WRITE_PROT ((uint8_t)29) /*!< Clears the write protection bit of the addressed group. */
Kojto 112:6f327212ef96 368 #define SD_CMD_SEND_WRITE_PROT ((uint8_t)30) /*!< Asks the card to send the status of the write protection bits. */
Kojto 112:6f327212ef96 369 #define SD_CMD_SD_ERASE_GRP_START ((uint8_t)32) /*!< Sets the address of the first write block to be erased. (For SD card only). */
Kojto 112:6f327212ef96 370 #define SD_CMD_SD_ERASE_GRP_END ((uint8_t)33) /*!< Sets the address of the last write block of the continuous range to be erased. */
Kojto 112:6f327212ef96 371 #define SD_CMD_ERASE_GRP_START ((uint8_t)35) /*!< Sets the address of the first write block to be erased. Reserved for each command
Kojto 112:6f327212ef96 372 system set by switch function command (CMD6). */
Kojto 112:6f327212ef96 373 #define SD_CMD_ERASE_GRP_END ((uint8_t)36) /*!< Sets the address of the last write block of the continuous range to be erased.
Kojto 112:6f327212ef96 374 Reserved for each command system set by switch function command (CMD6). */
Kojto 112:6f327212ef96 375 #define SD_CMD_ERASE ((uint8_t)38) /*!< Reserved for SD security applications. */
Kojto 112:6f327212ef96 376 #define SD_CMD_FAST_IO ((uint8_t)39) /*!< SD card doesn't support it (Reserved). */
Kojto 112:6f327212ef96 377 #define SD_CMD_GO_IRQ_STATE ((uint8_t)40) /*!< SD card doesn't support it (Reserved). */
Kojto 112:6f327212ef96 378 #define SD_CMD_LOCK_UNLOCK ((uint8_t)42) /*!< Sets/resets the password or lock/unlock the card. The size of the data block is set by
Kojto 112:6f327212ef96 379 the SET_BLOCK_LEN command. */
Kojto 112:6f327212ef96 380 #define SD_CMD_APP_CMD ((uint8_t)55) /*!< Indicates to the card that the next command is an application specific command rather
Kojto 112:6f327212ef96 381 than a standard command. */
Kojto 112:6f327212ef96 382 #define SD_CMD_GEN_CMD ((uint8_t)56) /*!< Used either to transfer a data block to the card or to get a data block from the card
Kojto 112:6f327212ef96 383 for general purpose/application specific commands. */
Kojto 112:6f327212ef96 384 #define SD_CMD_NO_CMD ((uint8_t)64)
Kojto 112:6f327212ef96 385
Kojto 112:6f327212ef96 386 /**
Kojto 112:6f327212ef96 387 * @brief Following commands are SD Card Specific commands.
Kojto 112:6f327212ef96 388 * SDIO_APP_CMD should be sent before sending these commands.
Kojto 112:6f327212ef96 389 */
Kojto 112:6f327212ef96 390 #define SD_CMD_APP_SD_SET_BUSWIDTH ((uint8_t)6) /*!< (ACMD6) Defines the data bus width to be used for data transfer. The allowed data bus
Kojto 112:6f327212ef96 391 widths are given in SCR register. */
Kojto 112:6f327212ef96 392 #define SD_CMD_SD_APP_STATUS ((uint8_t)13) /*!< (ACMD13) Sends the SD status. */
Kojto 112:6f327212ef96 393 #define SD_CMD_SD_APP_SEND_NUM_WRITE_BLOCKS ((uint8_t)22) /*!< (ACMD22) Sends the number of the written (without errors) write blocks. Responds with
Kojto 112:6f327212ef96 394 32bit+CRC data block. */
Kojto 112:6f327212ef96 395 #define SD_CMD_SD_APP_OP_COND ((uint8_t)41) /*!< (ACMD41) Sends host capacity support information (HCS) and asks the accessed card to
Kojto 112:6f327212ef96 396 send its operating condition register (OCR) content in the response on the CMD line. */
Kojto 112:6f327212ef96 397 #define SD_CMD_SD_APP_SET_CLR_CARD_DETECT ((uint8_t)42) /*!< (ACMD42) Connects/Disconnects the 50 KOhm pull-up resistor on CD/DAT3 (pin 1) of the card. */
Kojto 112:6f327212ef96 398 #define SD_CMD_SD_APP_SEND_SCR ((uint8_t)51) /*!< Reads the SD Configuration Register (SCR). */
Kojto 112:6f327212ef96 399 #define SD_CMD_SDIO_RW_DIRECT ((uint8_t)52) /*!< For SD I/O card only, reserved for security specification. */
Kojto 112:6f327212ef96 400 #define SD_CMD_SDIO_RW_EXTENDED ((uint8_t)53) /*!< For SD I/O card only, reserved for security specification. */
Kojto 112:6f327212ef96 401
Kojto 112:6f327212ef96 402 /**
Kojto 112:6f327212ef96 403 * @brief Following commands are SD Card Specific security commands.
Kojto 112:6f327212ef96 404 * SD_CMD_APP_CMD should be sent before sending these commands.
Kojto 112:6f327212ef96 405 */
Kojto 112:6f327212ef96 406 #define SD_CMD_SD_APP_GET_MKB ((uint8_t)43) /*!< For SD card only */
Kojto 112:6f327212ef96 407 #define SD_CMD_SD_APP_GET_MID ((uint8_t)44) /*!< For SD card only */
Kojto 112:6f327212ef96 408 #define SD_CMD_SD_APP_SET_CER_RN1 ((uint8_t)45) /*!< For SD card only */
Kojto 112:6f327212ef96 409 #define SD_CMD_SD_APP_GET_CER_RN2 ((uint8_t)46) /*!< For SD card only */
Kojto 112:6f327212ef96 410 #define SD_CMD_SD_APP_SET_CER_RES2 ((uint8_t)47) /*!< For SD card only */
Kojto 112:6f327212ef96 411 #define SD_CMD_SD_APP_GET_CER_RES1 ((uint8_t)48) /*!< For SD card only */
Kojto 112:6f327212ef96 412 #define SD_CMD_SD_APP_SECURE_READ_MULTIPLE_BLOCK ((uint8_t)18) /*!< For SD card only */
Kojto 112:6f327212ef96 413 #define SD_CMD_SD_APP_SECURE_WRITE_MULTIPLE_BLOCK ((uint8_t)25) /*!< For SD card only */
Kojto 112:6f327212ef96 414 #define SD_CMD_SD_APP_SECURE_ERASE ((uint8_t)38) /*!< For SD card only */
Kojto 112:6f327212ef96 415 #define SD_CMD_SD_APP_CHANGE_SECURE_AREA ((uint8_t)49) /*!< For SD card only */
Kojto 112:6f327212ef96 416 #define SD_CMD_SD_APP_SECURE_WRITE_MKB ((uint8_t)48) /*!< For SD card only */
Kojto 112:6f327212ef96 417
Kojto 112:6f327212ef96 418 /**
Kojto 112:6f327212ef96 419 * @brief Supported SD Memory Cards
Kojto 112:6f327212ef96 420 */
Kojto 112:6f327212ef96 421 #define STD_CAPACITY_SD_CARD_V1_1 ((uint32_t)0x00000000)
Kojto 112:6f327212ef96 422 #define STD_CAPACITY_SD_CARD_V2_0 ((uint32_t)0x00000001)
Kojto 112:6f327212ef96 423 #define HIGH_CAPACITY_SD_CARD ((uint32_t)0x00000002)
Kojto 112:6f327212ef96 424 #define MULTIMEDIA_CARD ((uint32_t)0x00000003)
Kojto 112:6f327212ef96 425 #define SECURE_DIGITAL_IO_CARD ((uint32_t)0x00000004)
Kojto 112:6f327212ef96 426 #define HIGH_SPEED_MULTIMEDIA_CARD ((uint32_t)0x00000005)
Kojto 112:6f327212ef96 427 #define SECURE_DIGITAL_IO_COMBO_CARD ((uint32_t)0x00000006)
Kojto 112:6f327212ef96 428 #define HIGH_CAPACITY_MMC_CARD ((uint32_t)0x00000007)
Kojto 112:6f327212ef96 429 /**
Kojto 112:6f327212ef96 430 * @}
Kojto 112:6f327212ef96 431 */
Kojto 112:6f327212ef96 432
Kojto 112:6f327212ef96 433 /* Exported macro ------------------------------------------------------------*/
Kojto 112:6f327212ef96 434 /** @defgroup SD_Exported_macros SD Exported Macros
Kojto 112:6f327212ef96 435 * @brief macros to handle interrupts and specific clock configurations
Kojto 112:6f327212ef96 436 * @{
Kojto 112:6f327212ef96 437 */
Kojto 112:6f327212ef96 438
Kojto 112:6f327212ef96 439 /**
Kojto 112:6f327212ef96 440 * @brief Enable the SD device.
Kojto 112:6f327212ef96 441 * @retval None
Kojto 112:6f327212ef96 442 */
Kojto 112:6f327212ef96 443 #define __HAL_SD_SDIO_ENABLE() __SDIO_ENABLE()
Kojto 112:6f327212ef96 444
Kojto 112:6f327212ef96 445 /**
Kojto 112:6f327212ef96 446 * @brief Disable the SD device.
Kojto 112:6f327212ef96 447 * @retval None
Kojto 112:6f327212ef96 448 */
Kojto 112:6f327212ef96 449 #define __HAL_SD_SDIO_DISABLE() __SDIO_DISABLE()
Kojto 112:6f327212ef96 450
Kojto 112:6f327212ef96 451 /**
Kojto 112:6f327212ef96 452 * @brief Enable the SDIO DMA transfer.
Kojto 112:6f327212ef96 453 * @retval None
Kojto 112:6f327212ef96 454 */
Kojto 112:6f327212ef96 455 #define __HAL_SD_SDIO_DMA_ENABLE() __SDIO_DMA_ENABLE()
Kojto 112:6f327212ef96 456
Kojto 112:6f327212ef96 457 /**
Kojto 112:6f327212ef96 458 * @brief Disable the SDIO DMA transfer.
Kojto 112:6f327212ef96 459 * @retval None
Kojto 112:6f327212ef96 460 */
Kojto 112:6f327212ef96 461 #define __HAL_SD_SDIO_DMA_DISABLE() __SDIO_DMA_DISABLE()
Kojto 112:6f327212ef96 462
Kojto 112:6f327212ef96 463 /**
Kojto 112:6f327212ef96 464 * @brief Enable the SD device interrupt.
Kojto 112:6f327212ef96 465 * @param __HANDLE__: SD Handle
Kojto 112:6f327212ef96 466 * @param __INTERRUPT__: specifies the SDIO interrupt sources to be enabled.
Kojto 112:6f327212ef96 467 * This parameter can be one or a combination of the following values:
Kojto 112:6f327212ef96 468 * @arg SDIO_IT_CCRCFAIL: Command response received (CRC check failed) interrupt
Kojto 112:6f327212ef96 469 * @arg SDIO_IT_DCRCFAIL: Data block sent/received (CRC check failed) interrupt
Kojto 112:6f327212ef96 470 * @arg SDIO_IT_CTIMEOUT: Command response timeout interrupt
Kojto 112:6f327212ef96 471 * @arg SDIO_IT_DTIMEOUT: Data timeout interrupt
Kojto 112:6f327212ef96 472 * @arg SDIO_IT_TXUNDERR: Transmit FIFO underrun error interrupt
Kojto 112:6f327212ef96 473 * @arg SDIO_IT_RXOVERR: Received FIFO overrun error interrupt
Kojto 112:6f327212ef96 474 * @arg SDIO_IT_CMDREND: Command response received (CRC check passed) interrupt
Kojto 112:6f327212ef96 475 * @arg SDIO_IT_CMDSENT: Command sent (no response required) interrupt
Kojto 112:6f327212ef96 476 * @arg SDIO_IT_DATAEND: Data end (data counter, SDIDCOUNT, is zero) interrupt
Kojto 112:6f327212ef96 477 * @arg SDIO_IT_STBITERR: Start bit not detected on all data signals in wide
Kojto 112:6f327212ef96 478 * bus mode interrupt
Kojto 112:6f327212ef96 479 * @arg SDIO_IT_DBCKEND: Data block sent/received (CRC check passed) interrupt
Kojto 112:6f327212ef96 480 * @arg SDIO_IT_CMDACT: Command transfer in progress interrupt
Kojto 112:6f327212ef96 481 * @arg SDIO_IT_TXACT: Data transmit in progress interrupt
Kojto 112:6f327212ef96 482 * @arg SDIO_IT_RXACT: Data receive in progress interrupt
Kojto 112:6f327212ef96 483 * @arg SDIO_IT_TXFIFOHE: Transmit FIFO Half Empty interrupt
Kojto 112:6f327212ef96 484 * @arg SDIO_IT_RXFIFOHF: Receive FIFO Half Full interrupt
Kojto 112:6f327212ef96 485 * @arg SDIO_IT_TXFIFOF: Transmit FIFO full interrupt
Kojto 112:6f327212ef96 486 * @arg SDIO_IT_RXFIFOF: Receive FIFO full interrupt
Kojto 112:6f327212ef96 487 * @arg SDIO_IT_TXFIFOE: Transmit FIFO empty interrupt
Kojto 112:6f327212ef96 488 * @arg SDIO_IT_RXFIFOE: Receive FIFO empty interrupt
Kojto 112:6f327212ef96 489 * @arg SDIO_IT_TXDAVL: Data available in transmit FIFO interrupt
Kojto 112:6f327212ef96 490 * @arg SDIO_IT_RXDAVL: Data available in receive FIFO interrupt
Kojto 112:6f327212ef96 491 * @arg SDIO_IT_SDIOIT: SD I/O interrupt received interrupt
Kojto 112:6f327212ef96 492 * @arg SDIO_IT_CEATAEND: CE-ATA command completion signal received for CMD61 interrupt
Kojto 112:6f327212ef96 493 * @retval None
Kojto 112:6f327212ef96 494 */
Kojto 112:6f327212ef96 495 #define __HAL_SD_SDIO_ENABLE_IT(__HANDLE__, __INTERRUPT__) __SDIO_ENABLE_IT((__HANDLE__)->Instance, (__INTERRUPT__))
Kojto 112:6f327212ef96 496
Kojto 112:6f327212ef96 497 /**
Kojto 112:6f327212ef96 498 * @brief Disable the SD device interrupt.
Kojto 112:6f327212ef96 499 * @param __HANDLE__: SD Handle
Kojto 112:6f327212ef96 500 * @param __INTERRUPT__: specifies the SDIO interrupt sources to be disabled.
Kojto 112:6f327212ef96 501 * This parameter can be one or a combination of the following values:
Kojto 112:6f327212ef96 502 * @arg SDIO_IT_CCRCFAIL: Command response received (CRC check failed) interrupt
Kojto 112:6f327212ef96 503 * @arg SDIO_IT_DCRCFAIL: Data block sent/received (CRC check failed) interrupt
Kojto 112:6f327212ef96 504 * @arg SDIO_IT_CTIMEOUT: Command response timeout interrupt
Kojto 112:6f327212ef96 505 * @arg SDIO_IT_DTIMEOUT: Data timeout interrupt
Kojto 112:6f327212ef96 506 * @arg SDIO_IT_TXUNDERR: Transmit FIFO underrun error interrupt
Kojto 112:6f327212ef96 507 * @arg SDIO_IT_RXOVERR: Received FIFO overrun error interrupt
Kojto 112:6f327212ef96 508 * @arg SDIO_IT_CMDREND: Command response received (CRC check passed) interrupt
Kojto 112:6f327212ef96 509 * @arg SDIO_IT_CMDSENT: Command sent (no response required) interrupt
Kojto 112:6f327212ef96 510 * @arg SDIO_IT_DATAEND: Data end (data counter, SDIDCOUNT, is zero) interrupt
Kojto 112:6f327212ef96 511 * @arg SDIO_IT_STBITERR: Start bit not detected on all data signals in wide
Kojto 112:6f327212ef96 512 * bus mode interrupt
Kojto 112:6f327212ef96 513 * @arg SDIO_IT_DBCKEND: Data block sent/received (CRC check passed) interrupt
Kojto 112:6f327212ef96 514 * @arg SDIO_IT_CMDACT: Command transfer in progress interrupt
Kojto 112:6f327212ef96 515 * @arg SDIO_IT_TXACT: Data transmit in progress interrupt
Kojto 112:6f327212ef96 516 * @arg SDIO_IT_RXACT: Data receive in progress interrupt
Kojto 112:6f327212ef96 517 * @arg SDIO_IT_TXFIFOHE: Transmit FIFO Half Empty interrupt
Kojto 112:6f327212ef96 518 * @arg SDIO_IT_RXFIFOHF: Receive FIFO Half Full interrupt
Kojto 112:6f327212ef96 519 * @arg SDIO_IT_TXFIFOF: Transmit FIFO full interrupt
Kojto 112:6f327212ef96 520 * @arg SDIO_IT_RXFIFOF: Receive FIFO full interrupt
Kojto 112:6f327212ef96 521 * @arg SDIO_IT_TXFIFOE: Transmit FIFO empty interrupt
Kojto 112:6f327212ef96 522 * @arg SDIO_IT_RXFIFOE: Receive FIFO empty interrupt
Kojto 112:6f327212ef96 523 * @arg SDIO_IT_TXDAVL: Data available in transmit FIFO interrupt
Kojto 112:6f327212ef96 524 * @arg SDIO_IT_RXDAVL: Data available in receive FIFO interrupt
Kojto 112:6f327212ef96 525 * @arg SDIO_IT_SDIOIT: SD I/O interrupt received interrupt
Kojto 112:6f327212ef96 526 * @arg SDIO_IT_CEATAEND: CE-ATA command completion signal received for CMD61 interrupt
Kojto 112:6f327212ef96 527 * @retval None
Kojto 112:6f327212ef96 528 */
Kojto 112:6f327212ef96 529 #define __HAL_SD_SDIO_DISABLE_IT(__HANDLE__, __INTERRUPT__) __SDIO_DISABLE_IT((__HANDLE__)->Instance, (__INTERRUPT__))
Kojto 112:6f327212ef96 530
Kojto 112:6f327212ef96 531 /**
Kojto 112:6f327212ef96 532 * @brief Check whether the specified SD flag is set or not.
Kojto 112:6f327212ef96 533 * @param __HANDLE__: SD Handle
Kojto 112:6f327212ef96 534 * @param __FLAG__: specifies the flag to check.
Kojto 112:6f327212ef96 535 * This parameter can be one of the following values:
Kojto 112:6f327212ef96 536 * @arg SDIO_FLAG_CCRCFAIL: Command response received (CRC check failed)
Kojto 112:6f327212ef96 537 * @arg SDIO_FLAG_DCRCFAIL: Data block sent/received (CRC check failed)
Kojto 112:6f327212ef96 538 * @arg SDIO_FLAG_CTIMEOUT: Command response timeout
Kojto 112:6f327212ef96 539 * @arg SDIO_FLAG_DTIMEOUT: Data timeout
Kojto 112:6f327212ef96 540 * @arg SDIO_FLAG_TXUNDERR: Transmit FIFO underrun error
Kojto 112:6f327212ef96 541 * @arg SDIO_FLAG_RXOVERR: Received FIFO overrun error
Kojto 112:6f327212ef96 542 * @arg SDIO_FLAG_CMDREND: Command response received (CRC check passed)
Kojto 112:6f327212ef96 543 * @arg SDIO_FLAG_CMDSENT: Command sent (no response required)
Kojto 112:6f327212ef96 544 * @arg SDIO_FLAG_DATAEND: Data end (data counter, SDIDCOUNT, is zero)
Kojto 112:6f327212ef96 545 * @arg SDIO_FLAG_STBITERR: Start bit not detected on all data signals in wide bus mode.
Kojto 112:6f327212ef96 546 * @arg SDIO_FLAG_DBCKEND: Data block sent/received (CRC check passed)
Kojto 112:6f327212ef96 547 * @arg SDIO_FLAG_CMDACT: Command transfer in progress
Kojto 112:6f327212ef96 548 * @arg SDIO_FLAG_TXACT: Data transmit in progress
Kojto 112:6f327212ef96 549 * @arg SDIO_FLAG_RXACT: Data receive in progress
Kojto 112:6f327212ef96 550 * @arg SDIO_FLAG_TXFIFOHE: Transmit FIFO Half Empty
Kojto 112:6f327212ef96 551 * @arg SDIO_FLAG_RXFIFOHF: Receive FIFO Half Full
Kojto 112:6f327212ef96 552 * @arg SDIO_FLAG_TXFIFOF: Transmit FIFO full
Kojto 112:6f327212ef96 553 * @arg SDIO_FLAG_RXFIFOF: Receive FIFO full
Kojto 112:6f327212ef96 554 * @arg SDIO_FLAG_TXFIFOE: Transmit FIFO empty
Kojto 112:6f327212ef96 555 * @arg SDIO_FLAG_RXFIFOE: Receive FIFO empty
Kojto 112:6f327212ef96 556 * @arg SDIO_FLAG_TXDAVL: Data available in transmit FIFO
Kojto 112:6f327212ef96 557 * @arg SDIO_FLAG_RXDAVL: Data available in receive FIFO
Kojto 112:6f327212ef96 558 * @arg SDIO_FLAG_SDIOIT: SD I/O interrupt received
Kojto 112:6f327212ef96 559 * @arg SDIO_FLAG_CEATAEND: CE-ATA command completion signal received for CMD61
Kojto 112:6f327212ef96 560 * @retval The new state of SD FLAG (SET or RESET).
Kojto 112:6f327212ef96 561 */
Kojto 112:6f327212ef96 562 #define __HAL_SD_SDIO_GET_FLAG(__HANDLE__, __FLAG__) __SDIO_GET_FLAG((__HANDLE__)->Instance, (__FLAG__))
Kojto 112:6f327212ef96 563
Kojto 112:6f327212ef96 564 /**
Kojto 112:6f327212ef96 565 * @brief Clear the SD's pending flags.
Kojto 112:6f327212ef96 566 * @param __HANDLE__: SD Handle
Kojto 112:6f327212ef96 567 * @param __FLAG__: specifies the flag to clear.
Kojto 112:6f327212ef96 568 * This parameter can be one or a combination of the following values:
Kojto 112:6f327212ef96 569 * @arg SDIO_FLAG_CCRCFAIL: Command response received (CRC check failed)
Kojto 112:6f327212ef96 570 * @arg SDIO_FLAG_DCRCFAIL: Data block sent/received (CRC check failed)
Kojto 112:6f327212ef96 571 * @arg SDIO_FLAG_CTIMEOUT: Command response timeout
Kojto 112:6f327212ef96 572 * @arg SDIO_FLAG_DTIMEOUT: Data timeout
Kojto 112:6f327212ef96 573 * @arg SDIO_FLAG_TXUNDERR: Transmit FIFO underrun error
Kojto 112:6f327212ef96 574 * @arg SDIO_FLAG_RXOVERR: Received FIFO overrun error
Kojto 112:6f327212ef96 575 * @arg SDIO_FLAG_CMDREND: Command response received (CRC check passed)
Kojto 112:6f327212ef96 576 * @arg SDIO_FLAG_CMDSENT: Command sent (no response required)
Kojto 112:6f327212ef96 577 * @arg SDIO_FLAG_DATAEND: Data end (data counter, SDIDCOUNT, is zero)
Kojto 112:6f327212ef96 578 * @arg SDIO_FLAG_STBITERR: Start bit not detected on all data signals in wide bus mode
Kojto 112:6f327212ef96 579 * @arg SDIO_FLAG_DBCKEND: Data block sent/received (CRC check passed)
Kojto 112:6f327212ef96 580 * @arg SDIO_FLAG_SDIOIT: SD I/O interrupt received
Kojto 112:6f327212ef96 581 * @arg SDIO_FLAG_CEATAEND: CE-ATA command completion signal received for CMD61
Kojto 112:6f327212ef96 582 * @retval None
Kojto 112:6f327212ef96 583 */
Kojto 112:6f327212ef96 584 #define __HAL_SD_SDIO_CLEAR_FLAG(__HANDLE__, __FLAG__) __SDIO_CLEAR_FLAG((__HANDLE__)->Instance, (__FLAG__))
Kojto 112:6f327212ef96 585
Kojto 112:6f327212ef96 586 /**
Kojto 112:6f327212ef96 587 * @brief Check whether the specified SD interrupt has occurred or not.
Kojto 112:6f327212ef96 588 * @param __HANDLE__: SD Handle
Kojto 112:6f327212ef96 589 * @param __INTERRUPT__: specifies the SDIO interrupt source to check.
Kojto 112:6f327212ef96 590 * This parameter can be one of the following values:
Kojto 112:6f327212ef96 591 * @arg SDIO_IT_CCRCFAIL: Command response received (CRC check failed) interrupt
Kojto 112:6f327212ef96 592 * @arg SDIO_IT_DCRCFAIL: Data block sent/received (CRC check failed) interrupt
Kojto 112:6f327212ef96 593 * @arg SDIO_IT_CTIMEOUT: Command response timeout interrupt
Kojto 112:6f327212ef96 594 * @arg SDIO_IT_DTIMEOUT: Data timeout interrupt
Kojto 112:6f327212ef96 595 * @arg SDIO_IT_TXUNDERR: Transmit FIFO underrun error interrupt
Kojto 112:6f327212ef96 596 * @arg SDIO_IT_RXOVERR: Received FIFO overrun error interrupt
Kojto 112:6f327212ef96 597 * @arg SDIO_IT_CMDREND: Command response received (CRC check passed) interrupt
Kojto 112:6f327212ef96 598 * @arg SDIO_IT_CMDSENT: Command sent (no response required) interrupt
Kojto 112:6f327212ef96 599 * @arg SDIO_IT_DATAEND: Data end (data counter, SDIDCOUNT, is zero) interrupt
Kojto 112:6f327212ef96 600 * @arg SDIO_IT_STBITERR: Start bit not detected on all data signals in wide
Kojto 112:6f327212ef96 601 * bus mode interrupt
Kojto 112:6f327212ef96 602 * @arg SDIO_IT_DBCKEND: Data block sent/received (CRC check passed) interrupt
Kojto 112:6f327212ef96 603 * @arg SDIO_IT_CMDACT: Command transfer in progress interrupt
Kojto 112:6f327212ef96 604 * @arg SDIO_IT_TXACT: Data transmit in progress interrupt
Kojto 112:6f327212ef96 605 * @arg SDIO_IT_RXACT: Data receive in progress interrupt
Kojto 112:6f327212ef96 606 * @arg SDIO_IT_TXFIFOHE: Transmit FIFO Half Empty interrupt
Kojto 112:6f327212ef96 607 * @arg SDIO_IT_RXFIFOHF: Receive FIFO Half Full interrupt
Kojto 112:6f327212ef96 608 * @arg SDIO_IT_TXFIFOF: Transmit FIFO full interrupt
Kojto 112:6f327212ef96 609 * @arg SDIO_IT_RXFIFOF: Receive FIFO full interrupt
Kojto 112:6f327212ef96 610 * @arg SDIO_IT_TXFIFOE: Transmit FIFO empty interrupt
Kojto 112:6f327212ef96 611 * @arg SDIO_IT_RXFIFOE: Receive FIFO empty interrupt
Kojto 112:6f327212ef96 612 * @arg SDIO_IT_TXDAVL: Data available in transmit FIFO interrupt
Kojto 112:6f327212ef96 613 * @arg SDIO_IT_RXDAVL: Data available in receive FIFO interrupt
Kojto 112:6f327212ef96 614 * @arg SDIO_IT_SDIOIT: SD I/O interrupt received interrupt
Kojto 112:6f327212ef96 615 * @arg SDIO_IT_CEATAEND: CE-ATA command completion signal received for CMD61 interrupt
Kojto 112:6f327212ef96 616 * @retval The new state of SD IT (SET or RESET).
Kojto 112:6f327212ef96 617 */
Kojto 112:6f327212ef96 618 #define __HAL_SD_SDIO_GET_IT (__HANDLE__, __INTERRUPT__) __SDIO_GET_IT ((__HANDLE__)->Instance, __INTERRUPT__)
Kojto 112:6f327212ef96 619
Kojto 112:6f327212ef96 620 /**
Kojto 112:6f327212ef96 621 * @brief Clear the SD's interrupt pending bits.
Kojto 112:6f327212ef96 622 * @param __HANDLE__ : SD Handle
Kojto 112:6f327212ef96 623 * @param __INTERRUPT__: specifies the interrupt pending bit to clear.
Kojto 112:6f327212ef96 624 * This parameter can be one or a combination of the following values:
Kojto 112:6f327212ef96 625 * @arg SDIO_IT_CCRCFAIL: Command response received (CRC check failed) interrupt
Kojto 112:6f327212ef96 626 * @arg SDIO_IT_DCRCFAIL: Data block sent/received (CRC check failed) interrupt
Kojto 112:6f327212ef96 627 * @arg SDIO_IT_CTIMEOUT: Command response timeout interrupt
Kojto 112:6f327212ef96 628 * @arg SDIO_IT_DTIMEOUT: Data timeout interrupt
Kojto 112:6f327212ef96 629 * @arg SDIO_IT_TXUNDERR: Transmit FIFO underrun error interrupt
Kojto 112:6f327212ef96 630 * @arg SDIO_IT_RXOVERR: Received FIFO overrun error interrupt
Kojto 112:6f327212ef96 631 * @arg SDIO_IT_CMDREND: Command response received (CRC check passed) interrupt
Kojto 112:6f327212ef96 632 * @arg SDIO_IT_CMDSENT: Command sent (no response required) interrupt
Kojto 112:6f327212ef96 633 * @arg SDIO_IT_DATAEND: Data end (data counter, SDIO_DCOUNT, is zero) interrupt
Kojto 112:6f327212ef96 634 * @arg SDIO_IT_STBITERR: Start bit not detected on all data signals in wide
Kojto 112:6f327212ef96 635 * bus mode interrupt
Kojto 112:6f327212ef96 636 * @arg SDIO_IT_SDIOIT: SD I/O interrupt received interrupt
Kojto 112:6f327212ef96 637 * @arg SDIO_IT_CEATAEND: CE-ATA command completion signal received for CMD61
Kojto 112:6f327212ef96 638 * @retval None
Kojto 112:6f327212ef96 639 */
Kojto 112:6f327212ef96 640 #define __HAL_SD_SDIO_CLEAR_IT(__HANDLE__, __INTERRUPT__) __SDIO_CLEAR_IT((__HANDLE__)->Instance, (__INTERRUPT__))
Kojto 112:6f327212ef96 641 /**
Kojto 112:6f327212ef96 642 * @}
Kojto 112:6f327212ef96 643 */
Kojto 112:6f327212ef96 644
Kojto 112:6f327212ef96 645 /* Exported functions --------------------------------------------------------*/
Kojto 112:6f327212ef96 646 /** @defgroup SD_Exported_Functions SD Exported Functions
Kojto 112:6f327212ef96 647 * @{
Kojto 112:6f327212ef96 648 */
Kojto 112:6f327212ef96 649
Kojto 112:6f327212ef96 650 /** @defgroup SD_Exported_Functions_Group1 Initialization and de-initialization functions
Kojto 112:6f327212ef96 651 * @{
Kojto 112:6f327212ef96 652 */
Kojto 112:6f327212ef96 653 HAL_SD_ErrorTypedef HAL_SD_Init(SD_HandleTypeDef *hsd, HAL_SD_CardInfoTypedef *SDCardInfo);
Kojto 112:6f327212ef96 654 HAL_StatusTypeDef HAL_SD_DeInit (SD_HandleTypeDef *hsd);
Kojto 112:6f327212ef96 655 void HAL_SD_MspInit(SD_HandleTypeDef *hsd);
Kojto 112:6f327212ef96 656 void HAL_SD_MspDeInit(SD_HandleTypeDef *hsd);
Kojto 112:6f327212ef96 657 /**
Kojto 112:6f327212ef96 658 * @}
Kojto 112:6f327212ef96 659 */
Kojto 112:6f327212ef96 660
Kojto 112:6f327212ef96 661 /** @defgroup SD_Exported_Functions_Group2 I/O operation functions
Kojto 112:6f327212ef96 662 * @{
Kojto 112:6f327212ef96 663 */
Kojto 112:6f327212ef96 664 /* Blocking mode: Polling */
Kojto 112:6f327212ef96 665 HAL_SD_ErrorTypedef HAL_SD_ReadBlocks(SD_HandleTypeDef *hsd, uint32_t *pReadBuffer, uint64_t ReadAddr, uint32_t BlockSize, uint32_t NumberOfBlocks);
Kojto 112:6f327212ef96 666 HAL_SD_ErrorTypedef HAL_SD_WriteBlocks(SD_HandleTypeDef *hsd, uint32_t *pWriteBuffer, uint64_t WriteAddr, uint32_t BlockSize, uint32_t NumberOfBlocks);
Kojto 112:6f327212ef96 667 HAL_SD_ErrorTypedef HAL_SD_Erase(SD_HandleTypeDef *hsd, uint64_t startaddr, uint64_t endaddr);
Kojto 112:6f327212ef96 668
Kojto 112:6f327212ef96 669 /* Non-Blocking mode: Interrupt */
Kojto 112:6f327212ef96 670 void HAL_SD_IRQHandler(SD_HandleTypeDef *hsd);
Kojto 112:6f327212ef96 671
Kojto 112:6f327212ef96 672 /* Callback in non blocking modes (DMA) */
Kojto 112:6f327212ef96 673 void HAL_SD_DMA_RxCpltCallback(DMA_HandleTypeDef *hdma);
Kojto 112:6f327212ef96 674 void HAL_SD_DMA_RxErrorCallback(DMA_HandleTypeDef *hdma);
Kojto 112:6f327212ef96 675 void HAL_SD_DMA_TxCpltCallback(DMA_HandleTypeDef *hdma);
Kojto 112:6f327212ef96 676 void HAL_SD_DMA_TxErrorCallback(DMA_HandleTypeDef *hdma);
Kojto 112:6f327212ef96 677 void HAL_SD_XferCpltCallback(SD_HandleTypeDef *hsd);
Kojto 112:6f327212ef96 678 void HAL_SD_XferErrorCallback(SD_HandleTypeDef *hsd);
Kojto 112:6f327212ef96 679
Kojto 112:6f327212ef96 680 /* Non-Blocking mode: DMA */
Kojto 112:6f327212ef96 681 HAL_SD_ErrorTypedef HAL_SD_ReadBlocks_DMA(SD_HandleTypeDef *hsd, uint32_t *pReadBuffer, uint64_t ReadAddr, uint32_t BlockSize, uint32_t NumberOfBlocks);
Kojto 112:6f327212ef96 682 HAL_SD_ErrorTypedef HAL_SD_WriteBlocks_DMA(SD_HandleTypeDef *hsd, uint32_t *pWriteBuffer, uint64_t WriteAddr, uint32_t BlockSize, uint32_t NumberOfBlocks);
Kojto 112:6f327212ef96 683 HAL_SD_ErrorTypedef HAL_SD_CheckWriteOperation(SD_HandleTypeDef *hsd, uint32_t Timeout);
Kojto 112:6f327212ef96 684 HAL_SD_ErrorTypedef HAL_SD_CheckReadOperation(SD_HandleTypeDef *hsd, uint32_t Timeout);
Kojto 112:6f327212ef96 685 /**
Kojto 112:6f327212ef96 686 * @}
Kojto 112:6f327212ef96 687 */
Kojto 112:6f327212ef96 688
Kojto 112:6f327212ef96 689 /** @defgroup SD_Exported_Functions_Group3 Peripheral Control functions
Kojto 112:6f327212ef96 690 * @{
Kojto 112:6f327212ef96 691 */
Kojto 112:6f327212ef96 692 HAL_SD_ErrorTypedef HAL_SD_Get_CardInfo(SD_HandleTypeDef *hsd, HAL_SD_CardInfoTypedef *pCardInfo);
Kojto 112:6f327212ef96 693 HAL_SD_ErrorTypedef HAL_SD_WideBusOperation_Config(SD_HandleTypeDef *hsd, uint32_t WideMode);
Kojto 112:6f327212ef96 694 HAL_SD_ErrorTypedef HAL_SD_StopTransfer(SD_HandleTypeDef *hsd);
Kojto 112:6f327212ef96 695 HAL_SD_ErrorTypedef HAL_SD_HighSpeed (SD_HandleTypeDef *hsd);
Kojto 112:6f327212ef96 696 /**
Kojto 112:6f327212ef96 697 * @}
Kojto 112:6f327212ef96 698 */
Kojto 112:6f327212ef96 699
Kojto 112:6f327212ef96 700 /* Peripheral State functions ************************************************/
Kojto 112:6f327212ef96 701 /** @defgroup SD_Exported_Functions_Group4 Peripheral State functions
Kojto 112:6f327212ef96 702 * @{
Kojto 112:6f327212ef96 703 */
Kojto 112:6f327212ef96 704 HAL_SD_ErrorTypedef HAL_SD_SendSDStatus(SD_HandleTypeDef *hsd, uint32_t *pSDstatus);
Kojto 112:6f327212ef96 705 HAL_SD_ErrorTypedef HAL_SD_GetCardStatus(SD_HandleTypeDef *hsd, HAL_SD_CardStatusTypedef *pCardStatus);
Kojto 112:6f327212ef96 706 HAL_SD_TransferStateTypedef HAL_SD_GetStatus(SD_HandleTypeDef *hsd);
Kojto 112:6f327212ef96 707 /**
Kojto 112:6f327212ef96 708 * @}
Kojto 112:6f327212ef96 709 */
Kojto 112:6f327212ef96 710
Kojto 112:6f327212ef96 711 /**
Kojto 112:6f327212ef96 712 * @}
Kojto 112:6f327212ef96 713 */
Kojto 112:6f327212ef96 714
Kojto 112:6f327212ef96 715 /* Private types -------------------------------------------------------------*/
Kojto 112:6f327212ef96 716 /** @defgroup SD_Private_Types SD Private Types
Kojto 112:6f327212ef96 717 * @{
Kojto 112:6f327212ef96 718 */
Kojto 112:6f327212ef96 719
Kojto 112:6f327212ef96 720 /**
Kojto 112:6f327212ef96 721 * @}
Kojto 112:6f327212ef96 722 */
Kojto 112:6f327212ef96 723
Kojto 112:6f327212ef96 724 /* Private defines -----------------------------------------------------------*/
Kojto 112:6f327212ef96 725 /** @defgroup SD_Private_Defines SD Private Defines
Kojto 112:6f327212ef96 726 * @{
Kojto 112:6f327212ef96 727 */
Kojto 112:6f327212ef96 728
Kojto 112:6f327212ef96 729 /**
Kojto 112:6f327212ef96 730 * @}
Kojto 112:6f327212ef96 731 */
Kojto 112:6f327212ef96 732
Kojto 112:6f327212ef96 733 /* Private variables ---------------------------------------------------------*/
Kojto 112:6f327212ef96 734 /** @defgroup SD_Private_Variables SD Private Variables
Kojto 112:6f327212ef96 735 * @{
Kojto 112:6f327212ef96 736 */
Kojto 112:6f327212ef96 737
Kojto 112:6f327212ef96 738 /**
Kojto 112:6f327212ef96 739 * @}
Kojto 112:6f327212ef96 740 */
Kojto 112:6f327212ef96 741
Kojto 112:6f327212ef96 742 /* Private constants ---------------------------------------------------------*/
Kojto 112:6f327212ef96 743 /** @defgroup SD_Private_Constants SD Private Constants
Kojto 112:6f327212ef96 744 * @{
Kojto 112:6f327212ef96 745 */
Kojto 112:6f327212ef96 746
Kojto 112:6f327212ef96 747 /**
Kojto 112:6f327212ef96 748 * @}
Kojto 112:6f327212ef96 749 */
Kojto 112:6f327212ef96 750
Kojto 112:6f327212ef96 751 /* Private macros ------------------------------------------------------------*/
Kojto 112:6f327212ef96 752 /** @defgroup SD_Private_Macros SD Private Macros
Kojto 112:6f327212ef96 753 * @{
Kojto 112:6f327212ef96 754 */
Kojto 112:6f327212ef96 755
Kojto 112:6f327212ef96 756 /**
Kojto 112:6f327212ef96 757 * @}
Kojto 112:6f327212ef96 758 */
Kojto 112:6f327212ef96 759
Kojto 112:6f327212ef96 760 /* Private functions prototypes ----------------------------------------------*/
Kojto 112:6f327212ef96 761 /** @defgroup SD_Private_Functions_Prototypes SD Private Functions Prototypes
Kojto 112:6f327212ef96 762 * @{
Kojto 112:6f327212ef96 763 */
Kojto 112:6f327212ef96 764
Kojto 112:6f327212ef96 765 /**
Kojto 112:6f327212ef96 766 * @}
Kojto 112:6f327212ef96 767 */
Kojto 112:6f327212ef96 768
Kojto 112:6f327212ef96 769 /* Private functions ---------------------------------------------------------*/
Kojto 112:6f327212ef96 770 /** @defgroup SD_Private_Functions SD Private Functions
Kojto 112:6f327212ef96 771 * @{
Kojto 112:6f327212ef96 772 */
Kojto 112:6f327212ef96 773
Kojto 112:6f327212ef96 774 /**
Kojto 112:6f327212ef96 775 * @}
Kojto 112:6f327212ef96 776 */
Kojto 112:6f327212ef96 777
Kojto 112:6f327212ef96 778 /**
Kojto 112:6f327212ef96 779 * @}
Kojto 112:6f327212ef96 780 */
Kojto 112:6f327212ef96 781
Kojto 112:6f327212ef96 782 /**
Kojto 112:6f327212ef96 783 * @}
Kojto 112:6f327212ef96 784 */
Kojto 112:6f327212ef96 785 #endif /* STM32F405xx || STM32F415xx || STM32F407xx || STM32F417xx || STM32F427xx || STM32F437xx || STM32F429xx || STM32F439xx ||
Kojto 112:6f327212ef96 786 STM32F401xC || STM32F401xE || STM32F411xE || STM32F446xx || STM32F469xx || STM32F479xx */
Kojto 112:6f327212ef96 787 #ifdef __cplusplus
Kojto 112:6f327212ef96 788 }
Kojto 112:6f327212ef96 789 #endif
Kojto 112:6f327212ef96 790
Kojto 112:6f327212ef96 791 #endif /* __STM32F4xx_HAL_SD_H */
Kojto 112:6f327212ef96 792
Kojto 112:6f327212ef96 793 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/