This page is deprecated and is no longer being updated. The content is being retained for reference. For more information about running Ubuntu on Zynq UltraScale+ MPSoC, please refer to Canonical Ubuntu

Table of Contents


Document History

Updated for 2017.1 tools
DateVersionAuthorDescription of Revisions
1stOct20161Upender Cherukupally
Jerry Wong
Srikanth Erusalagandi
Initial Image only release
22ndDec20171.1Aniket KolarkarUpdated with 2017.1 tools release.

Description/Summary

Zynq® UltraScale+™ MPSoC delivers unprecedented levels of heterogeneous multi-processing and combines seven user programmable processors including Quad-core ARM® Cortex™-A53 Application Processing Unit (APU), Dual-core 32-bit ARM® Cortex™-R5 Real Time Processing Unit (RPU), and ARM® Mali™-400 MP2 Graphics Processing Unit (GPU). It is Industry’s First Multi-Processor SoC delivering 5x system level performance-per-watt and any-to-any connectivity.

This demonstration showcases the fully featured desktop-class operating system running multiple applications on symmetric multiprocessing (SMP) Linux on APU and graphics rendering on the GPU. Users can install and run any required applications from open source. The demo also enables quick migration of Linux/Ubuntu Desktop based applications to Zynq UltraScale+ MPSoC.
  1. Ubuntu Desktop environment on SMP Linux with multiple applications in-built; and flexible to create, download and install new applications on APU subsystem.
  2. Multiple telnet based applications like Mandelbrot Xaos are executing simultaneously on symmetric multiprocessing (SMP) Linux on APU subsystem.
  3. Demonstrates automated Power Advantage Tool to monitor the run time power consumption of Zynq UltraScale+ MPSoC running different applications.

Figure 1: Zynq UltraScale+ MPSoC Block Diagram with blocks highlighted used in this design


The following Zynq® UltraScale+™ MPSoC PS components are used in this demonstration

Software Stack used for this demonstration

Files Provided
zynqus_pwr_zcu102_20171220.zipArchived file
contain the following files/folders:
  1. zynqus\pwr\sd: This folder contains the Ubuntu Desktop Images file for the SD card to boot in SD boot mode
  2. zynqus\pwr\ZynqUS_Demos: This folder contains the Power Advantage Tool Host PC files including the GUI and automated scripts




Requirements:


Setup:

Host Machine Setup for Power Advantage Tool:


1. Extract the downloaded zcu102_ubuntu_pwr_demo_<Timestamp>.zip file (e.g. zynqus_pwr_zcu102_20171220.zip) on to your host hard drive.

2. Copy the ZynqUS_Demos folder from the extracted zip file zynqus\pwr\ZynqUS_Demos to C: drive as shown below.
C:\ZynqUS_Demos

3. Install the required installation files for running the demo.
Note: The following is a one-time Installation for the host machine.
If Tera Term, Putty, AutoHotkey, and CP210x driver are already installed and configured, just ignore that step in ‘1’

The installers are located in the C:\ZynqUS_Demos\tools directory

Note: This might ask you to restart the machine. Perform the next step before restarting the machine

4. Modify your laptop Ethernet IP to "192.168.1.110" using the following steps
Windows LAN settings Page1

Windows LAN settings Page2


Static IP address setting

5. Restart the Host machine.

Preparing the SD card with pre-built Images:


1. Extract the <Timestamp>_zcu102_ubuntu.zip (e.g. zynqus_pwr_zcu102_20171220.zip) present in the "zynqus\pwr\sd" directory. It contians the <TimeStamp>_zcu102_ubuntu.img file which needs to be extracted to the SD card. The SD card can be burned with the .img file using the Win32DiskImager.exe tool on Windows PC or using Linux commands on a Linux PC.

2. Install Win32DiskImager.exe Tool
The tool can be downloaded and installed from https://sourceforge.net/projects/win32diskimager/

3. SD card image (<TimeStamp>_zcu102_ubuntu.img) which can be written to 16 GB card (bigger device if any issues with the size) by following method
Burn this image using the Win32 disk Image writer,
Step 1: as highlighted below first browse the path to <TimeStamp>_zcu102_ubuntu.img file
Step 2: In Device select the SD card partition (This has to selected with utmost care as this tool is going to format the selected drive) and
Step 3: Select the option to write to SD card selected in Device option.
Disk Image selections for writing img file to SD card

4. On a Linux PC we can burn the .img image onto SD Card using the DD command

$ dd if=name.img of=/dev/sdb
Where ‘if’ is pointing to name.img file of the Ubuntu Desktop image and ‘of’ points to the SD card to which the image has to be extracted.

5. By doing this you should have the following directories and images on your SD card.

ZCU102 Board Setup:

1. Connect the Micro USB cable into the ZCU102 Board Micro USB port J83, and the other end into an open USB port on the host PC. This cable will be used for UART over USB communication.
2. Connect one end of Ethernet cable into the ZCU102 connector J73, and other end connect to the Ethernet socket of the host machine.
3. Insert SD card into the SD card slot J100.
4. Set the SW6 switches as shown. This configures the boot settings to boot from SD:
Switch selection for SD boot mode

5. Connect 12V Power to the ZCU102 6-Pin Molex connector.

6. Connect the Display Port or HDMI monitor using DisplayPort or HDMI cable to U50 or HDMI TX connector respectively.

7.The following figure shows the connections made to the ZCU102 board.

ZCU102 Board Connections


8. Flashing MSP430:
If you have received new demo software for an existing ZCU102 board, you may need to flash the onboard MSP430 to enable new features. To flash the MSP430, refer to Appendix A.


Execution


1. Switch on the ZCU102 Board at SW1 (red switch).

2. In few seconds the Ubuntu Desktop will boot as shown in the following figure.
ZCU102 Ubuntu Welcome Screen




3. As shown in the following figure there are few icons tailor made like Qt cube demo, 3D Car Model, Soft glMark2 etc. to execute the Zynq UltraScale+ MPSoC specific applications.


4. Right click and open the applications, following steps explains the each of the above icons.

5. Check if the Ethernet port is up by using the “ifconfig” command. With 2016.2 tool version images The ZC102 Ethernet port is default configured to eth4 interface.
Use the following command in the terminal to assign a static IP to the board.

$ “ifconfig eth4 192.168.1.112 up”

If there is no eth4 interface, then try assigning IP Address to other interfaces from eth0 to eth6 to bring up the Ethernet interface.
Once the IP address successfully assigned launch the Web server application.

6. Double click on the Webserver icon on the desktop and following window will pop up. This window shows the IP address of the ZCU102, so use this IP address in the web client of you PC/laptop.

WebClient Launch Info dialog


7. In Host PC or Laptop launch any web browser like Chrome or Internet Explorer and type the following in the Address bar of the Web Browser.
http://192.168.1.112
Web server application

8 . To launch the OSG car demo, Select the “OSG Car Model” icon. This will launch the Car Demo as shown below.
The OSG Car Graphics is rendered by the GPU.



9. Drag the Car to any direction by holding the Mouse left button.
You should see the Car rotating on the window.

10. To minimize this window select the keys: ‘Ctrl+Alt+D’.

11. Running the Power Demo (Laptop Terminals without recommended DP Monitor):
Power Advantage Tool GUI



At this point follow instructions from Zynq UltraScale+ MPSoC Power Advantage Tool 2017.1 to run different applications and observe Power readings on the Power Advantage tool.

What you will observe


Power Advantage Tool Demo



Telnet based games where display is not available and what to check the Power consumption for complex games


Appendix A: Flashing the MSP430


MSP430 Flashing: If you have received new demo software for an existing ZCU102 board, you may need to flash the onboard MSP430 to enable new features

Attach the MSP-FET Flash Emulation Tool to USB and ZCU102 J92 (Near the power switch).
MSP430 Programmer

Appendix B : Steps to build Linux Images

Download Linux Project

Download Reference Design Zip Files ZCU102 rev 1.0 or rev D2 / production silicon from Zynq UltraScale MPSoC Base TRD 2017.1, to your local Linux machine and follow below steps:

Configure PetaLinux Project


$ cd rdf0421-zcu102-base-trd-2017-1/apu/petalinux_bsp
c:\zynqus\pwr\sw\pl_lib_wrapper.hdf
$ petalinux-config -get-hw-description=<path for pl_lib_wrapper.hdf>

Image Packaging Configuration > Root filesystem type (SD card) > SD card

Device Tree Settings

Set the device-tree file by using the same device tree setting from design module 6 reference design
$ cd project-spec/meta-user/recipes-bsp/device-tree/files
$ cp zcu102-base-dm6.dtsi system-user.dtsi
$ cd project-spec/meta-user/recipes-bsp/device-tree/files
bootargs = "earlycon clk_ignore_unused earlyprintk uio_pdrv_genirq.of_id=xlnx,generic-uio root=/dev/mmcblk0p2 rw rootwait cma=1024M";

Kernel Configuration


$ cd rdf0421-zcu102-base-trd-2017-1/apu/petalinux_bsp


$ petalinux-config -c kernel

General setup > Initial RAM file system and RAM disk (initramfs/initrd) support
Multimedia and USB related settings
Device Drivers->Input device support->Event interface
Device Drivers->Input device support->Keyboards
Device Drivers->Input device support->Mouse interface
Device Drivers->Multimedia support->Media USB Adapters->USB Video Class (UVC)
Device Drivers->Multimedia support->Cameras/video grabbers support
Device Drivers->Multimedia support->V4L platform devices
Device Drivers->USB support and enable all required classes
Device Drivers->HID support->Generic HID driver
Device Drivers->HID support->USB HID support->USB HID transport layer
Disabling the PMBUS PMIC so that power demo can use them without any issues
Device Drivers->Hardware Monitoring support->PMBus support->Maxim MAX20751
Enable the PHY settings
Device Drivers->PHY Subsystem
Device Drivers->PHY Subsystem->Xilinx ZynqMP PHY driver
Disable the PCI settings
Bus Support->PCI support’ This needs to be disabled for this version
Enable the sound related settings
Device Drivers->Sound card support’
Device Drivers->Sound card support->Advanced Linux Sound Architecture’ enabling ALSA support
Kernel hacking > Tracers > Kernel Function Tracer

Rootfs Configuration
Petalinux-config -c rootfs
Filesystem Packages --->libs ---> libmali-xlnx
[*] libmali-xlnx
[*] libmali-xlnx-dbg
[*] libmali-xlnx-dev

Build Image

$ petalinux-build


$ <petalinux_bsp_path>/images/Linux/

to PetaLinux Project petalinux_bsp/images/Linux directory
Boot_image:
{
[pmufw_image] pmufw.elf
[destination_cpu=a53-0, bootloader] zynqmp_fsbl.elf
[destination_device=pl] pl_lib_wrapper.bit
[destination_cpu=a53-0, exception_level=el-3, trustzone] bl31.elf
[destination_cpu=r5-lockstep] r5.elf
[destination_cpu=a53-0, exception_level=el-2] u-boot.elf
}
$ cd images/Linux
$ petalinux-package --boot --bif=boot_image.bif --force