Rainbow Electronics AT89C5132 User Manual
Page 83
83
AT8xC5132
4173A–8051–08/02
Bus Lines
The MultiMedia Card bus architecture requires all cards to be connected to the same set
of lines. No card has an individual connection to the host or other devices, which
reduces the connection costs of the MultiMedia Card system.
The bus lines can be divided into three groups:
•
Power supply: V
SS1
and V
SS2
, V
DD
– used to supply the cards.
•
Data transfer: MCMD, MDAT – used for bidirectional communication.
•
Clock: MCLK – used to synchronize data transfer across the bus.
Bus Protocol
After a Power-on reset, the host must initialize the cards by a special message-based
MultiMedia Card bus protocol. Each message is represented by one of the following
tokens:
•
Command: a command is a token which starts an operation. A command is
transferred serially from the host to the card on the MCMD line.
•
Response: a response is a token which is sent from an addressed card (or all
connected cards) to the host as an answer to a previously received command. It is
transferred serially on the MCMD line.
•
Data: data can be transferred from the card to the host or vice-versa. Data is
transferred serially on the MDAT line.
Card addressing is implemented using a session address assigned during the initializa-
tion phase, by the bus controller to all currently connected cards. Individual cards are
identified by their CID number. This method requires that every card will have an unique
CID number. To ensure uniqueness of CIDs the CID register contains 24 Bits (MID and
OID fields) which are defined by the MMCA. Every card manufacturers is required to
apply for an unique MID (and optionally OID) number.
MultiMedia Card bus data transfers are composed of these tokens. One data transfer is
a bus operation. There are different types of operations. Addressed operations always
contain a command and a response token. In addition, some operations have data
token, the others transfer their information directly within the command or response
structure. In this case no data token is present in an operation. The Bits on the MDAT
and the MCMD lines are transferred synchronous to the host clock.
Two types of data transfer commands are defined:
•
Sequential commands: These commands initiate a continuous data stream, they
are terminated only when a stop command follows on the MCMD line. This mode
reduces the command overhead to an absolute minimum.
•
Block-oriented commands: These commands send data block succeeded by CRC
Bits. Both read and write operations allow either single or multiple block
transmission. A multiple block transmission is terminated when a stop command
follows on the MCMD line similarly to the stream read.
Figure 52 to Figure 56 show the different types of operations, on these figures, grayed
tokens are from host to card(s) while white tokens are from card(s) to host.
Figure 52. Sequential Read Operation
Data Stream
Command
Response
MCMD
MDAT
Data Stop Operation
Data Transfer Operation
Command
Response
Stop Command