This is simple example to demonstrate Vitis Bare-Metal Emulation flow on Versal platform to validate platform and does not any user PL kernels.
KEY CONCEPTS: Building the Bare-Metal System
EXCLUDED PLATFORMS:
- Samsung SmartSSD Computation Storage Drive
- Samsung U.2 SmartSSD
- All Embedded Zynq Platforms, i.e zc702, zcu102 etc
- All NoDMA Platforms, i.e u50 nodma etc
Application code is located in the src directory.
src/main.cpp
The baremetal flow is used for emulation platform level basic testing i.e. to test different applications - DDR testing, LPDDR testing, AIE testing. This example is to demonstrate simple platform validation.
In this example, by default extensible hw_emu XSA $PLATFORM_REPO_PATHS/xilinx_vck190_base_202220_1/hw_emu/hw_emu.xsa
is directly used at v++ link to generate the fixed XSA. Users can have their own extensible XSA and provide it at v++ link.
The user needs to generate the fixed XSA from v++ link using extensible XSA.
- Build the fixed xsa using v++ link step as per extensible XSA:
make fixed_xsa EXTENSIBLE_XSA=$PLATFORM_REPO_PATHS/xilinx_vck190_base_202220_1/hw_emu/hw_emu.xsa
- Build the BSP sources and libraries required for compilation of user application.
Compile and link the user application to generate main.elf :
make baremetal_elf
- Note: Users can modify sw/main.cpp file and incrementally compile it to build the main.elf as per your user application.
- Generate the package directory using v++ package step as per fixed platform:
make package
- Note: The fixed XPFM generated out of fixed XSA can be found inside
./workspace_fixed/$(APP_NAME)/export/$(APP_NAME)/$(APP_NAME).xpfm
- Run the user application:
./package.hw_emu/launch_hw_emu.sh
- To run all the steps at once, use
make run TARGET=hw_emu EXTENSIBLE_XSA=$PLATFORM_REPO_PATHS/xilinx_vck190_base_202220_1/hw_emu/hw_emu.xsa
For more comprehensive documentation, click here.