29.01.2015 Views

STM32F101xx, STM32F102xx, STM32F103xx, STM32F105xx and ...

STM32F101xx, STM32F102xx, STM32F103xx, STM32F105xx and ...

STM32F101xx, STM32F102xx, STM32F103xx, STM32F105xx and ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Secure digital input/output interface (SDIO)<br />

RM0008<br />

The bus transaction for a GEN_CMD is the same as the single-block read or write<br />

comm<strong>and</strong>s (WRITE_BLOCK, CMD24 or READ_SINGLE_BLOCK,CMD17). In this case, the<br />

argument denotes the direction of the data transfer rather than the address, <strong>and</strong> the data<br />

block has vendor-specific format <strong>and</strong> meaning.<br />

The card must be selected (in transfer state) before sending GEN_CMD (CMD56). The data<br />

block size is defined by SET_BLOCKLEN (CMD16). The response to GEN_CMD (CMD56)<br />

is in R1b format.<br />

Comm<strong>and</strong> types<br />

Both application-specific <strong>and</strong> general comm<strong>and</strong>s are divided into the four following types:<br />

● broadcast comm<strong>and</strong> (BC): sent to all cards; no responses returned.<br />

●<br />

●<br />

●<br />

broadcast comm<strong>and</strong> with response (BCR): sent to all cards; responses received<br />

from all cards simultaneously.<br />

addressed (point-to-point) comm<strong>and</strong> (AC): sent to the card that is selected; does<br />

not include a data transfer on the SDIO_D line(s).<br />

addressed (point-to-point) data transfer comm<strong>and</strong> (ADTC): sent to the card that is<br />

selected; includes a data transfer on the SDIO_D line(s).<br />

Comm<strong>and</strong> formats<br />

See Table 121 on page 464 for comm<strong>and</strong> formats.<br />

Comm<strong>and</strong>s for the MultiMediaCard/SD module<br />

Table 137.<br />

Block-oriented write comm<strong>and</strong>s<br />

CMD<br />

index<br />

Type<br />

Argument<br />

Response<br />

format<br />

Abbreviation<br />

Description<br />

CMD23<br />

ac<br />

[31:16] set to 0<br />

[15:0] number<br />

of blocks<br />

R1<br />

SET_BLOCK_COUNT<br />

Defines the number of blocks which<br />

are going to be transferred in the<br />

multiple-block read or write comm<strong>and</strong><br />

that follows.<br />

CMD24<br />

adtc<br />

[31:0] data<br />

address<br />

R1<br />

WRITE_BLOCK<br />

Writes a block of the size selected by<br />

the SET_BLOCKLEN comm<strong>and</strong>.<br />

CMD25<br />

adtc<br />

[31:0] data<br />

address<br />

R1<br />

WRITE_MULTIPLE_BLOCK<br />

Continuously writes blocks of data<br />

until a STOP_TRANSMISSION<br />

follows or the requested number of<br />

blocks has been received.<br />

CMD26 adtc [31:0] stuff bits R1 PROGRAM_CID<br />

CMD27 adtc [31:0] stuff bits R1 PROGRAM_CSD<br />

Programming of the card identification<br />

register. This comm<strong>and</strong> must be<br />

issued only once per card. The card<br />

contains hardware to prevent this<br />

operation after the first programming.<br />

Normally this comm<strong>and</strong> is reserved<br />

for manufacturer.<br />

Programming of the programmable<br />

bits of the CSD.<br />

488/995 Doc ID 13902 Rev 9

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!