AM335x USB Boot详细说明

首先,要rev2.1的芯片才支持,以前的cpu有bug,无法使用usb boot

上位机需要uniflash,

以太网上截取的报文,可以进入第一阶段

AM335x自动从c:\am335x_flashtool\images目录下下载u-boot-spl-restore.bin

http://processors.wiki.ti.com/index.php/Sitara_Linux_AM335x_Flash_Programming_Linux_Development

注意,需要先关掉windows防火墙,才能tftp下载成功。

必须要用ubuntu才能编译,uboot下的config,需要用am335x_evm_XXXXXX, 在board.cfg 里能看到支持的平台,

make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- O=flash-restore am335x_evm_ usbspl

然后执行拷贝,到uniflash的tftp主目录,改成固定文件名,就能看到打印信息。串口0上

COPY Z:\media\disk2\ti-sdk-am335x-evm-07.00.00.00\board-support\u-boot-2013.10-ti2013.12.01\flash-restore\u-boot.img C:\AM335x_Flashtool\images\u-boot-restore.img

COPY Z:\media\disk2\ti-sdk-am335x-evm-07.00.00.00\board-support\u-boot-2013.10-ti2013.12.01\flash-restore\spl\u-boot-spl.bin C:\AM335x_Flashtool\images\u-boot-spl-restore.bin

串口上的输出结果

U-Boot SPL 2013.10-00189-g78d8ebd-dirty (Jun 23 2014 - 13:00:54)

Could not read the EEPROM; something fundamentally wrong on the I2C bus.

Could not get board ID.

Could not read the EEPROM; something fundamentally wrong on the I2C bus.

Could not get board ID.

Unknown board, cannot configure pinmux.### ERROR ### Please RESET the board ###

看来我的理解没有错,SPL被通过usb Ethernet的tftp下载到内部sram上执行,执行后usb口再次被枚举成USB RNDIS以太网,下载uboot,然后再用uboot根据脚本Debrick Script下载内核文件系统等。整体的流程就是这样无疑。

U-Boot SPL 2013.10-00189-g78d8ebd-dirty (Jun 24 2014 - 13:00:20)

Using default environment

usb_ether

using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in

MAC d0:ff:50:03:cc:14

HOST MAC de:ad:be:af:00:00

RNDIS ready

musb-hdrc: peripheral reset irq lost!

high speed config #2: 2 mA, Ethernet Gadget, using RNDIS

USB RNDIS network up!

BOOTP broadcast 1

BOOTP broadcast 2

BOOTP broadcast 3

Using usb_ether device

TFTP from server 192.168.2.1; our IP address is 192.168.2.2

Filename 'u-boot-restore.img'.

Load address: 0x807fffc0

Loading: ###########################

         752 KiB/s

done

Bytes transferred = 388968 (5ef68 hex)

U-Boot 2013.10-00189-g78d8ebd-dirty (Jun 24 2014 - 13:00:20)

I2C:   ready

DRAM:  128 MiB

NAND:  128 MiB

MMC:   OMAP SD/MMC: 0, OMAP SD/MMC: 1

Net:   cpsw, usb_ether

Hit any key to stop autoboot:  0

mmc0 is current device

Scanning mmc 0...

** File not found /boot/zImage **

mmc0 is current device

SD/MMC found on device 0

reading uEnv.txt

** Unable to read file uEnv.txt **

** File not found /boot/zImage **

Card did not respond to voltage select!

mmc1(part 0) is current device

Card did not respond to voltage select!

Booting from nand ...

NAND read: device 0 offset 0x80000, size 0x40000

 262144 bytes read: OK

NAND read: device 0 offset 0x200000, size 0x800000

 8388608 bytes read: OK

Bad Linux ARM zImage magic!

U-Boot# setenv ethact usb_ether

U-Boot# tftp 0x80008000 zImage

using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in

MAC d0:ff:50:03:cc:16

HOST MAC de:ad:be:af:00:00

RNDIS ready

musb-hdrc: peripheral reset irq lost!

high speed config #2: 2 mA, Ethernet Gadget, using RNDIS

USB RNDIS network up!

Using usb_ether device

TFTP from server 192.168.100.111; our IP address is 192.168.100.241

Filename 'zImage'.

Load address: 0x80008000

Loading: T T

Abort

U-Boot# setenv ipaddr 192.168.2.2

U-Boot# setenv serverip 192.168.2.1

U-Boot# saveenv

Saving Environment to NAND...

Erasing NAND...

Erasing at 0x1c0000 -- 100% complete.

Writing to NAND... OK

U-Boot# tftp 0x80000000 zImage

using musb-hdrc, OUT ep1out IN ep1in STATUS ep2in

MAC d0:ff:50:03:cc:16

HOST MAC de:ad:be:af:00:00

RNDIS ready

high speed config #2: 2 mA, Ethernet Gadget, using RNDIS

USB RNDIS network up!

Using usb_ether device

TFTP from server 192.168.2.1; our IP address is 192.168.2.2

Filename 'zImage'.

Load address: 0x80000000

Loading: T #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #################################################################

         #######################

         2 MiB/s

done

Bytes transferred = 32768000 (1f40000 hex)

U-Boot#

至此,usbboot已经完成功能,能通过usb下载boot和内核了,文件系统等均可以用usb eth通过tftp下载。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值