As many of you have heard, Vitis is Xilinx's newest unified development platform. With this new software comes the challenge and fears of learning something new. In some cases, a switch as big as Vitis might not be ideal, but in many other cases, this is a great opportunity to pick up the latest and greatest from Xilinx! I will walk you through the migration process and give you the most up to date information that I found while working on this fun project!
This has only been tested and verified in Vitis 2020.2, and the errors I will list out will be fixed in later versions of the tool.
I have tested this in both Windows 10 and Ubuntu Linux versions, and I have highlighted in the process where they may diverge.
Migration ProcessUnzip both Files provided or use your own projects!
HARDWARE CREATION IN VIVADO 2019.1 (DONE FOR YOU IN VIVADO 2019.1 PROJECT FILES)
a. In 2019.1, open and examine block design
-Simple Zynq Proc System with GPIO that controls Pushbuttons and LEDs
b. Generate output products
c. Create HDL Wrapper
d. Generate bitstream
e. Export hardware - HDF File
f. Archive Project
SOFTWARE CREATION IN SDK 2019.1 (DONE FOR YOU IN SDK 2019.1 PROJECT FILES)
a. Create an application project and point it to hdf created and exported in vivado
b. Write application code
c. Build code
d. Archive SDK project
MIGRATING TO VITIS
a. Open the vivado 2019.1 project file (ZCU104_PB_LED.xpr.zip) in 2020.2
b. Upgrade your project to 2020.2
c. Click “Report IP Status” and update any necessary IP
d. Regenerate bitstream and export hardware (now an XSA file)
i. When exporting hardware, make sure to include bitstream
e. Open Vitis GUI
f. Import archived SDK project (ZCU102_PB_LED_SDK.zip)
i. Only the application project and hardware platform are needed, as shown in the pictures
g. In the hardware platform project.spr file, click “Update Hardware Specification”
i. Right click on hw platform on the left
ii. Click on “Update Hardware Specification” and point it to XSA file created in step 3.d
h. Build hardware platform project
i. Build software application
i. If you encounter an xparameters.h or a Makefile: Package error, look at the end of the document
j. (OPTIONAL, IF BOOTING BY SD CARD) Once platform and software projects are building properly, create BOOT.BIN image to place in sd card
i. Go to Xilinx > create boot image on the top right
ii. Change architecture to Zynq MP
iii. Find a folder to place the output BIF file and BOOT.BIN
iv. Click “add” to add the fsbl, application, and bit files. You must click add every time as they are added separately. Below are the locations of each of the files.
1. FSBL (partition type = bootloader)- ZCU104_PB_LED.xpr\ZCU104_PB_LED\ZCU104_PB_LED.sdk\fsbl_PB_LED\Debug\fsbl_PB_LED.elf
2. Application (partition type = datafile)- ZCU104_PB_LED.xpr\ZCU104_PB_LED\ZCU104_PB_LED.sdk\App_PB_LED\Debug\App_PB_LED.elf
3. Bit file (partition type = datafile)- ZCU104_PB_LED.xpr\ZCU104_PB_LED\ZCU104_PB_LED.sdk\design_1_wrapper_hw_platform_0\design_1_wrapper.bit
k. (OPTIONAL, IF BOOTING BY SD CARD) Find created BOOT.BIN and place it in your sd card. Place sd card in board’s sd card slot. Set board to boot from sd card.
l. Attach usb to microusb cable from your boards UART port to your laptop
m. Open serial connection with board using putty.
i. You must find the COM port being used by the board by going to device manager
ii. Baud Rate: 115200
n. Turn on board
o. Press buttons on zcu104 and see LEDs flash and output on terminal.
i. When you press button 1 (SW14), all the lights should flash consecutively (LED0 > LED1 > LED2 > LED3) and you should see output on the terminal
ii. When you press button 2 (SW15), one of the LEDs (LED3) will flash and you will see on the terminal telling you which button was pressed
Possible
ERROR 1 – xparameter.h
If after updating hardware specification (step 3.g), application build fails with xparameters.h missing, do not worry because this is a known error with the software. Something in the “Update HW Specification” function does not update the xparameters.h file. I have found a workaround.
1. Click on platform.spr project file on the left side in the platform project
2. On the application project BSP, Click on “Reset BSP Sources”
3. You will see another error saying
a. Multiple versions of driver “generic” assigned to different peripherals
4. Click on “Modify BSP Settings…”
5. Change all “generic” drivers to version 2.0
6. Reset BSP sources again
7. Go back to step 3.h
Possible
ERROR 2 – Makefile: Package
1. In zynqmp_fsbl Board Support Package, reset the BSP
2. Rebuild Platform Application
3. Rebuild SW Application
ResourcesVitis Embedded Software Development Flow
Vitis Unified Software Platform Documentation: Embedded Software Development
Zynq UltraScale+ MPSoC: Embedded Design Tutorial
RECAP
Now that you're at the end of the walkthrough, you should have a functioning Vitis project with your old SDK application! Congratulations! If you need help with any of the steps above or have suggestions for how I can improve this walkthrough, please do not be afraid to reach out!
Comments
Please log in or sign up to comment.