SanDisk SDSDB-32-201-80 - Industrial Grade Flash Memory Card Product Manual page 62

Secure digital card
Table of Contents

Advertisement

Secure Digital (SD) Card Protocol Description
After receiving a block of data and completing the CRC check, the card will begin writing and hold the DAT0 line
low if its write buffer is full and unable to accept new data from a new WRITE_BLOCK command. The host may
poll the status of the card with a SEND_STATUS command (CMD13) at any time, and the card will respond with
its status. The status bit READY_FOR_DATA indicates whether the card can accept new data or whether the write
process is still in progress. The host may deselect the card by issuing CMD7 (to select a different card), which will
displace the card into the Disconnect State and release the DAT line without interrupting the write operation. When
reselecting the card, it will reactivate busy indication by pulling DAT to low if programming is still in progress and
the write buffer is unavailable. Actually, the host may perform simultaneous write operations to several cards by
using an inter- leaving process. The interleaving process can be done by accessing each card separately while other
cards are in busy. This process can be done by proper CMD and DAT0-3 line manipulations (disconnection of busy
cards).
Pre-erase setting prior to a multiple block write operation
Setting a number of write blocks to be pre_erased (ACMD23) will make a following Multiple Block Write
operation faster compared to the same operation without preceding ACMD23. The host will use this command to
define how many write blocks are going to be sent in the next write operation. If the host terminates the write
operation (using stop transmission) before all the data blocks are sent to the card, the content of the remaining write
blocks is undefined (can be either erased or still have the old data). If the host sends a greater number of write
blocks than are defined in ACMD23, the card will erase blocks one by one (as new data is received). This number
will be reset to the default (=1) value after Multiple Blocks Write operation.
It is recommended to use this command preceding CMD25, so that SanDisk's SD Card will be faster for Multiple
Write Blocks operation. Note that the host must send ACMD23 just before the WRITE command if the host wants
to use the pre-erase feature. If not, pre-erase-count might be cleared automatically when another command (ex:
Security Application Commands) is executed.
Send Number of Written Blocks
Systems that use the PipeLine mechanism for data buffers management are, in some cases, unable to determine
which block was the last to be well written to the flash if an error occurs in the middle of a Multiple Blocks Write
operation. The card will respond to ACMD22 with the number of well-written blocks.
Erase
It is desirable to erase many write blocks simultaneously in order to enhance the data throughput. Identification of
these write blocks is accomplished with the ERASE_WR_BLK_START (CMD32), ERASE_WR_BLK_END
(CMD33) commands.
The host must adhere to the following command sequence: ERASE_WR_BLK_START, ERASE_WR_BLK_END
and ERASE (CMD38).
If an erase (CMD38) or address setting (CMD32, 33) command is received out of sequence, the card shall set the
ERASE_SEQ_ERROR bit in the status register and reset the whole sequence.
If an out of sequence command (except SEND_STATUS) is received, the card shall set the ERASE_RESET status
bit in the status register, reset the erase sequence and execute the last command.
If the erase range includes write protected sectors, they shall be left intact and only the non-protected sectors shall
be erased. The WP_ERASE_SKIP status bit in the status register shall be set.
The address field in the address setting commands is a write block address in byte units. The card will ignore all
LSBs below the WRITE_BLK_LEN (see CSD) size.
4-12
SanDisk Secure Digital (SD) Card Product Manual, Rev. 1.9 © 2003 SANDISK CORPORATION

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents