Versions Compared

Key

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


Info

These instructions are targeted at versions 2023.1 and later of the AMD tools and Yocto build environment.  For notes relevant to previous versions, refer to Install and Build with Xilinx Yocto

...

Install the standard Yocto dependencies for your host machine per the Yocto Reference Manual - Langdale - Required Packages for the Build Host

Alternatively, if your Linux machine does not match the host dependencies, a docker image could potentially be used as the build environment - see Building Yocto Images using a Docker Container

Repo

Repo is a repository management tool that is built on top of Git. Repo unifies the many Git repositories when necessary, and automates parts of the development workflow.

Repo is not meant to replace Git, only to make it easier to work with Git in the context of development. The repo command is an executable Python script that you can put anywhere in your path. With a single Repo command you can download files from multiple repositories into your local working directory.

Info

For more info about Repo, please see https://source.android.com/source/developing.html.

Repo is generally available from the OS Package manager, so it is preferred to install it using this method:

...

The repo tool uses git to clone and setup the local build environment.  If you get the error "stderr: Committer identity unknown" this means that you have not yet configured your local git profile.  The

You can use the following commands will acheive to achieve this:

Code Block
themeMidnight
$ git config --global user.email "you@example.com"
$ git config --global user.name "Your Name"

...

Repo uses a manifest which is an XML file that describes all the required repositories. 

It can manage all of your git repositories so that they remain in sync.  Use repo with the Xilinx yocto-manifest file for the desired release to fetch all required source files for a Yocto build:

...

Info

Replace rel-v2023.2 with the git release tag of interest, e.g. , for example, rel-v2023.1, rel-v2023.2 etc..  The tags for the yocto-manifests can be found at https://github.com/Xilinx/yocto-manifests/branches/all .  The instructions below assume that you are running the current release tag.

...

Setupsdk is a Xilinx script which configures the Xilinx Yocto environment.  Essentially it 's is a wrapper for the familiar "oe-init-build-env" Yocto script.

...

Finally bitbake the target image "petalinux-image-minimal".  You can pass the target machine on the command line or add it to your local.conf as the default machine.  When the build is completes, your images are located in "build/tmp/deploy/images/<machine>".  In this example we are building for the ZCU102 board.

Code Block
themeMidnight
$ MACHINE=zcu102-zynqmp bitbake petalinux-image-minimal

...

Info

Other available machines, e.g. for example zcu706-zynqmp, ultra96-zynqmp, or zc706-zynq7 , can be found under "sources/meta-xilinx/meta-xilinx-bsp/conf/machine"

Create and install an SD card disk image

Depending on the target machine, a wic file may might have been created for direct copy onto a raw SD card.  Check to see if there is a wic file generated:

...

Now insert an SD card into your machine, and look at the difference to determine the mount path. 

In this case, the SD card mount point is "/dev/example".  However, on your machine, this may well be the first boot partition of your OS, so it 's is critical to get the correct name.  Always double check this and don't do not assume it will always be static.  The "RM" column indicates that this is a removable device, and the SIZE column should also be double-checked to check the mount point is of the correct size.

...

In conclusion, we are convinced in this example that the mount point of this SD card is /dev/example, so we may can proceed with writing the SD card image.

...

The dd command will take some time to complete.  Once completed, the SD card may can be ejected from the Once completed, the SD card can be ejected and removed from the machine and inserted into the target board.

...

The method to boot the board will vary.  However, in general, the SD card is inserted into the board, and the mode dipswitches will be checked to ensure that the boot mode is set to SD card. 

The table below shows an extract from the user guide for common boards to specify the dip switch to set for SD boot:

...

Then, the user will ensure that a USB cable is attached to the board to connect to the appropriate UART for console output and power on the board. 

Boards can have up to 4 four UARTs connected to one USB connection for various outputs.  Check the documentation to find the correct one to view, or view all four to observe the output and any additional board diagnostics.

Once booted, the board can usually be logged into with the username "petalinux"

...