For this particular example design, partial bitstreams are placed into PS-DDR
memory and loaded into the device using a baremetal application, running on the
Cortex-A53. This application takes inputs
from the user through a UART to select the RM to
load. The application uses the xilfpga library to load the partial bitstreams
through the PCAP. More information on the xilfpga library can be found in the
Zynq
UltraScale+ MPSoC: Software Developers Guide (UG1137).
Perform the following steps to create the software application.
- In Vivado, select .
- Click Next in the Export hardware platform window.
- Leave the output set to Pre-synthesis on the output window, and click Next.
- Change the XSA file name to
topand the Export to as a location of the project directory. Click Next and then select Finish to build a design image for the Vitis integrated design environment. This creates thetop.xsafile under the project_idf_dfx_zcu102 directory. - Select . The Eclipse launcher dialog box appears in Vivado.
- Ensure the workspace maps to the current project directory (project_idf_dfx_zcu102) in the Eclipse launcher, and then click Launch to open the main Vitis integrated design environment GUI.
- Select in the Vitis IDE.
- Click Next on the welcome screen.
- Select the Create a new platform from hardware (XSA) tab, and browse to select top.xsa to import the file that was exported from Vivado.
- Keep the platform name as
top, select Generate boot components, and select psu_cortexa53_0.
- Click Next.
- Name the project
dfx_demoin the Application Project window, and select psu_cortexa53_0 as the target processor. Click Next.
- Keep default values for Domain, and click Next.
- Select Empty Application(C), and click Finish.
- Expand dfx_demo in the
Project Explorer
window. Right-click src and select
Import Sources. Browse to the
sources/dfx_demo/src directory, and
click Open. Finally, check all .c and .h sources in that folder, and click Finish.Important: If the actual bitstream file size does not match with the size of bit file in
dfx_demo.h, then loading the partial bitlstream on hardware might fail. Check the size of partial bitstream files (.bin) and update the new bitstream file size indfx_demo.h. Update the address range in bif file accordingly.
- The application uses the xilfpga library to load the partial bitstreams via
PCAP. More information on the xilfpga library can be found in the
Zynq
UltraScale+ MPSoC: Software Developers Guide (UG1137). You must enable the
xilfpga and dependent libraries in the BSP settings. Select dfx_demo.prj and click Navigate to BSP settings.
- Select Board Support Package under
standalone_psu_cortexa53_0 and then click Modify BSP Settings.
- Select xilfpga, xilsecure, and xilskey from the supported libraries list.
- Select , then select xilfpga to
open configuration for the library. Change the
secure_modevalue to false.
- Click OK.
- Open the dfx_demo_system settings and disable Generate SD card image.
- Build the
dfx_demoproject, and generatedfx_demo.elf. To build the project, select the project from the Explorer drop-down list, and click .
- Create a boot image, which loads partial bitstreams into the PS-DDR and
initializes PL with the Config1 full bitstream. Click . Select Import from existing BIF file
option, browse to the directory where you placed the application
note files, and then select and open dfx_demo.bif.Important: Check the load address of the partial bitstreams. The address range should be more than the actual bitstream file size.
- Click Create Image and then click OK to overwrite the bif file. This creates the BOOT.bin.