Monday, June 3, 2013

uboot mmc read / write command usage

mmc read is used to read the contents into memory,
mmc write is used to write the contents of memory to the mmc

Specific usage
mmc read <device num> addr blk # cnt [partition]
mmc write <device num> addr blk # cnt [partition]
mmc list
mmc device num is the device number, you can query through mmc list
addr is the memory address
blk # is the number of blocks within mmc
cnt number of blocks

Example:
mmc write 2 0x90000000 0x600 0x10
The memory 0x90000000, length 16x512 size data, write to 2 mmc device block at offset position of 0x600

mmc read 2 0x90000000 0x600 0x10
Mmc device of the second block starting at offset 0x600, 16x512 size of length data, read out to the memory at 0x90000000

3 comments:

  1. Hi, how did you calculate this address: 0x90000000?

    ReplyDelete
  2. This is RAM address. You may have to check the data sheet

    ReplyDelete