Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Table of Contents
stylenone

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.

...

  1. 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
  2. Change to the U-Boot top directory:

    Code Block
    $ cd u-boot
  3. Configure U-Boot for the Emcraft STM32H7 SOM board:

    Code Block
    $ make distclean
    $ make stm32h7_som_nor_defconfig
  4. Run make to create the u-boot.img binary:

    Code Block
    $ make -s

...

  1. 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 >
  2. 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 >
  3. 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) .