bootargs
bootargs=console=ttyS0,115200 ubi.mtd=UBI,2048 root=ubi:rootfs ro rootfstype=ubifs init=/linuxrc rootwait=1 LX_MEM=0x7f00000 mma_heap=mma_heap_name0,miu=0,sz=0x3400000 mma_memblock_remove=1 highres=off mmap_reserved=fb,miu=0,sz=0x300000,max_start_off=0x7C00000,max_end_off=0x7F00000 mtdparts=nand0:384k@1280k(IPL0),384k(IPL1),384k(IPL_CUST0),384k(IPL_CUST1),768k(UBOOT0),768k(UBOOT1),256k(ENV),256k(ENV1),0x20000(KEY_CUST),0x60000(LOGO),0x500000(KERNEL),0x500000(RECOVERY),0x1600000(rootfs_bak),-(UBI)
bootargs=console=ttyS0,115200 ubi.mtd=UBI,2048 root=ubi:rootfs ro rootfstype=ubifs init=/linuxrc rootwait=1 LX_MEM=0x7f00000 mma_heap=mma_heap_name0,miu=0,sz=0x3400000 mma_memblock_remove=1 highres=off mmap_reserved=fb,miu=0,sz=0x300000,max_start_off=0x7C00000,max_end_off=0x7F00000 mtdparts=nand0:384k@1280k(IPL0),384k(IPL1),384k(IPL_CUST0),384k(IPL_CUST1),768k(UBOOT0),768k(UBOOT1),256k(ENV),256k(ENV1),0x20000(KEY_CUST),0x60000(LOGO),0x500000(KERNEL),0x500000(RECOVERY),0x1600000(rootfs_bak),-(UBI)
bootcmd
例子:
bootcmd=gpio out 4 1; gpio out 6 1; gpio out 7 0; bootlogo 0 0 0 0 1; mw 1f001cc0 11; gpio out 8 0; gpio out 1 1; gpio out 15 0; nand read.e 0x22000000 KERNEL 0x500000; gpio out 8 1; gpio out 15 1; bootm 0x22000000;nand read.e 0x22000000 RECOVERY 0x500000; bootm 0x22000000
bootcmd=gpio out 4 1; gpio out 6 1; gpio out 7 0; bootlogo 0 0 0 0 1; mw 1f001cc0 11; gpio out 8 0; gpio out 1 1; gpio out 15 0; nand read.e 0x22000000 KERNEL 0x500000; gpio out 8 1; gpio out 15 1; bootm 0x22000000;nand read.e 0x22000000 RECOVERY 0x500000; bootm 0x22000000
1. 每一条命令使用; 分割
2. 依次执行每一条命令
命令解释:
gpio out 4 1 -- gpio4 设置高电平
bootlogo 0 0 0 0 1 -- 执行bootlogo
mw 1f001cc0 11 --"这里是针对2.4G 的wifi 设置命令"
着重解释一下面的操作命令:
nand read.e 0x22000000 KERNEL 0x500000; gpio out 8 1; gpio out 15 1; bootm 0x22000000;nand read.e 0x22000000 RECOVERY 0x500000; bootm 0x22000000
nand read.e 0x22000000 KERNEL 0x500000 ; bootm 0x22000000 -- 从KERNEL 分区中读取内核到RAM 0x22000000 地址,然后执行启动内核(bootm), 正常情况,bootcmd 到此结束。
当KERNEL分区异常,无法启动内核,则执行下面操作
nand read.e 0x22000000 RECOVERY 0x500000; bootm 0x22000000 -- 从 RECOVERY读取分区到RAM 0x22000000 地址, 然后执行内核。