English
Language : 

K60P100M100SF2RM Datasheet, PDF (1647/1809 Pages) Freescale Semiconductor, Inc – K60 Sub-Family Reference Manual
Chapter 52 Secured digital host controller (SDHC)
For MMC operation, the host starts the card identification process in open-drain mode
with the identification clock rate lower than 400 kHz and the power voltage higher than
2.7 V. The open drain driver stages on the CMD line allow parallel card operation during
card identification. After the bus is activated the host will request the cards to send their
valid operation conditions (CMD1). The response to CMD1 is the "wired OR" operation
on the condition restrictions of all cards in the system. Incompatible cards are sent into
the inactive state. The host then issues the broadcast command All_Send_CID (CMD2),
asking all cards for their unique card identification (CID) number. All unidentified cards
(the cards in ready state) simultaneously start sending their CID numbers serially, while
bit-wise monitoring their outgoing bit stream. Those cards, whose outgoing CID bits do
not match the corresponding bits on the command line in any one of the bit periods, stop
sending their CID immediately and must wait for the next identification cycle. Since the
CID is unique for each card, only one card can be successfully send its full CID to the
host. This card then goes into the identification state. Thereafter, the host issues
Set_Relative_Addr (CMD3) to assign to the card a relative card address (RCA). Once the
RCA is received the card state changes to the standby state, and the card does not react in
further identification cycles, and its output driver switches from open-drain to push-pull.
The host repeats the process, mainly CMD2 and CMD3, until the host receives a time-out
condition to recognize the completion of the identification process.
For CE-ATA operation (same interface as MMC cards):
card_registry()
{
do { // decide RCA for each card until response time-out
if(card is labelled as SDCombo or SDIO) { // for SDIO card like device
send_command(SET_RELATIVE_ADDR, 0x00, <...>); // ask SDIO card to publish its
RCA
retrieve RCA from response;
} // end if (card is labelled as SDCombo ...
else if (card is labelled as SD) { // for SD card
send_command(ALL_SEND_CID, <...>);
if (RESP_TIMEOUT == wait_for_response(ALL_SEND_CID)) break;
send_command(SET_RELATIVE_ADDR, <...>);
retrieve RCA from response;
} // else if (card is labelled as SD ...
else if (card is labelled as MMC or CE-ATA) { // treat CE-ATA as MMC
send_command(ALL_SEND_CID, <...>);
rca = 0x1; // arbitrarily set RCA, 1 here for example, this RCA is also the
relative address to access the CE-ATA card
send_command(SET_RELATIVE_ADDR, 0x1 << 16, <...>); // send RCA at upper 16
bits
} // end of else if (card is labelled as MMC ...
} while (response is not time-out);
}
52.6.3 Card access
This section discusses the various card access methods.
K60 Sub-Family Reference Manual, Rev. 6, Nov 2011
Freescale Semiconductor, Inc.
1647