|
SdFat
|
Raw SDIO access to SD and SDHC flash memory cards. More...
#include <PioSdioCard.h>


Public Member Functions | |
| bool | begin (PioSdioConfig config) |
| bool | cardCMD6 (uint32_t arg, uint8_t *status) final |
| void | end () final |
| bool | erase (Sector_t firstSector, Sector_t lastSector) final |
| uint8_t | errorCode () const final |
| uint32_t | errorData () const final |
| uint32_t | errorLine () const |
| virtual bool | hasDedicatedSpi () |
| bool | isBusy () final |
| virtual bool | isDedicatedSpi () |
| virtual bool | isSpi () |
| uint32_t | kHzSdClk () |
| bool | readCID (cid_t *cid) final |
| bool | readCSD (csd_t *csd) final |
| bool | readData (uint8_t *dst) |
| bool | readOCR (uint32_t *ocr) final |
| bool | readSCR (scr_t *scr) final |
| bool | readSDS (sds_t *sds) final |
| bool | readSector (Sector_t sector, uint8_t *dst) final |
| bool | readSectors (Sector_t sector, uint8_t *dst, size_t ns) final |
| bool | readStart (Sector_t sector) |
| bool | readStop () |
| Sector_t | sectorCount () final |
| virtual bool | setDedicatedSpi (bool value) |
| uint32_t | status () final |
| bool | stopTransmission (bool blocking) |
| bool | syncDevice () final |
| uint8_t | type () const final |
| bool | writeData (const uint8_t *src) |
| bool | writeSector (Sector_t sector, const uint8_t *src) final |
| bool | writeSectors (Sector_t sector, const uint8_t *src, size_t ns) final |
| bool | writeStart (Sector_t sector) |
| bool | writeStop () |
Raw SDIO access to SD and SDHC flash memory cards.
| bool PioSdioCard::begin | ( | PioSdioConfig | config | ) |
Initialize the SD card.
| [in] | config | SDIO card configuration. |
|
finalvirtual |
CMD6 Switch mode: Check Function Set Function.
| [in] | arg | CMD6 argument. |
| [out] | status | return status data. |
Implements SdCardInterface.
|
finalvirtual |
Disable an SDIO card. not implemented.
Reimplemented from FsBlockDeviceInterface.
Erase a range of sectors.
| [in] | firstSector | The address of the first sector in the range. |
| [in] | lastSector | The address of the last sector in the range. |
Implements SdCardInterface.
|
finalvirtual |
Implements SdCardInterface.
|
finalvirtual |
Implements SdCardInterface.
| uint32_t PioSdioCard::errorLine | ( | ) | const |
|
inlinevirtualinherited |
|
finalvirtual |
|
inlinevirtualinherited |
|
inlinevirtualinherited |
| uint32_t PioSdioCard::kHzSdClk | ( | ) |
|
finalvirtual |
Read a card's CID register. The CID contains card identification information such as Manufacturer ID, Product name, Product serial number and Manufacturing date.
| [out] | cid | pointer to area for returned data. |
Implements SdCardInterface.
|
finalvirtual |
Read a card's CSD register. The CSD contains Card-Specific Data that provides information regarding access to the card's contents.
| [out] | csd | pointer to area for returned data. |
Implements SdCardInterface.
| bool PioSdioCard::readData | ( | uint8_t * | dst | ) |
Read one data sector in a multiple sector read sequence
| [out] | dst | Pointer to the location for the data to be read. |
|
finalvirtual |
Read OCR register.
| [out] | ocr | Value of OCR register. |
Implements SdCardInterface.
|
finalvirtual |
Read SCR register.
| [out] | scr | Value of SCR register. |
Implements SdCardInterface.
|
finalvirtual |
Return the 64 byte SD Status register.
| [out] | sds | location for 64 status bytes. |
Implements SdCardInterface.
|
finalvirtual |
Read a 512 byte sector from an SD card.
| [in] | sector | Logical sector to be read. |
| [out] | dst | Pointer to the location that will receive the data. |
Implements FsBlockDeviceInterface.
|
finalvirtual |
Read multiple 512 byte sectors from an SD card.
| [in] | sector | Logical sector to be read. |
| [in] | ns | Number of sectors to be read. |
| [out] | dst | Pointer to the location that will receive the data. |
Implements FsBlockDeviceInterface.
| bool PioSdioCard::readStart | ( | Sector_t | sector | ) |
Start a read multiple sectors sequence.
| [in] | sector | Address of first sector in sequence. |
| bool PioSdioCard::readStop | ( | ) |
End a read multiple sectors sequence.
|
finalvirtual |
Determine the size of an SD flash memory card.
Implements FsBlockDeviceInterface.
|
inlinevirtualinherited |
Set SPI sharing state
| [in] | value | desired state. |
|
finalvirtual |
Reimplemented from SdCardInterface.
| bool PioSdioCard::stopTransmission | ( | bool | blocking | ) |
Send CMD12 to stop read or write.
| [in] | blocking | If true, wait for command complete. |
|
finalvirtual |
Implements FsBlockDeviceInterface.
|
finalvirtual |
Return the card type: SD V1, SD V2 or SDHC
Implements SdCardInterface.
| bool PioSdioCard::writeData | ( | const uint8_t * | src | ) |
Write one data sector in a multiple sector write sequence.
| [in] | src | Pointer to the location of the data to be written. |
|
finalvirtual |
Writes a 512 byte sector to an SD card.
| [in] | sector | Logical sector to be written. |
| [in] | src | Pointer to the location of the data to be written. |
Implements FsBlockDeviceInterface.
|
finalvirtual |
Write multiple 512 byte sectors to an SD card.
| [in] | sector | Logical sector to be written. |
| [in] | ns | Number of sectors to be written. |
| [in] | src | Pointer to the location of the data to be written. |
Implements FsBlockDeviceInterface.
| bool PioSdioCard::writeStart | ( | Sector_t | sector | ) |
Start a write multiple sectors sequence.
| [in] | sector | Address of first sector in sequence. |
| bool PioSdioCard::writeStop | ( | ) |
End a write multiple sectors sequence.