=> mmc -help
mmc - MMC sub system
Usage:
mmc info - display info of the current MMC device
mmc read addr blk# cnt
mmc write addr blk# cnt
mmc erase blk# cnt
mmc rescan
mmc part - lists available partition on current mmc device
mmc dev [dev] [part] - show or set current mmc device [partition]
mmc list - lists available devices
mmc hwpartition [args...] - does hardware partitioning
arguments (sizes in 512-byte blocks):
[user [enh start cnt] [wrrel {on|off}]] - sets user data area attributes
[gp1|gp2|gp3|gp4 cnt [enh] [wrrel {on|off}]] - general purpose partition
[check|set|complete] - mode, complete set partitioning completed
WARNING: Partitioning is a write-once setting once it is set to complete.
Power cycling is required to initialize partitions after set to complete.
mmc setdsr <value> - set DSR register value
=> md.b
md - memory display
Usage:
md [.b, .w, .l] address [# of objects]
s5p4418# mmc list
NXP DWMMC: 0 //sd卡
NXP DWMMC: 1
NXP DWMMC: 2 //emmc
s5p4418# mmc info
Device: NXP DWMMC
Manufacturer ID: 15
OEM: 100
Name: 8GME4
Tran Speed: 52000000
Rd Block Len: 512
MMC version 4.0
High Capacity: Yes
Capacity: 7.3 GiB
Bus Width: 4-bit
emmc的第0x400块开始的2块存放着环境变量
读取环境变量
mmc read 48000000 400 2
md.b 48000000 3b0
md.b 48031400 3b0
480313f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
48031400: 5d d0 a6 e0 62 61 75 64 72 61 74 65 3d 31 31 35 ]...baudrate=115
......
48031790: 6f 75 74 3d 73 65 72 69 61 6c 00 74 70 3d 63 61 out=serial.tp=ca
480317a0: 70 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 p...............
480317b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
擦除emmc存放环境变量的两块
mmc erase 400 2
TBC
因篇幅问题不能全部显示,请点此查看更多更全内容