1. Install TFTP on Ubuntu.
2. Please copy the kernel and file system to tftp directory under Ubuntu system, for example, copy uImage and ubi.img to the /tftpboot directory under Ubuntu system.
3. 1) Press “Enter” to get into u-boot command mode when the board start countdown;
2) Configure u-boot environment;
1 set ipaddr 192.168.1.250
2 set ethaddr 88:33:14:f6:c0:d4
3 set serverip 192.168.1.220
4 saveenv
5 reset
The above commands are used for setting IP address of the board, MAC address of the Ethernet, IP address of the Ubuntu Host server, saving variables and restart. Then use ping command to ensure the board pings through with the Host.
1 ping 192.168.1.220
2 Auto negotitation failed
3 link up on port 0, speed 100, full duplex
4 Using cpsw device
5 host 192.168.1.220 is alive
For above, if prompts “host xxx is alive”, it means the board has pinged through with the Host successfully. If failed, it will prompts as below:
1 MYD_AM335X# ping 192.168.1.220
2 Auto negotitation failed
3 Auto negotitation failed
4 Using cpsw device
5 ping failed; host 192.168.1.220 is not alive
3) Acquire Address Assignment
Use printenv to check u-boot environment variables
1 printenv
There will be some output as below:
"updatesys=nand erase.chip;mmc rescan; fatload mmc 0 82000000 MLO;nandecc hw 2;nand write.i 82000000 0 ${filesize}; fatload mmc 0 82000000 u-boot.img;nandecc hw 2;nand write.i 82000000 80000 ${filesize}; fatload mmc 0 82000000 uImage;nandecc hw 2;nand write.i 82000000 280000 ${filesize}; fatload mmc 0 82000000 ubi.img;nandecc sw;nand write.i 82000000 780000 ${filesize};led flash all"
all
The purple part indicates programming MLO; the red part indicates programming u-boot; the green part indicates programming uImage; the blue part indicates programming filesystem, the nandecc hw 2 and the nandecc sw need ECC hardware checking and software checking.
The address assignment is as below:
First boot address: 0x0
RAM memory address: 0x82000000
u-boot address: 0x80000
kernel address: 0x280000
ubi.img
filesystem address: 0x780000
4) Download kernel
Download kernel from PC to the board RAM 0x82000000, the length will be reminded after succeed such as Bytes transferred = 3605768 (370508 hex)
1
2 tftp 0x82000000 uImage
nandecc hw
2 #AM335X kernel needs ecc checking or it will have error: ECC: uncorrectable.
If executing above command, it displays “#”, it means transmitting file; if prompts “TTT…”, it means transmitting overtime, you may need to check if the board has pinged through Host successfully.
Erase the content of 0x370508 byte from 0x280000 address:
1 nand erase 0x280000 0x370508
Write the content of RAM 0x82000000 to Flash address 0x280000, length is 0x3605768:
1 nand write.i 0x82000000 0x280000 0x370508
For above
-
nand write.jffs2 program JFFS2 file system, jump over the bad block
-
nand write.i equal to nand write.jffs2
-
nand write.yaffs program yaffs2 file system, need page aligned
Download file sytem
Download file system from PC to the board RAM 0x82000000, the length will be prompted after downloading successfully, using hexadecimal, command is as below:
1 tftp 0x82000000 ubi.img
2 nandecc sw #AM335X kernel needs ecc software checking
Note: due to the large size of filesystem, please do not interrupt during the filesystem transmitting to avoid failure.
Erase the content of 0x3da000 byte from 0x780000
1 nand erase 0x780000 0x3da0000
Write the content of RAM 0x82000000 to the FLASH 0x780000 with length 0x3da0000:
1 nand write.i 0x82000000 0x780000 0x3da0000
|