See Vitis™ Development Environment on xilinx.com |
Version: Vitis 2024.1
This is a new feature with the Vitis Unified Embedded IDE, where users can add a makefile and argument that can be used to create custom builds. This allows the user more control over their project builds instead of letting the tools generate the components.
The biggest advantages of user managed mode are being able to do the following:
- Quickly rebuild a Vitis Unified Workspace in the GUI.
- Quickly call makefile actions.
This tutorial describes three use cases for the User Managed Mode.
Launch Vitis 2024.1, select open_workspace, and navigate to the Vitis-Tutorials/Embedded_Software/Feature_Tutorials/01-user_managed_mode
directory
Select the Open Explorer View
In this use case, we shall be using the Python script introduced in the 04-vitis_scripting_flows to build a workspace and with a simple Hello World application template. However, users can also utilize the Python script logs/builder.py
that gets generated for every Vitis Unified IDE workspace.
Right click in the Explorer view, right-click and select Edit Build Configurations and New Build Configuration and set similar as shown below.
To launch the build configuration, right click on the Explorer view, and then select Build.
Note: If there is only a single build configuration, then this will launch automatically. If there is more than one build configuration, a list is shown that you can choose from.
This will generate the Vitis Unified IDE workspace based on the XSA.
Next, we can create a Launch Configuration to test the application created above on our hardware target.
Right click in the Explorer view, and select Edit Launch Configurations and New Launch Configurations and select Baremetal and browse to your XSA file used to create the workspace above.
Here, we can add the FSBL (as this is for a Zynq UltraScale Device)
Users can select on the + icon and add the ELF as shown below
Once the launch configuration is complete, users can select the debug icon to deploy and debug the hello world application
The Debug view will be launched, and users can debug as normal
In this use case, we can build the example given here here. In particular, we will build the Edge-AI-ZCU104 Platform.
Launch Vitis 2024.1, select open_workspace, and navigate to the Vitis-Tutorials/Embedded_Software/Feature_Tutorials/01-user_managed_mode
directory
Select the Open Explorer View
In this use case, copy the Makefile, export_xsa.tcl and the system_step1.tcl from The Git repository above into the workspace.
Right click in the Explorer view, and select Edit Build Configurations and New Build Configurations and set as shown below:
To launch the build configuration, right click on the Explorer view and select Build.
Note: If there is only a single build configuration, then this will launch automatically. If there are more than one build configurations, then the user will be presented with a list to choose from.
This will generate the XSA into the Build folder.
Users can target these newly generated XSA filed in Vitis Unified IDE. Users can switch views View → Vitis Components, and target the platform for their development.
In this demo I have a simple makefile to generate and deploy u-boot using the metadata extracted from the XSA file. The script will do the following
- Download Git sources
- Generate the Platform (with FSBL)
- Generate the device tree files
- Compile device-tree
- Compile ARM Trusted Firmware
- Compile U-boot
- Generate JTAG boot script
Each section above can be built independently. For example, if users want to make a change to the device-tree, then only the DT needs to be compiled and re-deployed on the board. This allows the users to speed up any u-boot debug or testing.
Launch Vitis 2024.1, select open_workspace, and navigate to the Vitis-Tutorials/Embedded_Software/Feature_Tutorials/01-user_managed_mode
directory
Select the Open Explorer View
If users want to create a Build Configuration, then right click in Explorer view -> Edit Build Configurations, and select the + icon. Users will be presented with an empty Build Configuration. For example, if we wanted to created a build configuration to run the boot script in XSCT
jtag_boot:
vitis -s ./boot_script.py
Create the build configuration as follows
To run a build configuration, right click in Explorer View and select Build and select your build configuration from the list
Similarly, to run a clean configuration, right click in Explorer View and select Clean and select your Clean configuration from the list
If users are using Git to maintain their work, then users may want to maintain or share the build configurations. This metadata is stored in the _ide/.theia/build.json file
The examples above should act as an introduction to how to utilize the User Managed Mode for different design flows. However, whether the users preference is to use the GUI or Command Line to build and maintain their Embedded System, they can still avail of all the debug features within Vitis Unified IDE with ease.
Copyright © 2020–2024 Advanced Micro Devices, Inc