The phyBOARD-i.MX7 is delivered with a pre-flashed bootloader. The following instructions for flashing images from SD card will be useful if you want to:
- Flash images because NAND is empty
- Upgrade to a new release
- Use custom built images
Configure SD Card for Flashing
In addition to the standard SD card formatted in Creating a Bootable SD Card, the following steps are required to copy over images that will be flashed. Execute from the host PC:
Copy u-boot.imx-nand to the Boot partition of the SD card. In order to be able to save the environment to NAND and boot kernel images from NAND by default, the u-boot.imx-nand image is needed. The default u-boot.imx image will default to SD card. Both images are available in the release binaries.
To build a u-boot.imx-nand image with Yocto, follow the same instructions for building the BSP described in the Quickstart, but set the UBOOT_CONFIG variable to nand in $YOCTO_DIR/build/conf/local.conf before starting the build:
Create a new partition on the SD card to hold the root filesystem ext4 image.
Copy the filesystem image to the new "data" partition. Due to the size of NAND, the standard 'fsl-image-gui' and 'fsl-image-validation-imx' filesystems do not fit on NAND, so a smaller filesystem will need to be used. This example uses the Yocto image "core-image-minimal", which is included in the BSP release images.
- Set the boot switches, according to Boot Configurations, to boot from SD card and power on the board into Linux.
Erase mtd0 and use NXP's utility "kobs-ng" to flash u-boot.imx-nand to NAND:
Flash zImage and device tree :
- Power off the board, set boot switches according to Boot Configurations, and power back on.