![Phytec phyBoard Wega AM335x Application Manual Download Page 97](http://html1.mh-extra.com/html/phytec/phyboard-wega-am335x/phyboard-wega-am335x_application-manual_1554191097.webp)
Advanced
Information
©
PHYTEC Messtechnik GmbH 2014 L-792e_1
81
4.4.2
Flashing the Bootloader
Use a bootable SD card in order to boot into Barebox.
Without any valid bootloader in NAND, the board will automatically try to
use the SD card for booting. Otherwise you need to force booting from SD
card by switching DIP switch S4 to
ON
(
The partition
boot
on the SD card should automatically be mounted as directory
/boot
by
the Barebox. Otherwise you can mount it manually using the following Barebox commands:
mkdir
/boot
mmc0.probe=1
mount
/dev/mmc0.0
/boot
Flash x-loader MLO by typing:
barebox_update
‐
t
MLO.nand
/boot/MLO
Write the Barebox into the Flash by typing:
barebox_update
‐
t
nand
/boot/barebox.bin
4.4.3
Writing the Kernel / Root File System into Flash
Flash the Linux kernel by typing:
erase
/dev/nand0.kernel.bb
cp
/boot/linuximage
/dev/nand0.kernel.bb
Flash the Oftree by typing:
erase
/dev/nand0.oftree.bb
cp
/boot/oftree
/dev/nand0.oftree.bb
Write the root file system into the Flash by typing:
ubiformat
/dev/nand0.root
ubiattach
/dev/nand0.root
ubimkvol
/dev/ubi0
root
0
cp
/boot/root.ubifs
/dev/ubi0.root