Network booting

You must first set up your PC workstation to use Digi Embedded Yocto. Follow the instructions at Set up your development workstation.

1. Open a serial connection

  1. Open a serial connection using any terminal program such as Tera Term, Minicom, Coolterm, or HyperTerminal. This documentation demonstrates using Minicom to work with the device command line.

    Use the following settings:

    Parameter Value

    Port

    Serial port where the device is connected

    Baud rate

    115200

    Data bits

    8

    Parity

    None

    Stop bits

    1

    Flow control

    None

  2. Reset the device by pressing the reset button on the board. Then immediately press any key in the serial terminal to stop the auto-boot process. The U-Boot bootloader prompt displays:

U-Boot dub-2018.03-r2.2+g2854efc (Sep 13 2019 - 20:07:29 +0000)

CPU:   Freescale i.MX8QXP revB A35 at 1000 MHz at 37C
DRAM:  2 GiB
MCA:   HW_VER=1  FW_VER=0.16
MMC:   FSL_SDHC: 0, FSL_SDHC: 1
In:    serial
Out:   serial
Err:   serial
Model: Digi International ConnectCore 8X SBC Pro Board.
ConnectCore 8X SOM variant 0x02: Industrial QuadXPlus 1.0GHz, 16GB eMMC, 2GB LPDDR4, -40/+85C, Wireless, Bluetooth
Board: ConnectCore 8X SBC Pro, version 1, ID 135
Boot:  MMC0

BuildInfo:
 - SCFW 494c97f3, SECO-FW d7523fe8, IMX-MKIMAGE abd6ce55, ATF 727cf89
 - U-Boot dub-2018.03-r2.2+g2854efc

Net:   eth0: ethernet@5b040000
Hit any key to stop autoboot:  0
=>

2. Prepare the device artifacts

  1. Get the Yocto firmware images to boot from network:

    • <kernel-file>.bin

    • <device-tree-file>.dtb

    • <rootfs-file>.rootfs.tar.bz2

    1. After building the Yocto firmware, you can find the image files inside the project directory at:

      <project_folder>/tmp/deploy/images/<platform>

    2. You can download Digi provided pre-built images from:

  2. Untar the root filesystem tarball (*.rootfs.tar.bz2) in the NFS exported directory of your development workstation. See Set up your development workstation.

    ~> sudo tar xvfp image.rootfs.tar.bz2 -C /exports/nfsroot-ccimx8x-sbc-pro
  3. Copy the kernel *.bin file to the TFTP exported directory of your development workstation.

    ~> sudo cp image.bin /tftpboot
  4. Copy the device tree *.dtb file to the TFTP exported directory of your development workstation.

    ~> sudo cp image.dtb /tftpboot

Read the board_id of your platform from U-Boot to find out the appropriate device tree file for your platform. For example:

=> printenv board_id
board_id=129
=>

The dtb file name of your device device tree for your platform follows the format: Image.gz—​4.9-r0.2-<platform>-id<board_id>-<date>.dtb

3. Configure your device’s network settings

  1. Get a dynamic IP for your target:

    => setenv autoload no
    => dhcp

    or you can set a static IP:

    => setenv ipaddr 192.168.115.222
  2. Configure the IP of the development workstation with TFTP and NFS servers installed. See Set up your development workstation:

    => setenv serverip 192.168.115.1

4. Boot from network

Boot from TFTP+NFS

  1. Set the directory with the rootfs to mount. This directory is the one exported via NFS in your development workstation. See Set up an NFS server.

    => setenv rootpath /exports/nfsroot-ccimx8x-sbc-pro
  2. Specify the device tree (*.dtb) file name. This is the name of the *.dtb file you copied to the TFTP exported directory of your development workstation.

    => setenv fdt_file image.dtb
  3. Establish the kernel file (*.bin) name. This is the name of the *.bin file you copied to the TFTP exported directory of your development workstation.

    => setenv imagegz image.bin
  4. Save the changes.

    => saveenv
  5. Boot from TFTP.

    => dboot linux tftp

    You can make these changes persistent by writing the following command:

    => setenv bootcmd 'dboot linux tftp'
    => saveenv

The target now loads the kernel and device tree from the TFTP server and the root filesystem from the NFS server.

Boot entirely from NFS

To avoid using TFTP for kernel and device tree files and boot everything from NFS, copy the kernel *.bin and device tree *.dtb files to the NFS-exported directory of your development workstation (instead of to the TFTP directory). See Set up an NFS server.

=> dboot linux nfs