Continuing my week2 post...... this will cover the SW introductory course
The objectives for the introductory Software course are:
- Introduce developers to Xilinx SDK (Software Development Kit)
- Demonstrate SDK capabilities
- Connect SDK to hardware for execution and debug
- Utilize a peripheral interrupt to show real-time software response
- Show a basic example of how to use an external sensor module
This diagram shows the handoff of the hardware design from Vivado to the SDK:
The full hardware design including the bitstream are exported from Vivado using an HDF (Hardware Design File *.hdf). This is the only file required to handoff the design to software. The HDF is an archive containing the complete Hardware Platform Definition (XML, PSU_INIT, and Bitstream). This file is then imported into the SDK.
Labs 3-4 take you through creating an application to run on the hardware requires 3 basic steps:
- Generate a Board Support Package (BSP) that contains all the necessary device drivers
- Develop the application code
- Build the application
The device drivers that are included in a BSP are viewable in the system.mss file (MSS -> Microprocessor Software Specification) as shown below:
The feature of the MSS that I think is really helpful is that documentation and example links are included for each driver.
There are 3 applications that are built:
- Hello World
- Memory Tests
- Peripheral Tests
When creating an application you get to specify the hardware platform, the software language, and the BSP (HW configuration) used:
Another feature that is helpful is that code templates are available for new applications so that you can get started quickly with example code that can be customized.
Lab 5 used the system debugger to load and run the applications using the JTAG/UART connection:
The debugger panel allows you reset the board and program it as shown below.
Labs 6 and 7 demonstrated building and running a Zynq Boot Image from the SD card. In this case we are just running a standalone application so there are only 3 boot partitions required as shown: the first stage bootloader (FSBL) which is loaded into the on chip memory (OCM), the PL bitstream, and the application program. If we were loading and running with an OS, a second stage boot program would be required (U-Boot).
Lab 8 used SDK Project Management to archive and duplicate projects. Lab 10 covered using the xilffs (Xilinx Fat File System) library that is included in the standalone BSP to write the device temperature to the SD card .
Lab 9 demonstrated using interrupts and Lab 11 demonstrated developing a standalone sensor application. Both these labs use the mezzanine card and the Click boards from the mezzanine kit, so I only did verification on the base Ultra96 board with the debug software. We should be getting a mezzanine board soon and I'll try using it with the PetaLinux labs.
I'm learning lots of useful stuff. I think the PetaLinux course will pull all of it together. I'm falling behind on blogging. I'll try to catch up with Week 3 in the next couple of days.