Quantcast
Channel: Xilinx Wiki : Xilinx Wiki - all changes
Viewing all 11776 articles
Browse latest View live

PS and PL based Ethernet in Zynq MPSoC

$
0
0
...
Run petalinux-create command on the console
petalinux-create -t project -s <path-to-bsp>
bash> cd $XAPP_HOME\xapp1305-ps-pl-based-ethernet-solution$XAPP_HOME\xapp1305-ps-pl-based-ethernet-solution\software
// for PS emio
...
project -s software\bsps\xapp1305_ps_pl_eth_1g\xilinx-zcu102-2016.4-ps-emio.bspbsps\xapp1305_ps_pl_eth_1g\xilinx-zcu102-2016.4-ps-emio.bsp
//for PS MIO
...
project -s software\bsps\xapp1305_ps_eth_1g\xilinx-zcu102-2016.4-ps-mio.bspbsps\xapp1305_ps_eth_1g\xilinx-zcu102-2016.4-ps-mio.bsp
2.3.1.2 Configure PetaLinux
// for PS emio
...
Run petalinux-create command on the command console:
petalinux-create -t project -s <path-to-bsp>
bash> cd $XAPP_HOME/xapp1305-ps-pl-based-ethernet-solution$XAPP_HOME/xapp1305-ps-pl-based-ethernet-solution\software
bash> petalinux-create
...
project -s software\bsps\pl_eth_1g\xilinx-zcu102-2016.4-pl_eth.bspbsps\pl_eth_1g\xilinx-zcu102-2016.4-pl_eth.bsp
2.4.1.2 Configure petalinux
bash> mv xilinx-zcu102-2016.4 xapp1305_pl_eth_1g
...
Run petalinux-create command on the command console:
petalinux-create -t project -s <path-to-bsp>
bash> cd $XAPP_HOME/xapp1305-ps-pl-based-ethernet-solution$XAPP_HOME/xapp1305-ps-pl-based-ethernet-solution\software
bash> petalinux-create
...
project -s software/bsps/PLbsps/PL Ethernet 10G/xilinx-zcu102-2016.4-pl-10g.bsp
2.4.2.2 Configure petalinux
bash> mv xilinx-zcu102-2016.4 xapp1305_pl_eth_10g

PS and PL based Ethernet in Zynq MPSoC

$
0
0
...
Run petalinux-create command on the console
petalinux-create -t project -s <path-to-bsp>
bash> cd $XAPP_HOME\xapp1305-ps-pl-based-ethernet-solution\software$XAPP_HOME/xapp1305-ps-pl-based-ethernet-solution/software
// for PS emio
...
project -s bsps\xapp1305_ps_pl_eth_1g\xilinx-zcu102-2016.4-ps-emio.bspbsps/xapp1305_ps_pl_eth_1g/xilinx-zcu102-2016.4-ps-emio.bsp
//for PS MIO
...
project -s bsps\xapp1305_ps_eth_1g\xilinx-zcu102-2016.4-ps-mio.bspbsps/xapp1305_ps_eth_1g/xilinx-zcu102-2016.4-ps-mio.bsp
2.3.1.2 Configure PetaLinux
// for PS emio
...
petalinux-create -t project -s <path-to-bsp>
bash> cd $XAPP_HOME/xapp1305-ps-pl-based-ethernet-solution\software
...
project -s bsps\pl_eth_1g\xilinx-zcu102-2016.4-pl_eth.bspbsps/pl_eth_1g/xilinx-zcu102-2016.4-pl_eth.bsp
2.4.1.2 Configure petalinux
bash> mv xilinx-zcu102-2016.4 xapp1305_pl_eth_1g
...
Run petalinux-create command on the command console:
petalinux-create -t project -s <path-to-bsp>
bash> cd $XAPP_HOME/xapp1305-ps-pl-based-ethernet-solution\software$XAPP_HOME/xapp1305-ps-pl-based-ethernet-solution/software
bash> petalinux-create
...
project -s bsps/PL Ethernet 10G/xilinx-zcu102-2016.4-pl-10g.bspbsps/xapp1305_pl_eth_10g/xilinx-zcu102-2016.4-pl-10g.bsp
2.4.2.2 Configure petalinux
bash> mv xilinx-zcu102-2016.4 xapp1305_pl_eth_10g

PS and PL based Ethernet in Zynq MPSoC

$
0
0
...
2.3.1.2 Configure PetaLinux
// for PS emio
bash> mv xilinx-zcu102-2016.4-ps-emio.bspxilinx-zcu102-2016.4 xapp1305_ps_emio_eth
bash> cd xapp1305_ps_emio_eth
//for PS mio
bash> mv xilinx-zcu102-2016.4-ps-mio.bspxilinx-zcu102-2016.4 xapp1305_ps_mio_eth
bash> cd xapp1305_ps_mio_eth
bash> petalinux-config

Zynq UltraScale MPSoC Base TRD 2016.4 - Design Module 6

$
0
0
Return to the Design Tutorials Overview.
Design Overview
This module shows how to add a Test Pattern Generator (TPG) implemented in the PL.
{base-trd-2016-3-dm6-bd.png}
Design Components
This module requires the following components:
zcu102_base_trd (Vivado)
pmu_fw
petalinux_bsp
zynqmp_fsbl
bl31
u-boot
kernel
device tree (system-dm6.dts)
rootfs
video_lib
video_qt2
Build Flow Tutorials
PL Base TRD
This tutorial shows how to build the Base TRD Vivado design that implements the TPG capture pipeline.
Create a Vivado project. Select 'es1' instead if you are targeting a rev D board with ES1 silicon.
% cd $TRD_HOME/pl/zcu102_base_trd
% vivado -s ./scripts/create_project.tcl -tclargs -platform zcu102 -silicon es2
Implement the design and generate a bitstream
{base-trd-2016-3-dm6-base-trd-bit.jpg}
Copy the generated bitstream to the PetaLinux directory or alternatively use the pre-built bit file that is already bundled with the PetaLinux BSP.
% cp -f project/zcu102_base_trd.runs/impl_1/zcu102_base_trd_wrapper.bit $TRD_HOME/apu/petalinux_bsp/images/linux
PMU Firmware
Please refer to design module 1 - PMU firmware for instructions or skip this step if you have built the PMU firmware in a previous module.
PetaLinux BSP
This tutorial shows how to build the Linux image and boot image using the PetaLinux build tool.
The petalinux-config step can be skipped if this was already done in a previous module.
% cd $TRD_HOME/apu/petalinux_bsp
% petalinux-config --get-hw-description=./hw-description --oldconfig
Select the device-tree matching design module 6 and build all Linux image components. If you have run petalinux-build in a previous module, the build step will be incremental.
% cd subsystems/linux/configs/device-tree
% cp system-dm6.dts system-top.dts
% petalinux-build
% cd -
Create a boot image.
% cd images/linux
% petalinux-package --boot --bif=dm6.bif --force
Copy the generated boot image and Linux image to the dm6 SD card directory.
% mkdir -p $TRD_HOME/images/dm6/bin
% cp BOOT.BIN image.ub $TRD_HOME/images/dm6
Copy the file autostart.sh from the pre-built dm9 SD card directory.
% cp $TRD_HOME/images/dm9/autostart.sh $TRD_HOME/images/dm6
Video Qt Application
There is no need to rebuild the video_qt2 application if you have already built it in module 5, otherwise follow the instructions from module 5.
Copy the generated video_qt2 executable to the dm6 SD card directory.
% cp -f video_qt2/video_qt2 $TRD_HOME/images/dm6/bin
Copy the video_qt2 wrapper scripts from the pre-built dm9 SD card directory.
% cp $TRD_HOME/images/dm9/bin/run_video.sh $TRD_HOME/images/dm9/bin/video_qt2_wrap.sh $TRD_HOME/images/dm6/bin/
Run Flow Tutorial
See here for board setup instructions.
Copy all the files from the $TRD_HOME/images/dm6 SD card directory to a FAT formatted SD card.
Power on the board to boot the images; make sure INIT_B, done and all power rail LEDs are lit green.
After ~30 seconds, the display will turn on and the application will start automatically, targeting the max supported resolution of the monitor (one of 3840x2160 or 1920x1080 or 1280x720).
Upon application exit, use the below login and password to log into the framebuffer or serial console:
root@Xilinx-ZCU102-2016_3 login: root
password: root
The SD card file system is mounted at /media/card
To re-start the TRD application type run_video.sh
The user can now control the application from the GUI's control bar (bottom) displayed on the monitor.
{tpg_dm-6.jpg}
By default, application launches with VIVID as a video-source, user can also select TPG from the "Video-source selection" button present on the GUI's control-bar.
Virtual Video Device (VIVID): emulates a USB webcam purely in software
USB Webcam (UVC): using the universal video class driver
Test Pattern Generator (TPG); implemented in the PL
The video info panel (top left) shows essential settings/statistics.
The CPU utilization graph (top right) shows CPU load for each of the four A53 cores.

Zynq UltraScale+ MPSoC USB 3.0 CDC Device Class Design

$
0
0

This Page is under construction

Document History
Date

Zynq UltraScale+ MPSoC USB 3.0 CDC Device Class Design

$
0
0

This Page is under construction
Document History
...
Rutuja Chavan & Rajesh Gugulothu
Initial version
02/15/2017
1.1
Rutuja Chavan
Updated to 2016.4 version

Summary
The Zynq® UltraScale+™ MPSoC USB 3.0 controller consists of two independent dual-role device (DRD) controllers. Both can be individually configured to work as host or device at any given time.The USB 3.0 DRD controller provides an eXtensible host controller interface (xHCI) to the system software through the advanced eXtensible interface (AXI) slave interface. An internal DMA engine is present in the controller and it utilizes the AXI master interface to transfer data. There are four primary types of communication defined by the USB protocol, based on which any required application can be built without changing the firmware or underlying hardware for different applications. These transfer types are Control Transfer, Bulk Transfer, Isochronous transfer and Interrupt transfer. Zynq® UltraScale+™ MPSoC USB3.0 controller supports all four types of transfers.This Tech Tip explains how to enable all the configuration options, step by step procedure to use the Zynq® UltraScale+™ MPSoC USB 3.0 controller in device mode and make use of bulk transfer type for a serial communication device abstraction using the USB 3.0. The CDC (ACM) class in the USB Component is used for data communication. You can typically use it in applications like serial COM or UART communicationThis design covers:
...
USB 3.0 Controller
Boards/Tools
ZCU102 Rev1.0 board,
ZCU102
Rev C/ RevB/C/ D board
Xilinx Tools Version
Xilinx SDK 2016.3,2016.4, Petalinux 2016.32016.4
Other Details
--
...
The gadget serial driver is a Linux USB gadget driver, a USB device side driver. It runs on a Linux system that has USB device side hardware; for example, a PDA, an embedded Linux system, or a PC with a USB development card. The gadget serial driver talks over USB to either a CDC ACM driver or a generic USB serial driver running on a host PC. On the device-side Linux system, the gadget serial driver looks like a serial device. On the host-side system, the gadget serial device looks like a CDC ACM compliant class device or a simple vendor specific device with bulk in and bulk out endpoints, and it is treated similarly to other serial devices.The host side driver can potentially be any ACM compliant driver or any driver that can talk to a device with a simple bulk in/out interface. With the gadget serial driver and the host side ACM or generic serial driver running, you should be able to communicate between the host and the gadget side systems as if they were connected by a serial cable.Configuring and building the Linux Operating System for Zynq Ultrascale + MPSoC
Follow the PetaLinux SDK installation user guide in this document. Execute the steps till the PetaLinux Working Environment Setup section for installing PetaLinux SDK to your Linux machine.
...
PetaLinux version 2016.3.2016.4. It recommendis recommended to download
...
installer version 2016.32016.4 from Xilinx website. This example uses the ZCU102 PetaLinux BSP to create a PetaLinux project. Ensure that you have downloaded the ZCU102 BSP for PetaLinux as per requirement.
After installing PetaLinux SDK create a project in the PetaLinux installed directory by executing $ petalinux-create –t project –n <project_name> command
Above command will create a project with the user provided name under the PetaLinux installed directory. Change the directory to project directory which is created above. $ cd <project_name>
...
{filesystem_configuratioj.png} Figure 4: Linux kernel configuration for Userspace-driven configuration filesystem
Ensure that parameters shown in the below figure are selected in the kernel source tree and save & exit the configuration file.
...
device mode. Change the USB device treeAdd below mentioned node property “dr_mode“ in the device tree source code as “peripheral" which controls the modeat end of the device driver. The respective device treesystem-top.dts file named as pcw.dtsi can be found under the path “<petalinux_installed_path>/<project_name>/subsystems/linux/configs/device-tree” as shown in figure below.
{device_tree_configuration.jpg} Figure 5: Device tree modification for USB 3.0 device mode
present at "<project_name>/project-spec/meta-user/recipes-dt/device-tree/files/"
&dwc3_0 {
dr_mode = "peripheral";
status = "okay";
};

With the
...
in kernel configuration,configuration and device tree, build petalinux
Create BOOT.BIN using petalinux SDK tool, change to images/linux (cd images/linux) directory and run below command
$ petalinux-package --boot --fsbl zynqmp_fsbl.elf --u-boot. This will create BOOT.BIN under images/linux
...
copy the following files into the SD card
BOOT.BIN which is created in the above section.
...
following path “<petalinux_installed_directory>/<project_name>/build/linux/kernel/xlnx-4.6/drivers/usb/gadget/”.“<project_name>/build/tmp/work/plnx_aarch64-xilinx-linux/petalinux-user-image/1.0-r0/rootfs/lib/modules/4.6.0-xilinx/kernel/drivers/usb/gadget/”
u_serial.ko file
...
following path “<petalinux_installed_directory>/<project_name>/build/linux/kernel/xlnx-4.6/drivers/usb/gadget/function".“<project_name>/build/tmp/work/plnx_aarch64-xilinx-linux/petalinux-user-image/1.0-r0/rootfs/lib/modules/4.6.0-xilinx/kernel/drivers/usb/gadget/function"
usb_f_serial.ko from following path “<petalinux_installed_directory>/<project_name>/build/linux/kernel/xlnx-4.6/drivers/usb/gadget/function".“<project_name>/build/tmp/work/plnx_aarch64-xilinx-linux/petalinux-user-image/1.0-r0/rootfs/lib/modules/4.6.0-xilinx/kenel/drivers/usb/gadget/function"
usb_f_acm.ko from following path “<petalinux_installed_directory>/<project_name>/build/linux/kernel/xlnx-4.6/drivers/usb/gadget/function".“<project_name>/build/tmp/work/plnx_aarch64-xilinx-linux/petalinux-user-image/1.0-r0/rootfs/lib/modules/4.6.0-xilinx/kernel/drivers/usb/gadget/function"
g_serial.ko from following path “<petalinux_installed_directory>/<project_name>/build/linux/kernel/xlnx-4.6/drivers/usb/gadget/legacy".“<project_name>/build/tmp/work/plnx_aarch64-xilinx-linux/petalinux-user-image/1.0-r0/rootfs/lib/modules/4.6.0-xilinx/kernel/drivers/usb/gadget/legacy"
Image.ub from “<petalinux_installed_directory>/<project_name>/images/linux”.“<project_name>/images/linux”
Note: For user convenience SD card images are provided along with this Tech Tip. Download the design files archive released with this Tech Tip and extract it under the convenient location of host machine. Find the SD card images for Linux under the path Design_files/pre_built_images/ of your extracted directory. User can use these images for quick test.
ZCU102 Board Setup:
...
Zynqmp_CDC_Design_files.zip
Design_files
BOOT.BINBOOT_rev1.0.BIN
BOOT_revBCD.BIN

image.ub
Various kernel modules listed below

Zynq UltraScale MPSoC Base TRD 2016.4 - Design Module 6

$
0
0

Zynq UltraScale MPSoC Base TRD 2016.4 - Design Module 7

$
0
0
Return to the Design Tutorials Overview.
Design Overview
This module shows how to add a 2D convolution filter between the capture pipeline and the display. The 2D filter is implemented purely in software using the OpenCV library.
{base-trd-2016-3-dm7-bd.png}
Design Components
This module requires the following components:
zcu102_base_trd (SDSoC)
pmu_fw
petalinux_bsp
zynqmp_fsbl
bl31
u-boot
kernel
device tree
rootfs
filter2d (SW)
video_lib
video_qt2
Build Flow Tutorials
2D Filter Sample
This tutorial shows how to build the OpenCV version of the 2D filter sample based on the Base TRD SDSoC platform.
Follow the steps in design module 5 to create a new workspace and to import the video_lib and video_qt2 projects. Otherwise, open the existing XSDK workspace only this time using the SDx tool instead of XSDK.
% cd $TRD_HOME/apu/video_app
% sdx -workspace . &
Change the eclipse perspective to 'SDx' instead of 'C/C++' which is the current selection.
{base-trd-2016-3-dm7-sdx-perspective.png}
Create a new SDx Project
{base-trd-2016-3-dm7-sdx-project.png}
Enter 'filter2d' as project name
{base-trd-2016-3-dm7-sdx-filter2d.png}
Click 'Add Custom Platform', browse to the $TRD_HOME/apu/zcu102_base_trd directory and confirm. Select the newly added 'zcu102_base_trd (custom)' platform from the list and click 'Next'.
{base-trd-2016-3-dm7-sdx-trd-pfm.png}
Check the 'Linux Root File System' box and browse to the $TRD_HOME/apu/petalinux_bsp/build/linux/rootfs/stage directory. This assumes the petalinux-build command has been run in a previous module.
Check the 'Shared Library' box and click 'Next'.
{base-trd-2016-3-dm7-sdx-sw-pfm.png}
Select the '2D Filter' template and click 'Finish'.
{base-trd-2016-3-dm7-sdx-2dfilter-template.png}
Change the 'Active build configuration' to Release in the SDx Project Settings window.
Remove the filter2d_sds HW function by highlighting the function name and clicking the red X symbol.
{base-trd-2016-3-dm7-sdx-project-settings.png}
Right-click the filter2d project, select 'C/C++ Build Settings'. Navigate to the 'Build Artifacts' tab and add the output prefix 'lib'. Click OK.
{base-trd-2016-3-dm7-sdx-lib-prefix.png}
Right-click the filter2d project and select 'Build Project'.
{base-trd-2016-3-dm7-sdx-filter2d-build.png}
Copy the content of the generated sd_card folder to the dm7 SD card directory
% mkdir -p $TRD_HOME/images/dm7/bin
% cp -rf filter2d/Release/sd_card $TRD_HOME/images/dm7/
Video Qt Application
This tutorial shows how to build the video library and the video Qt application.
Right-click the video_lib project, select 'C/C++ Build Settings'. Add the symbol 'WITH_SDSOC' and click OK.
{base-trd-2016-3-dm7-video-lib.png}
Open the file $TRD_HOME/apu/video_app/video_qt2/video_qt2.pro with an editor and modify the highlighted lines as shown in the screenshot by removing the '#' symbol to un-comment those lines we had previously commented in module 5.
{base-trd-2016-3-dm7-video-qt.png}
Source the Qt setup script to re-generate the Qt Makefile reflecting these changes.
% cd video_qt2
% source qmake_set_env.sh
Right-click the video_qt project and click 'Build Project'.
{base-trd-2016-3-dm5-video-qt-build.png}
Copy the generated video_qt2 executable to the dm7 SD card directory.
% cp -f video_qt2 $TRD_HOME/images/dm7/bin/
Copy the video_qt2 wrapper scripts from the pre-built dm9 SD card directory.
% cp $TRD_HOME/images/dm9/bin/run_video.sh $TRD_HOME/images/dm9/bin/video_qt2_wrap.sh $TRD_HOME/images/dm7/bin/
Copy the file autostart.sh from the pre-built dm9 SD card directory.
% cp $TRD_HOME/images/dm9/autostart.sh $TRD_HOME/images/dm7
Run Flow Tutorial
See here for board setup instructions.
Copy all the files from the $TRD_HOME/images/dm7 SD card directory to a FAT formatted SD card.
Power on the board to boot the images; make sure INIT_B, done and all power rail LEDs are lit green.
After ~30 seconds, the display will turn on and the application will start automatically, targeting the max supported resolution of the monitor (one of 3840x2160 or 1920x1080 or 1280x720).
Upon application exit, use the below login and password to log into the framebuffer or serial console:
root@Xilinx-ZCU102-2016_3 login: root
password: root
The SD card file system is mounted at /media/card
To re-start the TRD application type run_video.sh
The user can now control the application from the GUI's control bar (bottom) displayed on the monitor.
By default, application launches with VIVID as a video-source, user can also select TPG from the "Video-source selection" button present on the GUI's control-bar.
Virtual Video Device (VIVID): emulates a USB webcam purely in software
USB Webcam (UVC): using the universal video class driver
Test Pattern Generator (TPG); implemented in the PL
A 2D convolution filter can be turned on and different filter presets can be selected; the following filter modes are available:
OFF - accelerator is disabled/bypassed
SW - accelerator is run on A53 using OpenCV algorithm
HW - accelerator is run on A53 using HLS algorithm
{base-trd-2016-3-dm7-video_qt2.jpg}
The video info panel (top left) shows essential settings/statistics.
The CPU utilization graph (top right) shows CPU load for each of the four A53 cores.


Zynq UltraScale MPSoC Base TRD 2016.4 - Design Module 7

$
0
0
...
Right-click the video_lib project, select 'C/C++ Build Settings'. Add the symbol 'WITH_SDSOC' and click OK.
{base-trd-2016-3-dm7-video-lib.png}
Open the file $TRD_HOME/apu/video_app/video_qt2/video_qt2.pro with an editor and modify the highlighted lines as shown in the screenshot by removing the '#' symbol to un-comment those lines we had previously commented in module 5.
{base-trd-2016-3-dm7-video-qt.png}

Source the Qt setup script to re-generate the Qt Makefile reflecting these changes.
% cd video_qt2$TRD_HOME/apu/video_app/video_qt2
% source qmake_set_env.sh
% qmake video_qt2-dm7.pro -r -spec linux-oe-g++
Right-click the video_qt project and click 'Build Project'.
{base-trd-2016-3-dm5-video-qt-build.png}

Zynq UltraScale MPSoC Base TRD 2016.3 - Design Module 8

$
0
0
...
Expand the filter2d project and sources in the project explorer, select the filter2d_sds function and click 'Toggle HW/SW' to select this function for hardware acceleration.
{base-trd-2016-3-dm8-sdx-filter2d-hw.png}
...
project settings panepanel and the
{base-trd-2016-3-dm8-sdx-project-settings.png}
Right-click the filter2d project and select 'Build Project'.

Zynq UltraScale MPSoC Base TRD 2016.4 - Design Module 8

$
0
0
Return to the Design Tutorials Overview.
Design Overview
This module shows how to move the 2D convolution filter from software to hardware using the PL optimized hls_video library that provides an OpenCV equivalent function.
{base-trd-2016-3-dm8-bd.png}
Design Components
This module requires the following components:
zcu102_base_trd (SDSoC)
pmu_fw
petalinux_bsp
zynqmp_fsbl
bl31
u-boot
kernel
device tree
rootfs
filter2d (HW)
video_lib
video_qt2
Build Flow Tutorials
2D Filter Sample2dfilter_dm8
This tutorial shows how to build the hls_video version of the 2D filter sample based on the Base TRD SDSoC platform.
Open the existing SDx workspace from design module 7 using the SDx tool.
% cd $TRD_HOME/apu/video_app
% sdx -workspace . &
Expand the filter2d project and sources in the project explorer, select the filter2d_sds function and click 'Toggle HW/SW' to select this function for hardware acceleration.
{base-trd-2016-3-dm8-sdx-filter2d-hw.png}
Verify the function was added to the HW functions in the project settings panel and the clock frequency is set to 300MHz
{base-trd-2016-3-dm8-sdx-project-settings.png}
Right-click the filter2d project and select 'Build Project'.
{base-trd-2016-3-dm7-sdx-filter2d-build.png}
Copy the content of the generated sd_card folder to the dm8 SD card directory
% cp -rf filter2d/Release/sd_card $TRD_HOME/images/dm8
Video Qt Application
There is no need to rebuild the video_qt2 application if you have already built it in module 7, otherwise follow the instructions from module 7.
Copy the generated video_qt2 executable to the dm8 SD card directory or alternatively use the pre-built version bundled with the SDSoC platform.
% cp -f video_qt2/video_qt2 $TRD_HOME/images/dm8/bin/
Run Flow Tutorial
See here for board setup instructions.
Copy all the files from the $TRD_HOME/images/dm8 SD card directory to a FAT formatted SD card.
Power on the board to boot the images; make sure INIT_B, done and all power rail LEDs are lit green.
After ~30 seconds, the display will turn on and the application will start automatically, targeting the max supported resolution of the monitor (one of 3840x2160 or 1920x1080 or 1280x720).
Upon application exit, use the below login and password to log into the framebuffer or serial console:
root@Xilinx-ZCU102-2016_3 login: root
password: root
The SD card file system is mounted at /media/card
To re-start the TRD application type run_video.sh
The user can now control the application from the GUI's control bar (bottom) displayed on the monitor.
By default, application launches with VIVID as a video-source, user can also select TPG from the "Video-source selection" button present on the GUI's control-bar.
Virtual Video Device (VIVID): emulates a USB webcam purely in software
USB Webcam (UVC): using the universal video class driver
Test Pattern Generator (TPG); implemented in the PL
A 2D convolution filter can be turned on and different filter presets can be selected; the following filter modes are available:
OFF - accelerator is disabled/bypassed
SW - accelerator is run on A53 using OpenCV algorithm
HW - accelerator is run on PL generated from HLS algorithm
{base-trd-2016-3-dm8-video_qt2.jpg}
The video info panel (top left) shows essential settings/statistics.
The CPU utilization graph (top right) shows CPU load for each of the four A53 cores.

Zynq UltraScale MPSoC Base TRD 2016.4 - Design Module 4

$
0
0

Zynq UltraScale MPSoC Base TRD 2016.4 - Design Module 9

$
0
0
Return to the Design Tutorials Overview.
Design Overview
This module combines all the previous modules by:
adding the heartbeat component running on RPU0
adding the perfapm-server component running on RPU1
adding the perfapm-client library integrated into the video_qt2 application
The perfapm-client and perfapm-server components communicate via RPMsg on the master side and OpenAMP on the remote side.
The remoteproc framework is used by the master to download the perfapm-server firmware on the remote.
Instead of printing the throughput numbers on the serial console as done in module 4, the numbers are now plotted as graph in the Qt GUI.
The perfapm-server and heartbeat applications demonstrate simultaneous, independent execution on both RPU cores configured in split mode.
{base-trd-2016-3-dm9-bd.png}
Design Components
This module requires the following components:
zcu102_base_trd (SDSoC)
pmu_fw
petalinux_bsp
zynqmp_fsbl
bl31
u-boot
kernel
device tree
rootfs
filter2d (HW)
video_lib
video_qt2
perfapm-client
perfapm-server
heartbeat
Build Flow Tutorials
2D Filter Sample
There is no need to rebuild the filter2d library if you have already built it in module 8, otherwise follow the instructions from module 8.
Copy the content of the generated sd_card folder to the dm9 SD card directory.
% cd $TRD_HOME/apu/video_app
% cp -rf filter2d/Release/sd_card $TRD_HOME/images/dm9
Copy the generated bitstream to the PetaLinux directory or alternatively use the pre-built bitstream already bundled with the PetaLinux BSP.
% cp -f filter2d/Release/libfilter2d.so.bit $TRD_HOME/apu/petalinux_bsp/images/linux
Perfapm-client Library
This tutorial shows how to build the performance monitor client library.
Open the existing SDx workspace from design module 8 using the SDx tool.
% cd $TRD_HOME/apu/video_app
% sdx -workspace . &
From the menu bar, select File -> Import Project, then select General -> Existing Projects into Workspace. Click Next.
{base-trd-2016-3-dm9-import-project.png}
Browse to the $TRD_HOME/apu/perfapm-client directory, confirm and only check the perfapm-client project. Click Finish.
{base-trd-2016-3-dm9-perfapm-client.png}
Right-click the perfapm-client project and select 'Build Project'
{base-trd-2016-3-dm9-build-project.png}
Video Qt Application
This tutorial shows how to build the video library and the video Qt application.
Open the file $TRD_HOME/apu/video_app/video_qt2/video_qt2.pro with an editor and modify the highlighted lines as shown in the screenshot by removing the '#' symbol to un-comment those lines we had previously commented in module 5.
{base-trd-2016-3-dm9-video-qt.png}
Source the Qt setup script to re-generate the Qt Makefile reflecting these changes.
% cd video_qt2
% source qmake_set_env.sh
Right-click the video_qt2 project and click 'Build Project'.
{base-trd-2016-3-dm5-video-qt-build.png}
Copy the generated video_qt2 executable to the dm9 SD card directory.
% cp -f video_qt2/video_qt2 $TRD_HOME/images/dm9/bin/
Heartbeat Application
Please refer to design module 2 Heartbeat Application for instructions or skip this step if you have built the heartbeat application in a previous module.
Perfapm-Server Application
Please refer to design module 4 Perfapm-server Application for instructions or skip this step if you have built the perfapm-server application in a previous module.
PetaLinux BSP
This tutorial shows how to build the Linux image and boot image using the PetaLinux build tool.
The petalinux-config step can be skipped if this was already done in a previous module.
% cd $TRD_HOME/apu/petalinux_bsp
% petalinux-config --get-hw-description=./hw-description --oldconfig
Select the device-tree matching design module 9 and build all Linux image components. If you have run petalinux-build in a previous module, the build step will be incremental.
% cd subsystems/linux/configs/device-tree
% cp system-dm9.dts system-top.dts
% petalinux-build
% cd -
Create a boot image.
% cd images/linux
% petalinux-package --boot --bif=dm9.bif --force
Copy the generated boot image and Linux image to the dm9 SD card directory.
% cp -f BOOT.BIN image.ub $TRD_HOME/images/dm9/
Run Flow Tutorialrun_dm9
See here for board setup instructions.
Copy all the files from the $TRD_HOME/images/dm9 SD card directory to a FAT formatted SD card.
Power on the board; make sure INIT_B, done and all power rail LEDs are lit green.
After ~30 seconds, the display will turn on and the application will start automatically, targeting the max supported resolution of the monitor (one of 3840x2160 or 1920x1080 or 1280x720).
Upon application exit, use the below login and password to log into the framebuffer or serial console:
root@Xilinx-ZCU102-2016_3 login: root
password: root
The SD card file system is mounted at /media/card
To re-start the TRD application type run_video.sh
The user can now control the application from the GUI's control bar (bottom) displayed on the monitor.
{main_display.jpg}
The following video sources are available:
Virtual Video Device (VIVID): emulates a USB webcam purely in software
USB Webcam (UVC): using the universal video class driver
Test Pattern Generator (TPG); implemented in the PL
A 2D convolution filter can be turned on and different filter presets can be selected; the following filter modes are available:
OFF - accelerator is disabled/bypassed
SW - accelerator is run on A53
HW - accelerator is run on PL
The video info panel (top left) shows essential settings/statistics.
The CPU utilization graph (top right) shows CPU load for each of the four A53 cores.
The memory throughput graph (bottom right) shows memory traffic generated by video source, filter and display.
The TPG settings panel gives access to advanced TPG controls:
{tpg_settings.jpg}
The 2D filter settings panel gives access to advanced filter controls:
{2dfilter_settings.jpg}

Zynq UltraScale MPSoC Base TRD 2016.4 - Design Module 8

$
0
0

Zynq UltraScale MPSoC Base TRD 2016.4 - Design Module 4

$
0
0

Zynq UltraScale MPSoC Base TRD 2016.4 - Design Module 3

$
0
0
...
Copy all the files from the $TRD_HOME/images/dm3 SD card directory to a FAT formatted SD card.
Power on the board to boot the images; make sure all power rail LEDs are lit green.
...
be viewed on UART-1. When prompted, user need to press 'Y' to view the application prints on UART-1 which isas shown in the following picture:
{perfapm-client-test_console.png}
pictures:
{dm-3_1.png}
{dm-3_2.png}

Zynq UltraScale MPSoC Base TRD 2016.4 - Design Module 9

$
0
0
...
Video Qt Application
This tutorial shows how to build the video library and the video Qt application.
Open the file $TRD_HOME/apu/video_app/video_qt2/video_qt2.pro with an editor and modify the highlighted lines as shown in the screenshot by removing the '#' symbol to un-comment those lines we had previously commented in module 5.
{base-trd-2016-3-dm9-video-qt.png}

Source the Qt setup script to re-generate the Qt Makefile reflecting these changes.
% cd video_qt2$TRD_HOME/apu/video_app/video_qt2
% source qmake_set_env.sh
% qmake video_qt2-dm9.pro -r -spec linux-oe-g++
Right-click the video_qt2 project and click 'Build Project'.
{base-trd-2016-3-dm5-video-qt-build.png}

Zynq UltraScale MPSoC Base TRD 2016.4 - Design Module 9

$
0
0
...
{base-trd-2016-3-dm5-video-qt-build.png}
Copy the generated video_qt2 executable to the dm9 SD card directory.
...
cp -f video_qt2/video_qt2video_qt2 $TRD_HOME/images/dm9/bin/
Heartbeat Application
Please refer to design module 2 Heartbeat Application for instructions or skip this step if you have built the heartbeat application in a previous module.

Zynq UltraScale MPSoC Base TRD 2016.4 - Design Module 3

$
0
0

Zynq UltraScale MPSoC Base TRD 2016.4 - Design Module 7

$
0
0
...
Copy the content of the generated sd_card folder to the dm7 SD card directory
% mkdir -p $TRD_HOME/images/dm7/bin
...
cp -rf filter2d/Release/sd_cardfilter2d/Release/sd_card/* $TRD_HOME/images/dm7/
Video Qt Application
This tutorial shows how to build the video library and the video Qt application.
Viewing all 11776 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>