- 指定image/dtb文件
bootdir= bootfile=zImage fdtfile=embest-SBCC_PH8800_WLQ.dtb loadaddr=0x82000000 fdtaddr=0x88000000 finduuid=part uuid mmc ${mmcdev}:2 uuid loadfdt=fatload mmc ${mmcdev}:1 ${fdtaddr} ${fdtfile} loaduimage=fatload mmc ${mmcdev}:1 ${loadaddr} ${bootfile} uenvcmd=mdio write 7 0 0x800; mmc rescan; run loaduimage; run loadfdt; run fdtboot fdtboot=run mmc_args; bootz ${loadaddr} - ${fdtaddr} mmc_args=run finduuid; setenv bootargs console=ttyS0,115200n8 loglevel=0 systemd.log_target=null systemd.journald.forward_to_console=0 ${optargs} root=PARTUUID=${uuid} rw rootfstype=${mmcrootfstype}
- 支持切换image/dtb文件
bootdir= bootfile=zImage fdtfile=embest-SBCC_PH8800_WLQ.dtb loadaddr=0x82000000 fdtaddr=0x88000000 finduuid=part uuid mmc ${mmcdev}:2 uuid recoveryflag=false uenvcmd=if test ${recoveryflag} = "true"; then setenv bootfile zImage_bak; setenv fdtfile embest-SBCC_PH8800_WLQ_bak.dtb; echo bootfile=${bootfile} fdtfile=${fdtfile}; fi; setenv loadfdt fatload mmc ${mmcdev}:1 ${fdtaddr} ${fdtfile}; setenv loaduimage fatload mmc ${mmcdev}:1 ${loadaddr} ${bootfile}; mdio write 7 0 0x800; mmc rescan; run loaduimage; run loadfdt; run fdtboot fdtboot=run mmc_args; bootz ${loadaddr} - ${fdtaddr} mmc_args=run finduuid; setenv bootargs console=ttyS0,115200n8 loglevel=0 systemd.log_target=null systemd.journald.forward_to_console=0 ${optargs} root=PARTUUID=${uuid} rw rootfstype=${mmcrootfstype}
- 软件更新
mount -o remount,rw /boot/firmware 固件更新成功:(注意-i和语句中的三个斜杠) sed -i ‘s/recoveryflag=true/recoveryflag=false/‘ /boot/firmware/uEnv.txt 固件更新失败: sed -i ‘s/recoveryflag=false/recoveryflag=true/‘ /boot/firmware/uEnv.txt sync mount -o remount,ro /boot/firmware