SDFileSystem for STM32F746NG DISCOVERY with 4bit SDMMC interface on fixed pins

Dependencies:   FATFileSystem

Dependents:   DISCO-F746NG_SDFileSystem uzairkhan DISCO-F746NG_Scope_copy

Fork of SDFileSystem by Neil Thiessen

Committer:
DieterGraef
Date:
Tue Apr 12 18:16:24 2016 +0000
Revision:
25:391eade4ef85
Parent:
24:698affe9560c
Child:
26:8f15aa3b052b
Solving cache issues.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
neilt6 0:2a6d8a096edc 1 /* SD/MMC File System Library
neilt6 22:3fa5eaf48e81 2 * Copyright (c) 2016 Neil Thiessen
DieterGraef 23:c03ef1abef0e 3 * Modified for the use with STM32F746 Discovery (C) 2016 Dieter Greaf
neilt6 0:2a6d8a096edc 4 * Licensed under the Apache License, Version 2.0 (the "License");
neilt6 0:2a6d8a096edc 5 * you may not use this file except in compliance with the License.
neilt6 0:2a6d8a096edc 6 * You may obtain a copy of the License at
neilt6 0:2a6d8a096edc 7 *
neilt6 0:2a6d8a096edc 8 * http://www.apache.org/licenses/LICENSE-2.0
neilt6 0:2a6d8a096edc 9 *
neilt6 0:2a6d8a096edc 10 * Unless required by applicable law or agreed to in writing, software
neilt6 0:2a6d8a096edc 11 * distributed under the License is distributed on an "AS IS" BASIS,
neilt6 0:2a6d8a096edc 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
neilt6 0:2a6d8a096edc 13 * See the License for the specific language governing permissions and
neilt6 0:2a6d8a096edc 14 * limitations under the License.
neilt6 0:2a6d8a096edc 15 */
neilt6 0:2a6d8a096edc 16
neilt6 0:2a6d8a096edc 17 #include "SDFileSystem.h"
neilt6 18:2286a4e7fa31 18 #include "diskio.h"
neilt6 18:2286a4e7fa31 19 #include "SDCRC.h"
DieterGraef 23:c03ef1abef0e 20 //for cache flush function
DieterGraef 23:c03ef1abef0e 21 #include "SD_Helper.h"
neilt6 0:2a6d8a096edc 22
DieterGraef 23:c03ef1abef0e 23 SDFileSystem::SDFileSystem( const char* name)
DieterGraef 23:c03ef1abef0e 24 : FATFileSystem(name), m_Cd(PC_13)
neilt6 0:2a6d8a096edc 25 {
neilt6 0:2a6d8a096edc 26 //Initialize the member variables
DieterGraef 23:c03ef1abef0e 27 uint8_t initstat;
DieterGraef 23:c03ef1abef0e 28 void* h;
neilt6 6:55a26a56046a 29 m_CardType = CARD_NONE;
neilt6 7:61db99e52c0d 30 m_Crc = true;
neilt6 6:55a26a56046a 31 m_LargeFrames = false;
neilt6 13:635147efa748 32 m_WriteValidation = true;
neilt6 0:2a6d8a096edc 33 m_Status = STA_NOINIT;
DieterGraef 23:c03ef1abef0e 34 m_Cd.mode(PullUp);
DieterGraef 23:c03ef1abef0e 35 m_CdAssert = 0;
DieterGraef 23:c03ef1abef0e 36 m_Cd.rise(this, &SDFileSystem::onCardRemoval);
DieterGraef 23:c03ef1abef0e 37 h=(void*)&SDFileSystem::DMA2_Stream3_IRQHandler;
DieterGraef 23:c03ef1abef0e 38 NVIC_SetVector(DMA2_Stream3_IRQn,(uint32_t)h);
DieterGraef 23:c03ef1abef0e 39 h=(void*)&SDFileSystem::DMA2_Stream6_IRQHandler;
DieterGraef 23:c03ef1abef0e 40 NVIC_SetVector(DMA2_Stream6_IRQn,(uint32_t)h);
DieterGraef 23:c03ef1abef0e 41 h=(void*)&SDFileSystem::SDMMC1_IRQHandler;
DieterGraef 23:c03ef1abef0e 42 NVIC_SetVector(SDMMC1_IRQn,(uint32_t)h);
DieterGraef 24:698affe9560c 43 BSP_SD_Clear_Busy();
DieterGraef 23:c03ef1abef0e 44 initstat=BSP_SD_Init();
DieterGraef 23:c03ef1abef0e 45 if (initstat!=MSD_OK)
DieterGraef 23:c03ef1abef0e 46 {
DieterGraef 23:c03ef1abef0e 47 m_Status |= STA_NOINIT;
DieterGraef 23:c03ef1abef0e 48 }
DieterGraef 23:c03ef1abef0e 49 else
DieterGraef 23:c03ef1abef0e 50 {
DieterGraef 23:c03ef1abef0e 51 m_Status &= ~STA_NOINIT;
DieterGraef 23:c03ef1abef0e 52 }
neilt6 0:2a6d8a096edc 53 }
neilt6 0:2a6d8a096edc 54
neilt6 20:2c1e8d442f68 55 bool SDFileSystem::card_present()
neilt6 0:2a6d8a096edc 56 {
neilt6 20:2c1e8d442f68 57 //Check the card socket
neilt6 0:2a6d8a096edc 58 checkSocket();
neilt6 0:2a6d8a096edc 59
neilt6 20:2c1e8d442f68 60 //Return whether or not a card is present
neilt6 20:2c1e8d442f68 61 return !(m_Status & STA_NODISK);
neilt6 20:2c1e8d442f68 62 }
neilt6 0:2a6d8a096edc 63
neilt6 20:2c1e8d442f68 64 SDFileSystem::CardType SDFileSystem::card_type()
neilt6 20:2c1e8d442f68 65 {
neilt6 20:2c1e8d442f68 66 //Check the card socket
neilt6 20:2c1e8d442f68 67 checkSocket();
neilt6 18:2286a4e7fa31 68
neilt6 0:2a6d8a096edc 69 //Return the card type
neilt6 0:2a6d8a096edc 70 return m_CardType;
neilt6 0:2a6d8a096edc 71 }
neilt6 0:2a6d8a096edc 72
neilt6 7:61db99e52c0d 73 bool SDFileSystem::crc()
neilt6 6:55a26a56046a 74 {
neilt6 6:55a26a56046a 75 //Return whether or not CRC is enabled
neilt6 7:61db99e52c0d 76 return m_Crc;
neilt6 6:55a26a56046a 77 }
neilt6 6:55a26a56046a 78
neilt6 7:61db99e52c0d 79 void SDFileSystem::crc(bool enabled)
neilt6 6:55a26a56046a 80 {
neilt6 20:2c1e8d442f68 81 //Check the card socket
neilt6 6:55a26a56046a 82 checkSocket();
neilt6 6:55a26a56046a 83
neilt6 6:55a26a56046a 84 //Just update the member variable if the card isn't initialized
neilt6 6:55a26a56046a 85 if (m_Status & STA_NOINIT) {
neilt6 7:61db99e52c0d 86 m_Crc = enabled;
neilt6 6:55a26a56046a 87 return;
neilt6 6:55a26a56046a 88 }
neilt6 6:55a26a56046a 89
neilt6 6:55a26a56046a 90 //Enable or disable CRC
neilt6 7:61db99e52c0d 91 if (enabled && !m_Crc) {
neilt6 6:55a26a56046a 92 //Send CMD59(0x00000001) to enable CRC
neilt6 7:61db99e52c0d 93 m_Crc = true;
DieterGraef 23:c03ef1abef0e 94 BSP_SD_CommandTransaction(CMD59, 0x00000001);
neilt6 7:61db99e52c0d 95 } else if (!enabled && m_Crc) {
DieterGraef 23:c03ef1abef0e 96 //Send CMD59(0x00000000) to disableAPP/MBED/targets/hal/TARGET_STM/TARGET_STM32F7/TARGET_DISCO_F746NG CRC
DieterGraef 23:c03ef1abef0e 97 BSP_SD_CommandTransaction(CMD59, 0x00000000);
neilt6 7:61db99e52c0d 98 m_Crc = false;
neilt6 6:55a26a56046a 99 }
neilt6 6:55a26a56046a 100 }
neilt6 6:55a26a56046a 101
neilt6 6:55a26a56046a 102 bool SDFileSystem::large_frames()
neilt6 6:55a26a56046a 103 {
neilt6 6:55a26a56046a 104 //Return whether or not 16-bit frames are enabled
neilt6 6:55a26a56046a 105 return m_LargeFrames;
neilt6 6:55a26a56046a 106 }
neilt6 6:55a26a56046a 107
neilt6 6:55a26a56046a 108 void SDFileSystem::large_frames(bool enabled)
neilt6 6:55a26a56046a 109 {
neilt6 6:55a26a56046a 110 //Set whether or not 16-bit frames are enabled
neilt6 6:55a26a56046a 111 m_LargeFrames = enabled;
neilt6 6:55a26a56046a 112 }
neilt6 6:55a26a56046a 113
neilt6 13:635147efa748 114 bool SDFileSystem::write_validation()
neilt6 13:635147efa748 115 {
neilt6 13:635147efa748 116 //Return whether or not write validation is enabled
neilt6 13:635147efa748 117 return m_WriteValidation;
neilt6 13:635147efa748 118 }
neilt6 13:635147efa748 119
neilt6 13:635147efa748 120 void SDFileSystem::write_validation(bool enabled)
neilt6 13:635147efa748 121 {
neilt6 13:635147efa748 122 //Set whether or not write validation is enabled
neilt6 13:635147efa748 123 m_WriteValidation = enabled;
neilt6 13:635147efa748 124 }
neilt6 13:635147efa748 125
neilt6 11:67ddc53e3983 126 int SDFileSystem::unmount()
neilt6 11:67ddc53e3983 127 {
neilt6 11:67ddc53e3983 128 //Unmount the filesystem
neilt6 11:67ddc53e3983 129 FATFileSystem::unmount();
neilt6 11:67ddc53e3983 130
neilt6 20:2c1e8d442f68 131 //Change the status to not initialized, and the card type to unknown
neilt6 11:67ddc53e3983 132 m_Status |= STA_NOINIT;
neilt6 20:2c1e8d442f68 133 m_CardType = CARD_UNKNOWN;
neilt6 11:67ddc53e3983 134
neilt6 11:67ddc53e3983 135 //Always succeeds
neilt6 11:67ddc53e3983 136 return 0;
neilt6 11:67ddc53e3983 137 }
neilt6 11:67ddc53e3983 138
neilt6 0:2a6d8a096edc 139 int SDFileSystem::disk_initialize()
neilt6 0:2a6d8a096edc 140 {
neilt6 0:2a6d8a096edc 141
neilt6 0:2a6d8a096edc 142 //Make sure there's a card in the socket before proceeding
neilt6 0:2a6d8a096edc 143 checkSocket();
neilt6 0:2a6d8a096edc 144 if (m_Status & STA_NODISK)
neilt6 0:2a6d8a096edc 145 return m_Status;
DieterGraef 23:c03ef1abef0e 146 BSP_SD_GetCardInfo(&m_CardInfo);
neilt6 12:eebddab6eff2 147
DieterGraef 23:c03ef1abef0e 148 switch(m_CardInfo.CardType)
DieterGraef 23:c03ef1abef0e 149 {
DieterGraef 23:c03ef1abef0e 150 case STD_CAPACITY_SD_CARD_V1_1:
DieterGraef 23:c03ef1abef0e 151 { m_CardType = CARD_SD;
DieterGraef 23:c03ef1abef0e 152 break; }
DieterGraef 23:c03ef1abef0e 153 case STD_CAPACITY_SD_CARD_V2_0:
DieterGraef 23:c03ef1abef0e 154 { m_CardType = CARD_SD;
DieterGraef 23:c03ef1abef0e 155 break; }
DieterGraef 23:c03ef1abef0e 156 case HIGH_CAPACITY_SD_CARD:
DieterGraef 23:c03ef1abef0e 157 { m_CardType = CARD_SDHC;
DieterGraef 23:c03ef1abef0e 158 break; }
DieterGraef 23:c03ef1abef0e 159 case MULTIMEDIA_CARD:
DieterGraef 23:c03ef1abef0e 160 { m_CardType = CARD_MMC;
DieterGraef 23:c03ef1abef0e 161 break; }
DieterGraef 23:c03ef1abef0e 162 case SECURE_DIGITAL_IO_CARD:
DieterGraef 23:c03ef1abef0e 163 { m_CardType = CARD_SD;
DieterGraef 23:c03ef1abef0e 164 break; }
DieterGraef 23:c03ef1abef0e 165 case HIGH_SPEED_MULTIMEDIA_CARD:
DieterGraef 23:c03ef1abef0e 166 { m_CardType = CARD_MMC;
DieterGraef 23:c03ef1abef0e 167 break; }
DieterGraef 23:c03ef1abef0e 168 case SECURE_DIGITAL_IO_COMBO_CARD:
DieterGraef 23:c03ef1abef0e 169 { m_CardType = CARD_SD;
DieterGraef 23:c03ef1abef0e 170 break; }
DieterGraef 23:c03ef1abef0e 171 case HIGH_CAPACITY_MMC_CARD:
DieterGraef 23:c03ef1abef0e 172 { m_CardType = CARD_MMC;
DieterGraef 23:c03ef1abef0e 173 break; }
DieterGraef 23:c03ef1abef0e 174 default:
DieterGraef 23:c03ef1abef0e 175 {m_CardType = CARD_UNKNOWN;
DieterGraef 23:c03ef1abef0e 176 return m_Status;}
DieterGraef 23:c03ef1abef0e 177 }
neilt6 0:2a6d8a096edc 178 //The card is now initialized
neilt6 0:2a6d8a096edc 179 m_Status &= ~STA_NOINIT;
neilt6 0:2a6d8a096edc 180
neilt6 9:1906befe7f30 181 //Return the disk status
neilt6 0:2a6d8a096edc 182 return m_Status;
neilt6 0:2a6d8a096edc 183 }
neilt6 0:2a6d8a096edc 184
neilt6 0:2a6d8a096edc 185 int SDFileSystem::disk_status()
neilt6 0:2a6d8a096edc 186 {
neilt6 20:2c1e8d442f68 187 //Check the card socket
neilt6 0:2a6d8a096edc 188 checkSocket();
neilt6 0:2a6d8a096edc 189
neilt6 9:1906befe7f30 190 //Return the disk status
neilt6 0:2a6d8a096edc 191 return m_Status;
neilt6 0:2a6d8a096edc 192 }
neilt6 0:2a6d8a096edc 193
neilt6 21:d10a519c0910 194 int SDFileSystem::disk_read(uint8_t* buffer, uint32_t sector, uint32_t count)
neilt6 0:2a6d8a096edc 195 {
DieterGraef 23:c03ef1abef0e 196 int retval;
neilt6 9:1906befe7f30 197 //Make sure the card is initialized before proceeding
neilt6 0:2a6d8a096edc 198 if (m_Status & STA_NOINIT)
neilt6 0:2a6d8a096edc 199 return RES_NOTRDY;
DieterGraef 25:391eade4ef85 200 __DSB();
DieterGraef 25:391eade4ef85 201 __ISB();
DieterGraef 24:698affe9560c 202 while(BSP_SD_Get_Busy()==1){;}
DieterGraef 24:698affe9560c 203 BSP_SD_Set_Busy();
neilt6 11:67ddc53e3983 204 //Read a single block, or multiple blocks
neilt6 11:67ddc53e3983 205 if (count > 1) {
DieterGraef 23:c03ef1abef0e 206 BSP_SD_Set_RX_Busy();
DieterGraef 23:c03ef1abef0e 207 retval=BSP_SD_ReadBlocks_DMA((uint32_t *)buffer, (uint64_t) (sector * 512),512, count);
DieterGraef 24:698affe9560c 208 while((BSP_SD_Get_RX_Busy()==1)&&(retval==MSD_OK)){;}
DieterGraef 23:c03ef1abef0e 209 CPU_CACHE_Flush((uint32_t *)buffer,(512*count));
DieterGraef 24:698affe9560c 210 BSP_SD_Clear_Busy();
DieterGraef 23:c03ef1abef0e 211 return (retval ? RES_ERROR : RES_OK);
neilt6 11:67ddc53e3983 212 } else {
DieterGraef 23:c03ef1abef0e 213 BSP_SD_Set_RX_Busy();
DieterGraef 23:c03ef1abef0e 214 retval= BSP_SD_ReadBlocks_DMA((uint32_t *)buffer, (uint64_t) (sector * 512), 512, 1);
DieterGraef 24:698affe9560c 215 while((BSP_SD_Get_RX_Busy()==1)&&(retval==MSD_OK)){;}
DieterGraef 23:c03ef1abef0e 216 CPU_CACHE_Flush((uint32_t *)buffer,(512));
DieterGraef 24:698affe9560c 217 BSP_SD_Clear_Busy();
DieterGraef 23:c03ef1abef0e 218 return (retval ? RES_ERROR : RES_OK);
neilt6 0:2a6d8a096edc 219 }
neilt6 0:2a6d8a096edc 220 }
neilt6 0:2a6d8a096edc 221
neilt6 21:d10a519c0910 222 int SDFileSystem::disk_write(const uint8_t* buffer, uint32_t sector, uint32_t count)
neilt6 0:2a6d8a096edc 223 {
DieterGraef 23:c03ef1abef0e 224 int retval;
neilt6 9:1906befe7f30 225 //Make sure the card is initialized before proceeding
neilt6 0:2a6d8a096edc 226 if (m_Status & STA_NOINIT)
neilt6 0:2a6d8a096edc 227 return RES_NOTRDY;
DieterGraef 25:391eade4ef85 228 __DSB();
DieterGraef 25:391eade4ef85 229 __ISB();
DieterGraef 24:698affe9560c 230 while(BSP_SD_Get_Busy()==1){;}
DieterGraef 24:698affe9560c 231 BSP_SD_Set_Busy();
neilt6 9:1906befe7f30 232 //Make sure the card isn't write protected before proceeding
neilt6 0:2a6d8a096edc 233 if (m_Status & STA_PROTECT)
DieterGraef 24:698affe9560c 234 {
DieterGraef 24:698affe9560c 235 BSP_SD_Clear_Busy();
DieterGraef 24:698affe9560c 236 return RES_WRPRT;
DieterGraef 24:698affe9560c 237 }
neilt6 11:67ddc53e3983 238 //Write a single block, or multiple blocks
neilt6 11:67ddc53e3983 239 if (count > 1) {
DieterGraef 23:c03ef1abef0e 240 CPU_CACHE_Flush((uint32_t *)buffer,(512*count));
DieterGraef 23:c03ef1abef0e 241 BSP_SD_Set_TX_Busy();
DieterGraef 23:c03ef1abef0e 242 retval= BSP_SD_WriteBlocks_DMA((uint32_t *)buffer, (uint64_t) (sector * 512), 512, count);
DieterGraef 24:698affe9560c 243 while((BSP_SD_Get_TX_Busy()==1)&&(retval==MSD_OK)){;}
DieterGraef 24:698affe9560c 244 BSP_SD_Clear_Busy();
DieterGraef 23:c03ef1abef0e 245 return (retval? RES_ERROR : RES_OK);
neilt6 11:67ddc53e3983 246 } else {
DieterGraef 23:c03ef1abef0e 247 CPU_CACHE_Flush((uint32_t *)buffer,(512));
DieterGraef 23:c03ef1abef0e 248 BSP_SD_Set_TX_Busy();
DieterGraef 23:c03ef1abef0e 249 retval= BSP_SD_WriteBlocks_DMA((uint32_t *)buffer, (uint64_t) (sector * 512), 512, 1);
DieterGraef 24:698affe9560c 250 while((BSP_SD_Get_TX_Busy()==1)&&(retval==MSD_OK)){;}
DieterGraef 24:698affe9560c 251 BSP_SD_Clear_Busy();
DieterGraef 23:c03ef1abef0e 252 return (retval? RES_ERROR : RES_OK);
DieterGraef 23:c03ef1abef0e 253
neilt6 0:2a6d8a096edc 254 }
neilt6 0:2a6d8a096edc 255 }
neilt6 0:2a6d8a096edc 256
neilt6 0:2a6d8a096edc 257 int SDFileSystem::disk_sync()
neilt6 0:2a6d8a096edc 258 {
neilt6 0:2a6d8a096edc 259 //Select the card so we're forced to wait for the end of any internal write processes
DieterGraef 25:391eade4ef85 260 __DSB();
DieterGraef 25:391eade4ef85 261 __ISB();
DieterGraef 24:698affe9560c 262 while(BSP_SD_Get_Busy()==1){;}
DieterGraef 24:698affe9560c 263 BSP_SD_Set_Busy();
DieterGraef 23:c03ef1abef0e 264 while(BSP_SD_GetStatus()==SD_TRANSFER_BUSY){;}
DieterGraef 23:c03ef1abef0e 265 if(BSP_SD_GetStatus()==SD_TRANSFER_OK)
DieterGraef 23:c03ef1abef0e 266 {
DieterGraef 24:698affe9560c 267 BSP_SD_Clear_Busy();
neilt6 10:395539a1481a 268 return RES_OK;
neilt6 10:395539a1481a 269 } else {
DieterGraef 24:698affe9560c 270 BSP_SD_Clear_Busy();
neilt6 10:395539a1481a 271 return RES_ERROR;
neilt6 10:395539a1481a 272 }
neilt6 0:2a6d8a096edc 273 }
neilt6 0:2a6d8a096edc 274
neilt6 21:d10a519c0910 275 uint32_t SDFileSystem::disk_sectors()
neilt6 0:2a6d8a096edc 276 {
DieterGraef 23:c03ef1abef0e 277 uint32_t sectors=0;
neilt6 9:1906befe7f30 278 //Make sure the card is initialized before proceeding
neilt6 0:2a6d8a096edc 279 if (m_Status & STA_NOINIT)
neilt6 0:2a6d8a096edc 280 return 0;
DieterGraef 25:391eade4ef85 281 __DSB();
DieterGraef 25:391eade4ef85 282 __ISB();
DieterGraef 24:698affe9560c 283 while(BSP_SD_Get_Busy()==1){;}
DieterGraef 24:698affe9560c 284 BSP_SD_Set_Busy();
DieterGraef 24:698affe9560c 285 BSP_SD_GetCardInfo(&m_CardInfo);
DieterGraef 24:698affe9560c 286 sectors=m_CardInfo.CardCapacity>>9;
DieterGraef 24:698affe9560c 287 BSP_SD_Clear_Busy();
DieterGraef 23:c03ef1abef0e 288 return sectors;
neilt6 0:2a6d8a096edc 289 }
neilt6 0:2a6d8a096edc 290
neilt6 13:635147efa748 291 void SDFileSystem::onCardRemoval()
neilt6 13:635147efa748 292 {
neilt6 20:2c1e8d442f68 293 //Check the card socket
neilt6 13:635147efa748 294 checkSocket();
neilt6 13:635147efa748 295 }
neilt6 13:635147efa748 296
neilt6 13:635147efa748 297 inline void SDFileSystem::checkSocket()
neilt6 0:2a6d8a096edc 298 {
neilt6 16:c2c1f0b16380 299 //Use the card detect switch (if available) to determine if the socket is occupied
neilt6 20:2c1e8d442f68 300 if (m_CdAssert != -1) {
neilt6 20:2c1e8d442f68 301 if (m_Status & STA_NODISK) {
neilt6 20:2c1e8d442f68 302 if (m_Cd == m_CdAssert) {
neilt6 20:2c1e8d442f68 303 //The socket is now occupied
neilt6 20:2c1e8d442f68 304 m_Status &= ~STA_NODISK;
neilt6 20:2c1e8d442f68 305 m_CardType = CARD_UNKNOWN;
neilt6 20:2c1e8d442f68 306 }
neilt6 20:2c1e8d442f68 307 } else {
neilt6 20:2c1e8d442f68 308 if (m_Cd != m_CdAssert) {
neilt6 20:2c1e8d442f68 309 //The socket is now empty
neilt6 20:2c1e8d442f68 310 m_Status |= (STA_NODISK | STA_NOINIT);
neilt6 20:2c1e8d442f68 311 m_CardType = CARD_NONE;
neilt6 20:2c1e8d442f68 312 }
neilt6 20:2c1e8d442f68 313 }
neilt6 0:2a6d8a096edc 314 }
neilt6 0:2a6d8a096edc 315 }
neilt6 0:2a6d8a096edc 316
neilt6 0:2a6d8a096edc 317
DieterGraef 23:c03ef1abef0e 318 /*interrupthandlers */
DieterGraef 23:c03ef1abef0e 319 /**
DieterGraef 23:c03ef1abef0e 320 * @brief This function handles DMA2 Stream 3 interrupt request.
DieterGraef 23:c03ef1abef0e 321 * @param None
DieterGraef 23:c03ef1abef0e 322 * @retval None
DieterGraef 23:c03ef1abef0e 323 */
DieterGraef 23:c03ef1abef0e 324 void SDFileSystem::DMA2_Stream3_IRQHandler(void)
neilt6 11:67ddc53e3983 325 {
DieterGraef 23:c03ef1abef0e 326 BSP_SD_DMA_Rx_IRQHandler();
DieterGraef 23:c03ef1abef0e 327 BSP_SD_Clear_RX_Busy();
neilt6 11:67ddc53e3983 328 }
neilt6 11:67ddc53e3983 329
DieterGraef 23:c03ef1abef0e 330 /**
DieterGraef 23:c03ef1abef0e 331 * @brief This function handles DMA2 Stream 6 interrupt request.
DieterGraef 23:c03ef1abef0e 332 * @param None
DieterGraef 23:c03ef1abef0e 333 * @retval None
DieterGraef 23:c03ef1abef0e 334 */
DieterGraef 23:c03ef1abef0e 335 void SDFileSystem::DMA2_Stream6_IRQHandler(void)
neilt6 11:67ddc53e3983 336 {
DieterGraef 23:c03ef1abef0e 337 BSP_SD_DMA_Tx_IRQHandler();
DieterGraef 23:c03ef1abef0e 338 BSP_SD_Clear_TX_Busy();
neilt6 11:67ddc53e3983 339 }
neilt6 9:1906befe7f30 340
DieterGraef 23:c03ef1abef0e 341 /**
DieterGraef 23:c03ef1abef0e 342 * @brief This function handles SDIO interrupt request.
DieterGraef 23:c03ef1abef0e 343 * @param None
DieterGraef 23:c03ef1abef0e 344 * @retval None
DieterGraef 23:c03ef1abef0e 345 */
DieterGraef 23:c03ef1abef0e 346 void SDFileSystem::SDMMC1_IRQHandler(void)
neilt6 11:67ddc53e3983 347 {
DieterGraef 23:c03ef1abef0e 348 BSP_SD_IRQHandler();
neilt6 9:1906befe7f30 349 }