Table of Contents | ||
---|---|---|
|
TBD Installing U-Boot to the STM32H7 SOM (uClinux) explains how to install the U-Boot firmware to the board for the first time. Having installed U-Boot, U-Boot is immediately available on the STM32H7 SOM as a primary firmware monitor.
...
The full U-Boot source for the Emcraft STM32H7 SOM board is included in the software distribution available from the Emcraft web site. Refer to the u-boot/
sub-directory in the software distribution tree.
...
On the Linux development host, activate the cross-build environment as described in TBD Installing and activating cross development environmentActivating Cross Development Environment (uClinux) :
Code Block $ . ./ACTIVATE.sh
Change to the U-Boot top directory:
Code Block $ cd u-boot
Configure U-Boot for the Emcraft STM32H7 SOM board:
Code Block $ make distclean $ make stm32h7_som_nor_defconfig
Run make to create the
u-boot.img
binary:Code Block $ make -s
...
Copy the U-Boot image to the TFTP server, adjust the
uboot_image
environment variable, if needed:Code Block STM32H7-SOM U-Boot > printenv uboot_image uboot_image=stm32h7/u-boot.img STM32H7-SOM U-Boot >
Download the U-Boot image from the TFTP server and install it to the QSPI Flash:
Code Block STM32H7-SOM U-Boot > run uboot_upgrade ethernet@40028000 Waiting for PHY auto negotiation to complete. done Using ethernet@40028000 device TFTP from server 192.168.0.3; our IP address is 192.168.0.166 Filename 'stm32h7/u-boot.img'. Load address: 0xd0c00000 Loading: ################################################################# ################################ 3.3 MiB/s done Bytes transferred = 495105 (78e01 hex) Erasing 0x00000000 ... 0x000fffff (256 eraseblock(s)) Writing 495105 byte(s) at offset 0x00000000 STM32H7-SOM U-Boot >
Verify that the new U-Boot has been successfully installed. Reset the SOM by pressing the S3 button on the carrier board and confirm that the U-Boot has been upgraded:
Code Block U-Boot SPL 2019.04- (May 03 2024 - 06:09:05 +0000) Hit 's' key to enter spl shell: Trying to boot from SPI U-Boot 2019.04- (May 03 2024 - 06:09:05 +0000) ...
Note that the self-upgrade sequence is a dangerous operation. You must be sure that you load and install a functional U-Boot image, which is always a tricky thing when you develop customizations to U-Boot. If something goes wrong, you can re-install the release U-Boot image as documented in Installing U-Boot to the STM32H7 SOM (uClinux) .