Flashing NAND
Engicam provides shell scripts to program each NAND partition individually.
The scripts are included via the Yocto recipe engicam-mtd-script from meta-engicam-nxp.
NAND applies to i.MX6ULL modules
NAND flashing is primarily used on imx6ull-microgea with the Microdev 3.0 carrier board.
Prerequisites
Build the BSP and locate the deploy directory:
Collect the following files:
| Component | File |
|---|---|
| U-Boot | u-boot.imx |
| Kernel | zImage |
| Device Tree | <machine>.dtb |
| Root Filesystem | rootfs.tar.bz2 |
Copy them to a bootable SD card or USB stick. Boot the board from SD to access the scripts.
Warning
Verify NAND partition device nodes (/dev/mtd*) before flashing.
Writing to the wrong partition can permanently corrupt the board.
Flash U-Boot
Writes U-Boot to /dev/mtd0 using kobs-ng. Do not interrupt this step.
Flash the Kernel
Erases /dev/mtd1 and writes the kernel image.
Flash the Device Tree
Writes the DTB to /dev/mtd2.
Flash the Root Filesystem
This script:
- Formats
/dev/mtd3with UBI. - Attaches the UBI volume.
- Creates a volume named
rootfs. - Mounts the UBI filesystem.
- Extracts the root filesystem tarball.
- Syncs data to NAND.
Warning
Ensure the root filesystem archive matches the UBI layout of your target board.
Flashing via TFTP
For lab or automated environments, Engicam provides TFTP-based scripts.
Set Up the TFTP Server
Place files in the TFTP root directory with these exact names:
Set the Server IP
Verify connectivity:
Run the TFTP Scripts
| Script | Action |
|---|---|
tftp_boot.sh |
Flash U-Boot via TFTP |
tftp_kernel.sh |
Flash kernel via TFTP |
tftp_fs.sh |
Flash root filesystem via TFTP |