Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 16 Current »

1. Overview

This page describes how to deploy the TorizonOS target images to the STM32MP2-EV1 development board.

The procedure documented below will install the U-Boot firmware, Linux kernel and filesystem images to the bootable eMMC disk on the STM32MP2 targer. Having completed the installation, the STM32MP2 will boot to Linux from the eMMC on next reset / power on.

Note that the procedure will erase all data previously that might be present on the eMMC disk.

2. Installing TorizonOS

Perform the following steps:

  1. Follow the instructions in the https://voxelbotics.atlassian.net/wiki/spaces/DOC/pages/546275360/Setting+up+the+STM32MP257F-EV1+Evaluation+Board#Installing-the-STM32CubeProgrammer-tool to install the STM32CubeProgrammer Tool to your Linux host.

  2. Add STM32_Programmer_CLI to your PATH:

    $ export PATH=$PATH:/bin:
    $ STM32_Programmer_CLI
          -------------------------------------------------------------------
                            STM32CubeProgrammer v2.14.0                  
          -------------------------------------------------------------------
    
    
    Usage :
    STM32_Programmer_CLI.exe [command_1] [Arguments_1][[command_2][Arguments_2]...]
    
    ...
  3. Power off the target board. S

  4. Select the USB Serial Downloader mode (see in https://voxelbotics.atlassian.net/wiki/spaces/DOC/pages/561709057/Selecting+STM32MP2+EV1+Boot+Device?atl_f=content-tree ).

  5. Attach an USB Type-C cable between the connector CN21 of the STM32MP2 EV1 and the Linux host.

  6. Attaching another USB-C cable between the connector CN15 of the STM32MP2 EV1 and the Linux host.

  7. Power the board on.

  8. Check that the programming USB port has appeared on the host (note the Device Index in the output):

    $ STM32_Programmer_CLI -l                                                                                                                                                                                                                                           
          -------------------------------------------------------------------                                                                                                                                                                                                          
                            STM32CubeProgrammer v2.14.0                                                                                                                                                                                                                                
          -------------------------------------------------------------------                                                                                                                                                                                                          
    
    =====  DFU Interface   =====
    
    Total number of available STM32 device in DFU mode: 1
    
      Device Index           : USB1
      USB Bus Number         : 002
      USB Address Number     : 007
      Product ID             : DFU in HS Mode @Device ID /0x505, @Revision ID /0x2000
      Serial number          : 002A00194136500B00363653
      Firmware version       : 0x0110
      Device ID              : 0x0505
    
  9. Download the Emcraft release images from the Emcraft site and unpack them into an arbitrary directory on the Linux host. (If you are installing the images built by Yocto, navigate to the builddir/deploy/images/stm32mp25-eval directory):

    $ tar -xf torizon_6.9.0-core-docker-stm32mp25-eval.tar.bz2
    $ cd torizon_6.9.0-core-docker-stm32mp25-eval/
    $ ls -nh
    total 1.5G
    drwxr-xr-x 7 1016 1016 4.0K Dec 25 00:51 arm-trusted-firmware
    drwxr-xr-x 2 1016 1016 4.0K Dec 25 00:51 fip
    drwxr-xr-x 5 1016 1016 4.0K Dec 25 00:51 flashlayout_torizon-core-docker
    -rw-r--r-- 1 1016 1016 1.5G Dec 25 00:52 torizon-core-docker-stm32mp25-eval.ota-ext4
  10. Use the eMMC card Flash Layout file for programming the images to SD card:

    $ STM32_Programmer_CLI -c port=usb1 -w flashlayout_torizon-core-docker/optee/FlashLayout_emmc_stm32mp257f-ev1-optee.tsv
          -------------------------------------------------------------------
                            STM32CubeProgrammer v2.14.0                                   
          -------------------------------------------------------------------
                        
                                                       
                          
    USB speed   : High Speed (480MBit/s)                                 
    Manuf. ID   : STMicroelectronics                             
    Product ID  : DFU in HS Mode @Device ID /0x505, @Revision ID /0x2000
    SN          : 002A00194136500B00363653                 
    DFU protocol: 1.1          
    Board       : --      
    Device ID   : 0x0505                                      
    Device name : STM32MP25xx                                   
    Device type : MPU                                         
    Revision ID : --                                    
    Device CPU  : Cortex-A7
                                                        
    Start Embedded Flashing service
                                                              
                                           
                                                                     
    Memory Programming ...
    Opening and parsing file: tf-a-stm32mp257f-ev1-usb.stm32
      File          : tf-a-stm32mp257f-ev1-usb.stm32
      Size          : 198.86 KB 
      Partition ID  : 0x01 
    
    Download in Progress:
    [==================================================] 100% 
    
    File download complete
    Time elapsed during download operation: 00:00:02.184
    
    RUNNING Program ...
      PartID:      :0x01
    
    Reconnecting the device ...
    
    USB speed   : High Speed (480MBit/s)
    Manuf. ID   : STMicroelectronics
    Product ID  : DFU @Device ID /0x505, @Revision ID /0x0011, @Name /STM32MP257FAI Rev.Y,
    SN          : 002A00194136500B00363653
    DFU protocol: 1.1
    Board       : --
    Device ID   : 0x0505
    Device name : STM32MP257FAI Rev.Y
    Device type : MPU
    Device CPU  : Cortex-A7
    Start operation done successfully at partition 0x01
    
    
    Memory Programming ...
    Opening and parsing file: fip-stm32mp257f-ev1-ddr-optee-emmc.bin
      File          : fip-stm32mp257f-ev1-ddr-optee-emmc.bin
      Size          : 29.38 KB
      Partition ID  : 0x02
    
    Download in Progress:
    [==================================================] 100% 
    
    File download complete
    Time elapsed during download operation: 00:00:00.024
    
    RUNNING Program ...
      PartID:      :0x02
    
    Reconnecting the device ...
    
    USB speed   : High Speed (480MBit/s)
    Manuf. ID   : STMicroelectronics
    Product ID  : DFU @Device ID /0x505, @Revision ID /0x0011, @Name /STM32MP257FAI Rev.Y,
    SN          : 002A00194136500B00363653
    DFU protocol: 1.1
    Board       : --
    Device ID   : 0x0505
    Device name : STM32MP257FAI Rev.Y
    Device type : MPU
    Device CPU  : Cortex-A7
    Start operation done successfully at partition 0x02
    
    
    Memory Programming ...
    Opening and parsing file: fip-stm32mp257f-ev1-optee-emmc.bin
      File          : fip-stm32mp257f-ev1-optee-emmc.bin
      Size          : 2.65 MB
      Partition ID  : 0x03
    
    Download in Progress:
    [==================================================] 100% 
    
    File download complete
    Time elapsed during download operation: 00:00:01.990
    
    RUNNING Program ...
      PartID:      :0x03
    
    Reconnecting the device ...
    
    USB speed   : High Speed (480MBit/s)
    Manuf. ID   : STMicroelectronics
    Product ID  : USB download gadget@Device ID /0x505, @Revision ID /0x0011, @Name /STM32MP257FAI Rev.Y,
    SN          : 002A00194136500B00363653
    DFU protocol: 1.1
    Board       : --
    Device ID   : 0x0505
    Device name : STM32MP257FAI Rev.Y
    Device type : MPU
    Device CPU  : Cortex-A7
    Start operation done successfully at partition 0x03
    
    Flashlayout Programming ...
    [==================================================] 100% 
    Running Flashlayout Partition ...
    
    Reconnecting the device ...
    
    USB speed   : High Speed (480MBit/s)
    Manuf. ID   : STMicroelectronics
    Product ID  : USB download gadget@Device ID /0x505, @Revision ID /0x0011, @Name /STM32MP257FAI Rev.Y,
    SN          : 002A00194136500B00363653
    DFU protocol: 1.1
    Board       : --
    Device ID   : 0x0505
    Device name : STM32MP257FAI Rev.Y
    Device type : MPU
    Device CPU  : Cortex-A7
    Flashlayout partition started successfully
    
    
    Memory Programming ...
    Opening and parsing file: tf-a-stm32mp257f-ev1-optee-emmc.stm32
      File          : tf-a-stm32mp257f-ev1-optee-emmc.stm32
      Size          : 202.91 KB
      Partition ID  : 0x04
    
    Download in Progress:
    [==================================================] 100% 
    
    File download complete
    Time elapsed during download operation: 00:00:00.055
    
    RUNNING Program ...
      PartID:      :0x04
    Start operation done successfully at partition 0x04
    
    
    Memory Programming ...
    Opening and parsing file: tf-a-stm32mp257f-ev1-optee-emmc.stm32
      File          : tf-a-stm32mp257f-ev1-optee-emmc.stm32
      Size          : 202.91 KB
      Partition ID  : 0x05
    
    Download in Progress:
    [==================================================] 100% 
    
    File download complete
    Time elapsed during download operation: 00:00:00.056
    
    RUNNING Program ...
      PartID:      :0x05
    Start operation done successfully at partition 0x05
    
    
    Memory Programming ...
    Opening and parsing file: metadata.bin
      File          : metadata.bin
      Size          : 120.00 B
      Partition ID  : 0x06
    
    Download in Progress:
    [==================================================] 100% 
    
    File download complete
    Time elapsed during download operation: 00:00:00.006
    
    RUNNING Program ...
      PartID:      :0x06
    Start operation done successfully at partition 0x06
    
    
    Memory Programming ...
    Opening and parsing file: metadata.bin
      File          : metadata.bin
      Size          : 120.00 B
      Partition ID  : 0x07
    
    Download in Progress:
    [==================================================] 100% 
    
    File download complete
    Time elapsed during download operation: 00:00:00.006
    
    RUNNING Program ...
      PartID:      :0x07
    Start operation done successfully at partition 0x07
    
    
    Memory Programming ...
    Opening and parsing file: fip-stm32mp257f-ev1-optee-emmc.bin
      File          : fip-stm32mp257f-ev1-optee-emmc.bin
      Size          : 2.65 MB
      Partition ID  : 0x08
    
    Download in Progress:
    [==================================================] 100% 
    
    File download complete
    Time elapsed during download operation: 00:00:00.613
    
    RUNNING Program ...
      PartID:      :0x08
    Start operation done successfully at partition 0x08
    
    
    Memory Programming ...
    Opening and parsing file: torizon-core-docker-stm32mp25-eval.ota-ext4
      File          : torizon-core-docker-stm32mp25-eval.ota-ext4
      Size          : 1.44 GB
      Partition ID  : 0x10
    
    Download in Progress:
    [==================================================] 100% 
    
    File download complete
    Time elapsed during download operation: 00:07:31.984
    
    RUNNING Program ...
      PartID:      :0x10
    Start operation done successfully at partition 0x10
    Flashing service completed successfully
  11. Disconnect the cable connected to the CN21.

  12. Set the boot mode for booting from eMMC. (Refer to https://voxelbotics.atlassian.net/wiki/spaces/DOC/pages/561709057/Selecting+STM32MP2+EV1+Boot+Device?atl_f=content-tree .)

  13. Connect the USB-C cable to the connector CN21, this will power the board on.

  14. From the serial console terminal, monitor the target boot sequence:

    NOTICE:  CPU: STM32MP257FAI Rev.Y
    NOTICE:  Model: STMicroelectronics STM32MP257F-EV1 Evaluation Board
    NOTICE:  Board: MB1936 Var1.0 Rev.D-01
    INFO:    Reset reason (0x2034):
    INFO:      Pad Reset from NRST
    INFO:    PMIC2 version = 0x11
    INFO:    PMIC2 product ID = 0x20
    INFO:    FCONF: Reading TB_FW firmware configuration file from: 0xe011000
    INFO:    FCONF: Reading firmware configuration information for: stm32mp_io
    INFO:    FCONF: Reading firmware configuration information for: stm32mp_fuse
    INFO:    Using EMMC
    INFO:      Instance 2
    
    ...

  • No labels