STM32MP157 Discovery Kit

FoundriesFactory CI Build

Important

Including the STM™ OpenEmbedded layer requires accepting the EULA. When building locally, it is enough to accept the EULA from an interactive prompt. When building in CI, this is not possible. To enable EULA acceptance in the CI job, the variable EULA_stm32mp15disco needs to be set in the factory-config.yml

...
lmp:
  params:
    ...
    EULA_stm32mp15disco: "1"
    ...

factory-config.yml can be found in the ci-scripts.git repo for your Factory.

Preparation

Important

Ensure you replace <factory> with the name of your Factory.

  1. Download the necessary files from https://app.foundries.io/factories/<factory>/targets:

    1. Click the latest Target with the platform trigger.
    2. Expand the run in the Runs section which corresponds with the name of the board. Download the Factory image for that machine, e.g., lmp-factory-image-<machine-name>.wic.gz or lmp-base-console-image-<machine-name>.wic.gz.

Flashing

Flash lmp-factory-image-stm32mp15-disco.wic.gz to an SD Card. This contains the bootable system image.

  1. Determine which disk to flash by finding the device with the SIZE that matches that of your flash drive. Ignore partitions (indicated by part under TYPE). Note the NAME of the flash drive (e.g., /dev/mmcblk0, /dev/sdb), as it will be used for the disk path:

    lsblk -po +MODEL
    
    $ lsblk -po +MODEL
    NAME             MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT                 MODEL
    /dev/mmcblk0     179:0    0  29.8G  0 disk
    ├─/dev/mmcblk0p1 179:1    0  41.6M  0 part /mnt/boot
    └─/dev/mmcblk0p2 179:2    0  29.8G  0 part /mnt/otaroot
    /dev/zram0       254:0    0    26G  0 disk /out
    /dev/nvme0n1     259:0    0 953.9G  0 disk                            SSDPEKKF010T8 NVMe INTEL 1024GB
    
  2. Flash the disk.

    Replace <system-image> with the path to your system image.
    Replace /dev/mmcblk<X> with your chosen disk path.
gunzip -c <system-image> | sudo dd of=/dev/mmcblk<X> bs=4M iflag=fullblock oflag=direct status=progress
  1. Remove the flash drive and connect it to the board.
  2. Power on the board to boot the new image.

Boot Mode

The STM32MP157C-DK2 has a dip switch that controls boot mode. The dip switch covers BOOT0 and BOOT2 signals. Turn both ON for the board to boot from SD card.

../../_images/stm32mp1_boot_mode.png