#include <file_config.h>
BOOL ReadBlock (
U32 bl, /* Absolute block (sector) address. */
U8* buf, /* Location where to write the data. */
U32 cnt); /* Number of blocks (sectors) to read.*/
Description
The function ReadBlock reads data from a SD/MMC Memory Card
to a buffer.
The parameter bl specifies the starting block
from where the data are read. The parameter buf is
a pointer to the buffer that stores the data. The parameter cnt specifies the number of block to be read.
The function is part of the MCI
Driver. The prototype is defined in the file
File_Config.h. Developers must customize the function.
The following sequences are sent to read data from an SD Memory
Card:
SetDma - sets the DMA to receive data.
This can be used if DMA must be set prior to sending an SD command.
If this function does not exist (a NULL pointer in the MCI Driver
control block), then it is not called.
Command - sends a command READ_BLOCK or READ_MULT_BLOCK
to SD Memory Card.
ReadBlock - reads a block of data from SD memory Card,
or simply waits for the DMA transfer to finish.
Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers of your data.