Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • printenv <var> - print the value of the variable <var>. Without arguments, prints all environment variables:

    Code Block
    STM32H7-SOM U-Boot> printenv
    addclk=setenv bootargs ${bootargs} clk_ignore_unused
    addip=setenv bootargs ${bootargs} ip=${ipaddr}:${serverip}:${gatewayip}:
    ${netmask}:${hostname}:eth0:off
    altbootcmd=run reliable_altboot
    baudrate=115200
    boot1_valid=1
    boot2_active=0
    ...
    upgrade_available=0
    
    Environment size: 3961/16379 bytes
    STM32H7-SOM U-Boot>
  • setenv <var> <val> - set the variable <var> to the value <val>:

    Code Block
    STM32H7-SOM U-Boot> setenv image my.rootfs.uImage
    STM32H7-SOM U-Boot>
  • saveenv - save the up-to-date U-Boot environment, possibly updated using setenv commands, into the QSPI Flash. Running saveenv makes sure that any updates you have made to the U-Boot environment are persistent across power cycles and resets.

    Code Block
    STM32H7-SOM U-Boot> saveenv
    Saving Environment to UBI... ubi0: detaching mtd2
    ...
    Writing to UBI... done
    OK
    STM32H7-SOM U-Boot>