![NXP Semiconductors LCP43 Series User Manual Download Page 1255](http://html1.mh-extra.com/html/nxp-semiconductors/lcp43-series/lcp43-series_user-manual_17218171255.webp)
UM10503
All information provided in this document is subject to legal disclaimers.
© NXP B.V. 2012. All rights reserved.
User manual
Rev. 1.3 — 6 July 2012
1255 of 1269
NXP Semiconductors
UM10503
Chapter 50: Supplementary information
Chapter 20: LPC43xx SD/MMC interface
How to read this chapter . . . . . . . . . . . . . . . . 414
Basic configuration . . . . . . . . . . . . . . . . . . . . 414
Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 414
General description . . . . . . . . . . . . . . . . . . . . 414
Pin description . . . . . . . . . . . . . . . . . . . . . . . . 415
Register description . . . . . . . . . . . . . . . . . . . 416
Control Register (CTRL) . . . . . . . . . . . . . . . . 417
Power Enable Register (PWREN) . . . . . . . . 420
Clock Divider Register (CLKDIV) . . . . . . . . . 420
SD Clock Source Register (CLKSRC) . . . . . 421
Clock Enable Register (CLKENA) . . . . . . . . 421
Time-out Register (TMOUT) . . . . . . . . . . . . . 421
Card Type Register (CTYPE) . . . . . . . . . . . . 422
Block Size Register (BLKSIZ). . . . . . . . . . . . 422
Byte Count Register (BYTCNT) . . . . . . . . . . 422
Mask Register (INTMASK) . . . . . . . 422
Command Argument Register (CMDARG). . 423
Command Register (CMD) . . . . . . . . . . . . . . 424
Response Register 0 (RESP0) . . . . . . . . . . . 426
Response Register 1 (RESP1) . . . . . . . . . . . 427
Response Register 2 (RESP2) . . . . . . . . . . . 427
Response Register 3 (RESP3) . . . . . . . . . . . 427
Masked Interrupt Status Register (MINTSTS) 427
Raw Interrupt Status Register (RINTSTS) . . 428
Status Register (STATUS) . . . . . . . . . . . . . . 430
FIFO Threshold Watermark Register
(FIFOTH) . . . . . . . . . . . . . . . . . . . . . . . . . . . 431
Write Protect Register (WRTPRT) . . . . . . . . 433
Transferred Host to BIU-FIFO Byte Count
Register (TBBCNT). . . . . . . . . . . . . . . . . . . . 433
Debounce Count Register (DEBNCE) . . . . . 433
Hardware Reset (RST_N). . . . . . . . . . . . . . . 433
Bus Mode Register (BMOD) . . . . . . . . . . . . . 434
Poll Demand Register (PLDMND) . . . . . . . . 434
(DBADDR) . . . . . . . . . . . . . . . . . . . . . . . . . . 435
Internal DMAC Status Register (IDSTS). . . . 435
Functional description . . . . . . . . . . . . . . . . . 437
Power/pull-up control and card detection unit 437
Auto-Stop . . . . . . . . . . . . . . . . . . . . . . . . . . . 438
restrictions . . . . . . . . . . 439
Programming sequence. . . . . . . . . . . . . . . . 441
20.7.4.1 Initialization . . . . . . . . . . . . . . . . . . . . . . . . . 441
20.7.4.2 Enumerated Card Stack . . . . . . . . . . . . . . . . 441
20.7.4.3 Clock Programming . . . . . . . . . . . . . . . . . . . 442
20.7.4.4 No-Data Command With or Without Response
Sequence. . . . . . . . . . . . . . . . . . . . . . . . . . . 443
20.7.4.5 Data Transfer Commands . . . . . . . . . . . . . . 444
20.7.4.6 Single-Block or Multiple-Block Read . . . . . . 445
20.7.4.7 Single-Block or Multiple-Block Write . . . . . . 446
20.7.4.8 Stream Read . . . . . . . . . . . . . . . . . . . . . . . . 448
20.7.4.9 Stream Write . . . . . . . . . . . . . . . . . . . . . . . . 448
20.7.4.10 Sending Stop or Abort in Middle of Transfer 448
20.7.5
Suspend or Resume Sequence . . . . . . . . . . 449
20.7.5.1 Read_Wait Sequence . . . . . . . . . . . . . . . . . 451
20.7.5.2 CE-ATA Data Transfer Commands . . . . . . . 451
20.7.5.2.1 Reset and Device Recovery . . . . . . . . . . . . 451
20.7.5.2.2 ATA Task File Transfer . . . . . . . . . . . . . . . . . 452
20.7.5.2.3 ATA Payload Transfer Using
RW_MULTIPLE_BLOCK (RW_BLK) . . . . . . 453
20.7.5.2.4 Sending Command Completion Signal
Disable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 455
20.7.5.2.5 Recovery after Command Completion Signal
Time-out . . . . . . . . . . . . . . . . . . . . . . . . . . . . 455
20.7.5.2.6 Reduced ATA Command Set . . . . . . . . . . . . 455
20.7.5.3 Controller/DMA/FIFO Reset Usage . . . . . . . 457
20.7.5.4 Error Handling . . . . . . . . . . . . . . . . . . . . . . . 458
20.7.6
DMA descriptors . . . . . . . . . . . . . . . . . . . . . 459
20.7.6.1 SD/MMC DMA descriptors . . . . . . . . . . . . . . 460
20.7.6.1.1 SD/MMC DMA descriptor DESC0 . . . . . . . 460
20.7.6.1.2 SD/MMC DMA descriptor DESC1 . . . . . . . . 461
20.7.6.1.3 SD/MMC DMA descriptor DESC2 . . . . . . . . 461
20.7.6.1.4 SD/MMC DMA descriptor DESC3 . . . . . . . . 461
20.7.6.2 Initialization . . . . . . . . . . . . . . . . . . . . . . . . . 462
20.7.6.3 Host bus burst access . . . . . . . . . . . . . . . . . 462
20.7.6.4 Host data buffer alignment . . . . . . . . . . . . . . 462
20.7.6.5 Buffer size calculations . . . . . . . . . . . . . . . . 462
20.7.6.6 Transmission . . . . . . . . . . . . . . . . . . . . . . . . 463
20.7.6.7 Reception. . . . . . . . . . . . . . . . . . . . . . . . . . . 463
20.7.6.8 Interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . 464
20.7.6.9 Abort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 464
20.7.6.10 FBE scenarios . . . . . . . . . . . . . . . . . . . . . . . 465
20.7.6.11 FIFO overflow and underflow. . . . . . . . . . . . 465
20.7.6.12 Programming of PBL and watermark levels. 465
Chapter 21: LPC43xx External Memory Controller (EMC)
How to read this chapter . . . . . . . . . . . . . . . . 466
Basic configuration . . . . . . . . . . . . . . . . . . . . 466
Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 467
General description . . . . . . . . . . . . . . . . . . . . 468
Memory bank select . . . . . . . . . . . . . . . . . . . 469
Pin description . . . . . . . . . . . . . . . . . . . . . . . . 470
Register description . . . . . . . . . . . . . . . . . . . 470
EMC Control register . . . . . . . . . . . . . . . . . 473
EMC Status register . . . . . . . . . . . . . . . . . . 474
EMC Configuration register . . . . . . . . . . . . . 475