Hi, I’m trying to create PYNQ bsp for Minized.
I have created system with fpga manager, jupyter notebook, pynq packages.
But if I’m trying to import PYNQ Im getting this message:
/usr/lib/python3.5/site-packages/pynq/lib/video/init.py in
38 from . import clocks
39
—> 40 if pynq.ps.CPU_ARCH == pynq.ps.ZYNQ_ARCH:
41 from . import dvi
42 elif pynq.ps.CPU_ARCH == pynq.ps.ZU_ARCH:
AttributeError: module ‘pynq’ has no attribute ‘ps’
Is this error connected with Minized not containing any video output?
How can I fix those errors? I’m missing some library?
Thanks for help
So I’ve just removed this line and dvi library.
Now PYNQ throws “ConnectionError: Could not connect to PL server” Isn’t fpga manager PL-server for PYNQ?
The PL server is a separate process which would normally be started by init. Given the errors you are seeing it’s likely that the server failed to start. You can run start_pl_server.py &
on the console to start it manually.
I’m a bit worried by the error messages you are seeing - that shouldn’t be happening and indicates some form of circular inclusion on our part. I don’t know why this would be an issue for the minized. If you get a finish your BSP would you be willing to share it so I can try and get to the root of the issue?
Peter
1 Like
Hi,
I have tried using start_pl_server.py, here is output:
start_pl_server.py
start_pl_server.py
sr/lib/python3.5/site-packages/pkg_resources/init.py", line 479, in load_entry_point
return get_distribution(dist).load_entry_point(group, name)
File “/usr/lib/python3.5/site-packages/pkg_resources/init.py”, line 2703, in load_entry_point
return ep.load()
File “/usr/lib/python3.5/site-packages/pkg_resources/init.py”, line 2321, in load
return self.resolve()
File “/usr/lib/python3.5/site-packages/pkg_resources/init.py”, line 2327, in resolve
module = import(self.module_name, fromlist=[‘name’], level=0)
File “/usr/lib/python3.5/site-packages/pynq/init.py”, line 47, in
from . import lib
File “/usr/lib/python3.5/site-packages/pynq/lib/init.py”, line 74, in
from . import video
File “/usr/lib/python3.5/site-packages/pynq/lib/video/init.py”, line 41, in
from . import dvi
File “/usr/lib/python3.5/site-packages/pynq/lib/video/dvi.py”, line 41, in
import pynq.lib._video
ImportError: No module named ‘pynq.lib._video’
MinizedBSP.bsp (2.5 MB)
This is output from fresh install.
Now I’m trying to get latest pynq and pandas from pypi, because petalinux 2019.2 have 2.4 pynq version included in meta-pynq which is outdated.
I will try to one more time after update finishes.
The start_pl_server.py
script is designed to run forever - hence why we aim to start it at boot.
If you run it in the background with
start_pl_server.py &
Does that make the core PYNQ library function correctly?
Okay, its seems to work after updating to version 2.5.4.
I can’t test it properly for now because while creating new overlay my wifi and mmc driver freak out so I’m losing wifi connection.
I will make some tests after I get over this issue.
PS1. Is there any petalinux recipe for 2.5.4 version?
Installing new pynq version via pip3 in minized is pain.
PS2. How can I create HWH file? Right now Im using TCL and Bitstream?
Petalinux 2020.1 has 2.5.1 in it which (for Z|YNQ) should be functionally identical to 2.5.4. The updated recipes are here and should be portable to 2019.2 if it’s important for you to stick with the old version.
Peter
1 Like
Thanks for help with PYNQ!
Sadly 2.5.1 doesn’t work out of box :
DEBUG: Executing python function sstate_task_prefunc
DEBUG: Python function sstate_task_prefunc finished
DEBUG: Executing python function extend_recipe_sysroot
NOTE: Direct dependencies are [‘/home/bartek/petalinux20192/components/yocto/source/arm/layers/core/meta/recipes-devtools/binutils/binutils-cross_2.31.bb:do_populate_sysroot’, ‘virtual:native:/home/bartek/petalinux20192/components/yocto/source/arm/layers/core/meta/recipes-devtools/pseudo/pseudo_git.bb:do_populate_sysroot’]
NOTE: Installed into sysroot:
NOTE: Skipping as already exists in sysroot: [‘binutils-cross-arm’, ‘pseudo-native’, ‘quilt-native’, ‘texinfo-dummy-native’, ‘flex-native’, ‘autoconf-native’, ‘zlib-native’, ‘gnu-config-native’, ‘gettext-minimal-native’, ‘libtool-native’, ‘automake-native’, ‘m4-native’, ‘xz-native’]
DEBUG: Python function extend_recipe_sysroot finished
DEBUG: Executing python function do_package_qa
NOTE: DO PACKAGE QA
DEBUG: Executing python function read_subpackage_metadata
DEBUG: Python function read_subpackage_metadata finished
NOTE: Checking Package: python3-pynq-dbg
NOTE: Checking Package: python3-pynq-dev
NOTE: Checking Package: python3-pynq-lic
NOTE: Checking Package: python3-pynq-doc
NOTE: Checking Package: python3-pynq-locale
NOTE: Checking Package: python3-pynq-staticdev
NOTE: Checking Package: python3-pynq-notebooks
NOTE: Checking Package: python3-pynq
ERROR: QA Issue: non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/pmod/bsp_iop_pmod/iop_pmoda_mb/lib/libc.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/pmod/bsp_iop_pmod/iop_pmoda_mb/lib/libgloss.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/pmod/bsp_iop_pmod/iop_pmoda_mb/lib/libgcc.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/pmod/bsp_iop_pmod/iop_pmoda_mb/lib/libxil.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/pmod/bsp_iop_pmod/iop_pmoda_mb/lib/libm.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/rpi/bsp_iop_rpi/iop_rpi_mb/lib/libc.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/rpi/bsp_iop_rpi/iop_rpi_mb/lib/libgloss.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/rpi/bsp_iop_rpi/iop_rpi_mb/lib/libgcc.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/rpi/bsp_iop_rpi/iop_rpi_mb/lib/libxil.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/rpi/bsp_iop_rpi/iop_rpi_mb/lib/libm.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/arduino/bsp_iop_arduino/iop_arduino_mb/lib/libc.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/arduino/bsp_iop_arduino/iop_arduino_mb/lib/libgloss.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/arduino/bsp_iop_arduino/iop_arduino_mb/lib/libgcc.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/arduino/bsp_iop_arduino/iop_arduino_mb/lib/libxil.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/arduino/bsp_iop_arduino/iop_arduino_mb/lib/libm.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/logictools/bsp_lcp_ar_mb/lcp_ar_mb/lib/libc.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/logictools/bsp_lcp_ar_mb/lcp_ar_mb/lib/libgloss.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/logictools/bsp_lcp_ar_mb/lcp_ar_mb/lib/libgcc.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/logictools/bsp_lcp_ar_mb/lcp_ar_mb/lib/libxil.a’
non -staticdev package contains static .a library: python3-pynq path ‘/work/cortexa9t2hf-neon-xilinx-linux-gnueabi/python3-pynq/2.5.1-r0/packages-split/python3-pynq/usr/lib/python3.5/site-packages/pynq/lib/logictools/bsp_lcp_ar_mb/lcp_ar_mb/lib/libm.a’ [staticdev]
ERROR: QA run found fatal errors. Please consider fixing them.
DEBUG: Python function do_package_qa finished
ERROR: Function failed: do_package_qa
I have created pynq based on Xilinx PYNQ from github, not via raw petalinux. Now it is working.