U-Boot使用指南:环境变量、脚本、镜像与网络启动全解析
1. U-Boot环境变量的使用
U-Boot启动并运行后,可通过设置适当的环境变量来对其进行配置,这与Unix shell(如bash)中环境变量的使用非常相似。要查看目标设备上环境变量的当前值,可使用 printenv 命令。以下是在OpenMoko GTA01开发硬件上找到的部分环境变量:
GTA01Bv4 # printenv
bootargs=
bootdelay=3
baudrate=115200
usbtty=cdc_acm
bootargs_base=rootfstype=jffs2 root=/dev/mtdblock4 console=ttySAC0,115200 console=tty0 loglevel=8
stdin=serial
stdout=serial
stderr=serial
dontask=y
bootcmd=setenv bootargs ${bootargs_base} ${mtdparts}; bootm 0x30100000
menu_1=Set console to USB: setenv stdin usbtty; setenv stdout usbtty; se
menu_2=Set console to serial: setenv stdin serial; setenv stdout serial; \
setenv stderr serial
menu_3=Power off: neo1973 power-off
splashimage=nand read.e 0x3600000
超级会员免费看
订阅专栏 解锁全文
1498

被折叠的 条评论
为什么被折叠?



