Boot TEZI on Custom Carrier Board

Hi Toradex Community,

I am currently working with an Apalis iMX6 for a medical device prototype. As per the design, it is currently inserted on a custom PCB, where some of the peripherals have been spread on it, including 2 USB ports. NOTE: There is no USB Debug Bridge port.

One is for a touchscreen, and the other is available to insert USB drive to modify files inside the iMX6.

I am looking to start using Toradex Easy Installer as an update tool directly on our custom board, rather than having to remove it, insert it on one of our Ixora, and then updating via TEZI.

On the Ixora board, TEZI is working as intended. I usually launch and stop at U-Boot, and launch the bootable USB with the command run bootcmd_usb0.

On the custom board, however, if I perform the same step for that same USB stick, I get the following error output:

Apalis iMX6 # run bootcmd_usb0
starting USB...
USB0: Port not available.
USB1: USB EHCI 1.00
scanning bus 1 for devices... 4 USB Device(s) found
       scanning usb for storage devices... 1 Storage Device(s) found
       scanning usb for ethernet devices... 0 Ethernet Device(s) found

USB device 0:
    Device 0: Vendor: Verbatim Rev: 2.00 Prod: STORE N GO
            Type: Removable Hard Disk
            Capacity: 3730.0 MB = 3.6 GB (7639040 x 512)
... is now current device
Scanning usb 0:1...
Found U-Boot script /boot.scr
reading /boot.scr
2478 bytes read in 23 ms (104.5 KiB/s)
## Executing script at 17000000
reading /tezi.itb
33009184 bytes read in 2719 ms (11.6 MiB/s)
reading overlays.txt
170 bytes read in 18 ms (8.8 KiB/s)
Bootargs: console=ttymxc0,115200 quiet video=DPI-1:640x480D video=HDMI-A-1:640x480-16@60D video=LVDS-1:d video=VGA-1:640x480-16@60D rootfstype=squashfs root=/dev/ram autoinstall
## Loading kernel from FIT Image at 12100000 ...
Could not find configuration node
ERROR: can't get kernel image!
SCRIPT FAILED: continuing...
Apalis iMX6 #

Any idea what the issue could be? For reference, I am using TEZI v5.7.2.

Thanks in advance.
Anthony

All Apalis iMX6 modules shipped with pre-installed Toradex Easy Installer. So you don’t need to start it from USB. As for ona fiels device update I’d recommend to use Over-The-Air Update Solutions

Hi @alex.tx ,

A bit more context to my situation; we eventually wish to upgrade already flashed boards. The devices are air gapped and do not have access to the network. The image is also built with Yocto. So OTA solutions wouldn’t be viable in our case.

In this case, there is currently no simple solution to upgrade the OS without being able to launch TEZI from an external drive.

So currently we have 2 options:

  1. Have a field service technician travel to each site with a Toradex Carrier Board, unmount the iMX6 from the device, mount it on the Carrier board, perform the update, and install it back on the custom device. This process would approximately take 1 to 2 hours + design of a fixture that would include a Toradex Carrier Board.

  2. Have a field service technician travel with a USB stick, and perform the update directly on the custom device. Which sounds alot more appealing. This process would take about 15 minutes.

Option 2 seems much better for all the parties, but that can only happen if TEZI can boot via a custom carrier board.

Thanks.
Anthony

Possible causes for this issue could be an incorrect path to the kernel image, Please check your boot.scr. Could you also provide a boot log when you booting from same USB on Ixora board?

Hi @alex.tx ,

Here is the content of my boot.scr file:

boot.scr
'V'ðcöy§  	n        n± Distro boot script                	f    setenv bootargs console=ttymxc0,115200 quiet video=DPI-1:640x480D video=HDMI-A-1:640x480-16@60D video=LVDS-1:d video=VGA-1:640x480-16@60D rootfstype=squashfs root=/dev/ram autoinstall ${teziargs}

# Re-enable fdt relocation since in place fdt edits corrupt the ramdisk
# in a FIT image...
setenv fdt_high

# Load FIT image from location as detected by distroboot
load ${devtype} ${devnum}:${distro_bootpart} ${ramdisk_addr_r} ${prefix}tezi.itb

# Load user specified overlays from eMMC partition (file overlays.txt)

test -n ${m4boot} || env set m4boot ';'
test -n ${fdtfile} || env set fdtfile ${fdt_file}
test -n ${boot_part} || env set boot_part ${distro_bootpart}
test -n ${root_part} || env set root_part 2
test -n ${boot_devnum} || env set boot_devnum ${devnum}
test -n ${root_devnum} || env set root_devnum ${devnum}
test -n ${kernel_image} || env set kernel_image Image.gz
test -n ${boot_devtype} || env set boot_devtype ${devtype}
test -n ${overlays_file} || env set overlays_file "overlays.txt"
test -n ${overlays_prefix} || env set overlays_prefix "overlays/"

test ${boot_devtype} = "mmc" && env set load_cmd 'load ${boot_devtype} ${boot_devnum}:${boot_part}'
test ${boot_devtype} = "usb" && env set load_cmd 'load ${boot_devtype} ${boot_devnum}:${boot_part}'
test ${boot_devtype} = "tftp" && env set load_cmd 'tftp'
test ${boot_devtype} = "dhcp" && env set load_cmd 'dhcp'

env set fdt_high
env set fdt_resize true
env set fitconf_fdt_overlays

env set set_default_overlays 'env set fdt_overlays "apalis-imx6_parallel-rgb_overlay.dtbo display-edt7_overlay.dtbo apalis-imx6_stmpe-ts_overlay.dtbo apalis-imx6_hdmi_overlay.dtbo apalis-imx6_vga_overlay.dtbo"'

# We have devtype, devnum and boot_part defined for boot from USB and eMMC
env set set_load_overlays_file 'env set load_overlays_file "${load_cmd} \\${loadaddr} \\${overlays_file} && env import -t \\${loadaddr} \\${filesize}; test -n \\${fdt_overlays} || run set_default_overlays"'

env set set_apply_overlays 'env set apply_overlays "for overlay_file in \"\\${fdt_overlays}\"; do env set fitconf_fdt_overlays \"\\"\\${fitconf_fdt_overlays}#conf-\\${overlay_file}\\"\"; env set overlay_file; done; true"'

env set bootcmd_run 'echo "Bootargs: \${bootargs}" && bootm ${ramdisk_addr_r}#conf-${fdtfile}\${fitconf_fdt_overlays}'

run set_load_overlays_file
run set_apply_overlays

run load_overlays_file
run apply_overlays

run bootcmd_run

Here is the boot log when I boot from this same USB on an Ixora board:

Booting from USB on Ixora carrier board
Apalis iMX6 # run bootcmd_usb0
starting USB...
Bus usb@2184000: USB EHCI 1.00
Bus usb@2184200: USB EHCI 1.00
scanning bus usb@2184000 for devices... 1 USB Device(s) found
scanning bus usb@2184200 for devices... 3 USB Device(s) found
       scanning usb for storage devices... 1 Storage Device(s) found

Device 0: Vendor: Verbatim Rev: 2.00 Prod: STORE N GO
            Type: Removable Hard Disk
            Capacity: 3730.0 MB = 3.6 GB (7639040 x 512)
... is now current device
Scanning usb 0:1...
Found U-Boot script /boot.scr
2478 bytes read in 4 ms (604.5 KiB/s)
## Executing script at 17000000
33009184 bytes read in 1457 ms (21.6 MiB/s)
170 bytes read in 4 ms (41 KiB/s)
Bootargs: console=ttymxc0,115200 quiet video=DPI-1:640x480D video=HDMI-A-1:640x480-16@60D video=LVDS-1:d video=VGA-1:640x480-16@60D rootfstype=squashfs root=/dev/ram autoinstall
## Loading kernel from FIT Image at 12200000 ...
   Using 'conf-imx6q-apalis-eval.dtb' configuration
   Trying 'kernel-1' kernel subimage
     Description:  Linux kernel
     Type:         Kernel Image
     Compression:  uncompressed
     Data Start:   0x12200108
     Data Size:    6992384 Bytes = 6.7 MiB
     Architecture: ARM
     OS:           Linux
     Load Address: 0x11000000
     Entry Point:  0x11000000
     Hash algo:    sha256
     Hash value:   9d22e40e9d27061b48bf426179f2dd088bbe09c3333095f1a4bec42775596fa9
   Verifying Hash Integrity ... sha256+ OK
## Loading ramdisk from FIT Image at 12200000 ...
   Using 'conf-imx6q-apalis-eval.dtb' configuration
   Trying 'ramdisk-1' ramdisk subimage
     Description:  tezi-initramfs
     Type:         RAMDisk Image
     Compression:  uncompressed
     Data Start:   0x128d10f8
     Data Size:    25858048 Bytes = 24.7 MiB
     Architecture: ARM
     OS:           Linux
     Load Address: unavailable
     Entry Point:  unavailable
     Hash algo:    sha256
     Hash value:   d0902b0b67bf331d14de686de48eb2f2b1c796b6df59cbb30a6ba5445a173b45
   Verifying Hash Integrity ... sha256+ OK
## Loading fdt from FIT Image at 12200000 ...
   Using 'conf-imx6q-apalis-eval.dtb' configuration
   Trying 'fdt-imx6q-apalis-eval.dtb' fdt subimage
     Description:  Flattened Device Tree blob
     Type:         Flat Device Tree
     Compression:  uncompressed
     Data Start:   0x128ab41c
     Data Size:    69656 Bytes = 68 KiB
     Architecture: ARM
     Load Address: 0x14200000
     Hash algo:    sha256
     Hash value:   29b4b7d14b8bb30685420b15beeac58d835af17b04e6b1bc7946036e78a16395
   Verifying Hash Integrity ... sha256+ OK
   Loading fdt from 0x128ab41c to 0x14200000
## Loading fdt from FIT Image at 12200000 ...
   Using 'conf-apalis-imx6_parallel-rgb_overlay.dtbo' configuration
   Trying 'fdt-apalis-imx6_parallel-rgb_overlay.dtbo' fdt subimage
     Description:  Flattened Device Tree blob
     Type:         Flat Device Tree
     Compression:  uncompressed
     Data Start:   0x128ce93c
     Data Size:    766 Bytes = 766 Bytes
     Architecture: ARM
     Load Address: 0x142f0000
     Hash algo:    sha256
     Hash value:   15cfbe734e3f90939db1fe62822ea0b91606676e8d69b36c4b1f99a2a71ead1a
   Verifying Hash Integrity ... sha256+ OK
   Loading fdt from 0x128ce93c to 0x142f0000
## Loading fdt from FIT Image at 12200000 ...
   Using 'conf-display-edt7_overlay.dtbo' configuration
   Trying 'fdt-display-edt7_overlay.dtbo' fdt subimage
     Description:  Flattened Device Tree blob
     Type:         Flat Device Tree
     Compression:  uncompressed
     Data Start:   0x128cfbf0
     Data Size:    807 Bytes = 807 Bytes
     Architecture: ARM
     Load Address: 0x142f0000
     Hash algo:    sha256
     Hash value:   5ff422accba583cc4b498ad4eb907672dfa881cff52636ae27bb56c01226811a
   Verifying Hash Integrity ... sha256+ OK
   Loading fdt from 0x128cfbf0 to 0x142f0000
## Loading fdt from FIT Image at 12200000 ...
   Using 'conf-apalis-imx6_stmpe-ts_overlay.dtbo' configuration
   Trying 'fdt-apalis-imx6_stmpe-ts_overlay.dtbo' fdt subimage
     Description:  Flattened Device Tree blob
     Type:         Flat Device Tree
     Compression:  uncompressed
     Data Start:   0x128ced38
     Data Size:    402 Bytes = 402 Bytes
     Architecture: ARM
     Load Address: 0x142f0000
     Hash algo:    sha256
     Hash value:   4382849143654495fa7dbcd046ab5ee38f1b1e68abe5faf8306f040ec84fb02c
   Verifying Hash Integrity ... sha256+ OK
   Loading fdt from 0x128ced38 to 0x142f0000
## Loading fdt from FIT Image at 12200000 ...
   Using 'conf-apalis-imx6_hdmi_overlay.dtbo' configuration
   Trying 'fdt-apalis-imx6_hdmi_overlay.dtbo' fdt subimage
     Description:  Flattened Device Tree blob
     Type:         Flat Device Tree
     Compression:  uncompressed
     Data Start:   0x128cda88
     Data Size:    398 Bytes = 398 Bytes
     Architecture: ARM
     Load Address: 0x142f0000
     Hash algo:    sha256
     Hash value:   67d8bb4a75294db7f272025cd788b813b834d9ace677437d2162b6e386f79b2d
   Verifying Hash Integrity ... sha256+ OK
   Loading fdt from 0x128cda88 to 0x142f0000
## Loading fdt from FIT Image at 12200000 ...
   Using 'conf-apalis-imx6_vga_overlay.dtbo' configuration
   Trying 'fdt-apalis-imx6_vga_overlay.dtbo' fdt subimage
     Description:  Flattened Device Tree blob
     Type:         Flat Device Tree
     Compression:  uncompressed
     Data Start:   0x128cefc4
     Data Size:    651 Bytes = 651 Bytes
     Architecture: ARM
     Load Address: 0x142f0000
     Hash algo:    sha256
     Hash value:   d56914090a7e8c10cfa4fc829d0fe35992fd9282e142db960370c8cbd4dd203a
   Verifying Hash Integrity ... sha256+ OK
   Loading fdt from 0x128cefc4 to 0x142f0000
   Booting using the fdt blob at 0x14200000
   Loading Kernel Image
   Loading Ramdisk to 2e757000, end 30000000 ... OK
   Loading Device Tree to 2e742000, end 2e75609f ... OK

Starting kernel ...

[    0.048842] debugfs: Directory 'dummy-iomuxc-gpr@20e0000' with parent 'regmap' already present!
[    0.902702] usb usb1-port1: over-current condition
Running /etc/rc.local...
Toradex Easy Installer 5.7.2+build.14 ()
Starting udev
[    2.961067] sd 1:0:0:0: [sda] No Caching mode page found
[    2.966500] sd 1:0:0:0: [sda] Assuming drive cache: write through
System time was Fri May  5 17:44:14 UTC 2023.
Setting the System Clock using the Hardware Clock as reference...
System Clock set. System local time is now Fri May  5 17:44:15 UTC 2023.

Welcome to the Toradex Easy Installer

This is a Linux based installer for Toradex modules. Currently, the installer
does not have a serial console interface. You can use the Toradex Easy Installer
via any of the available display interfaces using USB mouse/keyboard or via a
network connection using VNC. Use:
  # ip addr show
to display the Ethernet IP address(es) or use USB RNDIS at IP 192.168.11.1.

Check our documentation at:
  https://developer.toradex.com/software/toradex-easy-installer
/ #

Thanks,
Anthony

VS

Apparently dtb file was not loaded in a second case. Check where it stored and if U_Boot environment variables set accordingly.

Hi,

Looks like our older image’s UBoot is an old version (U-Boot 2016.11-2.8.3).

I’m not 100% sure how it relates to Toradex Easy Installer, but I downgraded from version 5.7.2 to TEZI version 1.8 and I was able to boot it on our custom carrier board. Probably some pathing that changed between versions?

Booting TEZI 5.7.2 from U-Boot 2020.07-0 works as intended though.

Thanks,
Anthony