Loading custom u-boot for TK1

I built a custom bootloader for my Apalis TK1 running Apalis-TK1_LXDE-Image_2.8.2. How do I convert my u-boot-dtb-tegra.bin file to the proper format and then load it onto my board?

I know that for the TK1, I’m supposed to use cbootimage to convert it to an apalis-tk1.img file and I thought I was doing this correctly by just copying my u-boot-dtb-tegra.bin to a legacy BSP package and running update.sh. However, my bootloader is not upgrading properly.

Can you point me to the proper instructions to upgrade to my new u-boot-dtb-tegra.bin?

Thanks.

https://developer.toradex.com/knowledge-base/build-u-boot-and-linux-kernel-from-source-code#Update

The note on that link says:
“Note: For Apalis TK1 first manually convert u-boot-dtb-tegra.bin to apalis-tk1.img using cbootimage from the legacy BSP package and its update.sh script”

This manual conversion of u-boot-dtb-tegra.bin is what I believe I am not doing correctly. How do I carry out the manual conversion using cbootimage?

Just copy it on-top of an extracted legacy update package and run ./update.sh -o whatever again e.g.:

[user@host ~]$ sudo tar xf ~/Downloads/Apalis-TK1_LXDE-Image_2.8b2.97-20180331.tar.bz2
[user@host ~]$ cd Apalis-TK1_LXDE-Image_2.8.2/
[user@host Apalis-TK1_LXDE-Image_2.8.2]$ sudo cp ~/u-boot-toradex/u-boot-dtb-tegra.bin apalis-tk1_bin/
[user@host Apalis-TK1_LXDE-Image_2.8.2]$ ./update.sh -o /var/lib/tftpboot/

And then just do the update e.g.:

U-Boot 2016.11-2.8.3+gaca804c9dd (Jun 21 2018 - 06:12:02 +0000)

SoC: tegra124
Reset cause: SW_MAIN
DRAM:  2 GiB 
MMC:   Tegra SD/MMC: 0, Tegra SD/MMC: 1, Tegra SD/MMC: 2
In:    serial
Out:   serial
Err:   serial
Model: Toradex Apalis TK1 2GB V1.2A, Serial# 02997331
Net:   No ethernet found.
Hit any key to stop autoboot:  0
Apalis TK1 # run setupdate; run update_uboot
MMC: no card present
** Bad device mmc 1 **
MMC: no card present
** Bad device mmc 2 **
starting USB...
USB0:   USB EHCI 1.10
USB1:   USB EHCI 1.10
USB2:   USB EHCI 1.10
scanning bus 0 for devices... 1 USB Device(s) found
scanning bus 1 for devices... 1 USB Device(s) found
scanning bus 2 for devices... 1 USB Device(s) found
** Bad device usb 0 **
e1000: no NVM
Using e1000#0 device
TFTP from server 192.168.10.1; our IP address is 192.168.10.2
Filename 'flash_eth.img'.
Load address: 0x81000000
Loading: ##################################################  444 Bytes
         0 Bytes/s
done
Bytes transferred = 444 (1bc hex)
## Executing script at 81000000
Using e1000#0 device
TFTP from server 192.168.10.1; our IP address is 192.168.10.2
Filename 'apalis-tk1/flash_eth.img'.
Load address: 0x81000000
Loading: ##################################################  2.3 KiB
         0 Bytes/s
done
Bytes transferred = 2377 (949 hex)
## Executing script at 81000000
enter "run update" to update the entire module
Using e1000#0 device
TFTP from server 192.168.10.1; our IP address is 192.168.10.2
Filename 'apalis-tk1/apalis-tk1.img'.
Load address: 0x82000000
Loading: ##################################################  606.5 KiB
         120.1 KiB/s
done
Bytes transferred = 621056 (97a00 hex)
switch to partitions #1, OK
mmc0(part 1) is current device

MMC write: dev # 0, block # 0, count 1213 ... 1213 blocks written: OK
Apalis TK1 # reset
resetting ...


U-Boot 2018.07-rc2-00013-gdc7df68f21 (Jun 22 2018 - 15:12:31 +0200)

TEGRA124
DRAM:  2 GiB
MMC:   sdhci@700b0000: 1, sdhci@700b0400: 2, sdhci@700b0600: 0
Loading Environment from MMC... OK
In:    serial
Out:   serial
Err:   serial
Model: Toradex Apalis TK1 2GB V1.2A, Serial# 02997331
Net:   No ethernet found.
Hit any key to stop autoboot:  0 
Apalis TK1 #

Thank you. I see what I was doing wrong. It was actually in where I expected to get execution in my bootloader modifications rather than the actual upgrading to my new bootloader.

Thanks for confirming the proper way to update to my built u-boot.

You are very welcome.