bool SdioSecureDigitalCard::eraseBlocks(uint32_t blockIndex_,uint32_t numBlocks_) { uint32_t startAddr,endAddr; startAddr=blockIndex_ * getBlockSizeInBytes(); endAddr=startAddr + (getBlockSizeInBytes() * numBlocks_); return handleReturnCode(SD_Erase(startAddr,endAddr),E_FAILED_TO_ERASE_BLOCKS); }
uint32_t SdioDmaSdCard::getTotalBlocksOnDevice() { return getCardCapacityInBytes()/getBlockSizeInBytes(); }
bool SdioSecureDigitalCard::readBlocks(void *pDest_,uint32_t blockIndex_,uint32_t numBlocks_) { return handleReadReturn(SD_ReadMultiBlocks(static_cast<uint8_t *> (pDest_),blockIndex_,getBlockSizeInBytes(),numBlocks_),E_FAILED_TO_READ_MULTIBLOCK); }
bool SdioSecureDigitalCard::writeBlocks(void *pDest_,uint32_t blockIndex_,uint32_t numBlocks_) { return handleWriteReturn(SD_WriteMultiBlocks(static_cast<uint8_t *> (pDest_),blockIndex_,getBlockSizeInBytes(),numBlocks_),E_FAILED_TO_WRITE_MULTIBLOCK); }