Broadcom BCM2835

Because the emmc module doesnt interpret the commands

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: o FIFOs in pingpong mode, i.e. one is used to transfer data to/from the card while the other is simultaneously accessed by DMA via the AXI bus. If the EMMC module is configured for single block transfers only one FIFO is used, so no DMA access is possible while data is transferred to/from the card and vice versa resulting in long dead times. o Registers Contrary to ArasanTM's documentation the EMMC module registers can only be accessed as 32 bit registers, i.e. the two LSBs of the address are always zero. The EMMC register base address is 0x7E300000 EMMC Address Map Address Offset 0x0 0x4 0x8 0xc 0x10 0x14 Register Name Description ACMD23 Argument Block Size and Count Argument Command and Transfer Mode Response bits 31 : 0 Response bits 63 : 32 Size 32 32 32 32 32 32 ARG2 BLKSIZECNT ARG1 CMDTM RESP0 RESP1 06 February 2012 Broadcom Europe Ltd. 406 Science Park Milton Road Cambridge CB4 0WW 2012 Broadcom Corporation. All rights reserved Page 66 0x18 0x1c 0x20 0x24 0x28 0x2c 0x30 0x34 0x38 0x3c 0x50 0x70 0x74 0x80 0x84 0x88 0x8c 0x90 0xf0 0xfc RESP2 RESP3 DATA STATUS CONTROL0 CONTROL1 INTERRUPT IRPT_MASK IRPT_EN CONTROL2 FORCE_IRPT BOOT_TIMEOUT DBG_SEL EXRDFIFO_CFG EXRDFIFO_EN TUNE_STEP TUNE_STEPS_STD TUNE_STEPS_DDR SPI_INT_SPT SLOTISR_VER Response bits 95 : 64 Response bits 127 : 96 Data Status Host Configuration bits Host Configuration bits Interrupt Flags Interrupt Flag Enable Interrupt Generation Enable Host Configuration bits Force Interrupt Event Timeout in boot mode Debug Bus Configuration Extension FIFO Configuration Extension FIFO Enable Delay per card clock tuning step Card clock tuning steps for SDR Card clock tuning steps for DDR SPI Interrupt Support Slot Interrupt Status and Version 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 32 ARG2 Register 06 February 2012 Broadcom Europe Ltd. 406 Science Park Milton Road Cambridge CB4 0WW 2012 Broadcom Corporation. All rights reserved Page 67 Synopsis This register contains the argument for the SD card specific command ACMD23 (SET_WR_BLK_ERASE_COUNT). ARG2 must be set before the ACMD23 command is issued using the CMDTM register. Description Argument to be issued with ACMD23 Type RW Reset 0x0 Bit(s) 31:0 Field Name ARGUMENT BLKSIZECNT Register Synopsis This register must not be accessed or modified while any data transfer between card and host is ongoing. It contains the number and size in bytes for data blocks to be transferred. Please note that the EMMC module restricts the maximum block size to the size of the internal data FIFO which is 1k bytes. BLKCNT is used to tell the host how many blocks of data are to be transferred. Once the data transfer has started and the TM_BLKCNT_EN bit in the CMDTM register is set the EMMC module automatically decreases the BNTCNT value as the data blocks are transferred and stops the transfer once BLKCNT reaches 0. Description Number of blocks to be transferred Reserved - Write as 0, read as don't care BLKSIZE Block size in bytes RW 0x0 Type RW Reset 0x0 Bit(s) 31:16 15:10 9:0 Field Name BLKCNT ARG1 Register Synopsis This register contains the arguments for all commands except for the SD card specific command ACMD23 which uses ARG2. ARG1 must be set before the command is issued using the CMDTM register. Description Argument to be issued with command Type RW Reset 0x0 Bit(s) 31:0 Field Name ARGUMENT 06 February 2012 Broadcom Europe Ltd. 406 Science Park Milton Road Cambridge CB4 0WW 2012 Broadcom Corporation. All rights reserved Page 68 CMDTM Register Synopsis This register is used to issue commands to the card. Besides the command it also contains flags informing the EMMC module what card response and type of data transfer to expect. Incorrect flags will result in strange behaviour. For data transfers two modes are supported: either transferring a single block of data or several blocks of the same size. The SD card uses two different sets of commands to differentiate between them but the host needs to be additionally configured using TM_MULTI_BLOCK. It is important that this bit is set correct for the command sent to the card, i.e. 1 for CMD18 and CMD25 and 0 for CMD17 and CMD24. Multiple block transfer gives a better performance. The BLKSIZECNT register is used to configure the size and number of blocks to be transferred. If bit TM_BLKCNT_EN of this register is set the transfer stops automatically after the number of data blocks configured in the BLKSIZECNT register has been transferred. The TM_AUTO_CMD_EN bits can be used to make the host to send automatically a command to the card telling it that the data transfer has finished once the BLKCNT bits in the BLKSIZECNT register are 0. Description Reserved - Write as 0, read as don't care CMD_INDEX CMD_TYPE Index of the command to be issued to the card Type of command to be issued to the card: 00 = normal 01 = suspend (the current data transfer) 10 = resume (the last data transfer) 11 = abort (the current data transfer) Command involves data transfer: 0 = no data transfer command 1 = data transfer command Check that response has same ind...
View Full Document

This note was uploaded on 04/17/2013 for the course EEC 193 taught by Professor Kevin during the Spring '13 term at UC Davis.

Ask a homework question - tutors are online