# PYNQ 2.7 custom board building error

**URL:** https://discuss.pynq.io/t/pynq-2-7-custom-board-building-error/4649
**Category:** Support
**Created:** [September 10, 2022, 1:55am UTC](https://discuss.pynq.io/t/pynq-2-7-custom-board-building-error/4649 "2022-09-10T01:55:11Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![HIBER](https://avatars.discourse-cdn.com/v4/letter/h/e79b87/32.png) [@HIBER](https://discuss.pynq.io/u/HIBER)
#### Post date: [September 10, 2022, 1:55am UTC](https://discuss.pynq.io/t/pynq-2-7-custom-board-building-error/4649/1 "2022-09-10T01:55:11Z")

</div>

Hi，I have a zynq7020 board, having different clk and DDR with official board. So I want to build my own PYNQ image.  
I devide it in two steps:  
1、Build PYNQ-Z2 image to verify my environment is complete.  
2、Modify clk and DDR in PYNQ-Z2 with vivado,then generate tcl and rebuild image.

However, I failed in the first step and cannot solve it for several weeks. I will very appreciate it if someone help me.

my environment lists as follows:  
VM ubuntu18.4 from vagrantfile;  
PYNQ 2.7( Cloned from PYNQ repo (latest master));  
ran setup\_host.sh script;  
installed vitis 2020.2 and petalinux 2020.2, and set up the environment variables.

I ran the following cmd in sdbuild dir.  
make BOARDS=Pynq-Z2 PREBUILT=/pynq/focal.arm.2.7.0\_2021\_11\_17.tar.gz

```auto
INFO: [Memdata 28-167] Found XPM memory block base_i/iop_pmod0/spi/U0/NO_DUAL_QUAD_MODE.QSPI_NORMAL/QSPI_LEGACY_MD_GEN.QSPI_CORE_INTERFACE_I/FIFO_EXISTS.RX_FIFO_II/gnuram_async_fifo.xpm_fifo_base_inst/gen_sdpram.xpm_memory_base_inst with a P_MEMORY_PRIMITIVE property set to auto. A value of block is required. You will not be able to use the updatemem program to update the bitstream with new data for the base_i/iop_pmod0/spi/U0/NO_DUAL_QUAD_MODE.QSPI_NORMAL/QSPI_LEGACY_MD_GEN.QSPI_CORE_INTERFACE_I/FIFO_EXISTS.RX_FIFO_II/gnuram_async_fifo.xpm_fifo_base_inst/gen_sdpram.xpm_memory_base_inst block.
Command: write_bitstream -force base_wrapper.bit
Attempting to get a license for feature 'Implementation' and/or device 'xczu7ev'
INFO: [Common 17-349] Got license for feature 'Implementation' and/or device 'xczu7ev'
INFO: [Common 17-83] Releasing license: Implementation
41 Infos, 0 Warnings, 0 Critical Warnings and 1 Errors encountered.
write_bitstream failed
ERROR: [Common 17-69] Command failed: This design contains one or more cells for which bitstream generation is not permitted:
base_i/video/hdmi_out/frontend/inst/v_hdmi_tx/inst (<encrypted cellview>)
base_i/video/hdmi_in/frontend/inst/v_hdmi_rx/inst (<encrypted cellview>)
If a new IP Core license was added, in order for the new license to be picked up, the current netlist needs to be updated by resetting and re-generating the IP output products before bitstream generation.
INFO: [Common 17-206] Exiting Vivado at Thu Sep 8 23:21:17 2022...
[Thu Sep 8 23:21:18 2022] impl_1 finished
WARNING: [Vivado 12-8222] Failed run(s) : 'impl_1'
wait_on_run: Time (s): cpu = 03:09:25 ; elapsed = 01:29:04 . Memory (MB): peak = 4545.023 ; gain = 0.000 ; free physical = 4524 ; free virtual = 8832
INFO: [Vivado 12-4895] Creating Hardware Platform: /workspace/PYNQ/sdbuild/build/PYNQ/boards/ZCU104/base/base.xsa ...
INFO: [Hsi 55-2053] elapsed time for repository (/workspace/Vivado/2020.2/data/embeddedsw) loading 0 seconds
WARNING: [BD 41-2589] Platform should have atleast one axi memory mapped master interface. Enable a master AXI interface as platform AXI_PORT.
INFO: [Project 1-1042] Successfully generated hpfm file
write_project_tcl: Time (s): cpu = 00:09:34 ; elapsed = 00:06:15 . Memory (MB): peak = 4545.023 ; gain = 0.000 ; free physical = 7553 ; free virtual = 12594
ERROR: [Common 17-70] Application Exception: Need an implemented design open to write bitstream. Aborting write_hw_platform..
INFO: [Common 17-206] Exiting Vivado at Thu Sep 8 23:27:47 2022...
makefile:16: recipe for target 'bitstream' failed
make[1]: *** [bitstream] Error 1
make[1]: Leaving directory '/workspace/PYNQ/sdbuild/build/PYNQ/boards/ZCU104/base'
+ unmount_special
+ for fs in $fss
+ sudo umount -l /workspace/PYNQ/sdbuild/build/focal.Pynq-Z2/proc
+ for fs in $fss
+ sudo umount -l /workspace/PYNQ/sdbuild/build/focal.Pynq-Z2/run
+ for fs in $fss
+ sudo umount -l /workspace/PYNQ/sdbuild/build/focal.Pynq-Z2/dev
+ sudo umount -l /workspace/PYNQ/sdbuild/build/focal.Pynq-Z2/ccache
+ rmdir /workspace/PYNQ/sdbuild/build/focal.Pynq-Z2/ccache
Makefile:343: recipe for target '/workspace/PYNQ/sdbuild/build/Pynq-Z2.tar.gz' failed
make: *** [/workspace/PYNQ/sdbuild/build/Pynq-Z2.tar.gz] Error 2
type or paste code here

```

It seems I don’t have licenses to build ZCU104. But question is I only want to build Pynq-Z2. How can I only build the specified board or get license for ZCU104?  
Furthermore, if I want to build my own board image. regenerate tcl file can make it?  
thanks for your time.

---

<div class="post-metadata">

### Author: ![briansune](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.pynq.io/briansune/32/3087_2.png) [@briansune](https://discuss.pynq.io/u/briansune)
#### Post date: [September 10, 2022, 3:29am UTC](https://discuss.pynq.io/t/pynq-2-7-custom-board-building-error/4649/2 "2022-09-10T03:29:37Z")

</div>

For the license part there are nothing we can do to help as this is a must to use high-density series FPGA  
on Xilinx.

However, the building part I can help, vargrant is a really unpredicted method!  
Here is a welly known method that stable enough for others to follow and repeat without major hazard:

Follow this link for build command usage:  
[https://pynq.readthedocs.io/en/latest/pynq\_sd\_card.html](https://pynq.readthedocs.io/en/latest/pynq_sd_card.html)

Follow this link for setting up the build environment:

> [@Stuck at extract yocoto](https://discuss.pynq.io/t/stuck-at-extract-yocoto/4134/8):
>
> Unless people having hard time on setting up the environment: Vagrant is not a good method to setup the SD build environment. I have not investigate to the bottom but what previous engineer shows there might Virtual R/W issue during such setup. STEPS: I will suggest download 18.04.06 LTS Ubuntu from official website Create a virtual disk size about 200GB or more, set the CPU \>#4, RAM \>#8192 Update Ubuntu packages before setting up the PYNQ 3b) Git clone the PYNQ to /home//PYNQ 3c) sudo ch…

Follow this link to see what need to pay attention during Ultra-Scale series ZYNQ build:

> [@UltraZYNQ+ Build](https://discuss.pynq.io/t/ultrazynq-build/4404/4):
>
> Problem solve: Indeed the boot arg is not default edited by the make script on the PYNQ. I not even notice this is the case as once it stuck I had no idea how I can get the log why and what reason it is stucking. Maybe Sarunas you can advise a bit how we can debug the root cause it is stuck. Starting Samba NMB Daemon... Starting OpenBSD Secure Shell server... Starting Permit User Sessions... [OK] Started Unattended Upgrades Shutdown. [OK] Finished Permit U…

Remember read the post completely and understand before you execute each part.

Enjoy ~

---

<div class="post-metadata">

### Author: ![HIBER](https://avatars.discourse-cdn.com/v4/letter/h/e79b87/32.png) [@HIBER](https://discuss.pynq.io/u/HIBER)
#### Post date: [September 10, 2022, 4:00am UTC](https://discuss.pynq.io/t/pynq-2-7-custom-board-building-error/4649/3 "2022-09-10T04:00:39Z")

</div>

> [@Stuck at extract yocoto](https://discuss.pynq.io/t/stuck-at-extract-yocoto/4134/8):
>
> python3 -m pip install --upgrade pip

Thanks for your reply.  
I am sorry, but it did not solve my problem. Actually, I have licenses to build pynq-Z2. it can generate pynq-Z2 bit successfully in vivado. I just can’t understand why it need licenses for ZCU104 when I use cmd : make BOARDS=Pynq-Z2 PREBUILT=/pynq/focal.arm.2.7.0\_2021\_11\_17.tar.gz.  
Can you tell me how to skip ZCU104 building process. Because I only want to generate pynq-Z2 now.

---

<div class="post-metadata">

### Author: ![briansune](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.pynq.io/briansune/32/3087_2.png) [@briansune](https://discuss.pynq.io/u/briansune)
#### Post date: [September 10, 2022, 5:18am UTC](https://discuss.pynq.io/t/pynq-2-7-custom-board-building-error/4649/4 "2022-09-10T05:18:45Z")

</div>

Modify the build.sh and remove line as this suggested  
Meantime, did you include the HDMI IP license for limited time period usage?

> [@Pynq 2.7 for Zybo-Z7](https://discuss.pynq.io/t/pynq-2-7-for-zybo-z7/4124):
>
> Hi everyone, I hope you’re okay. I was following this [post](https://discuss.pynq.io/t/quick-porting-of-pynq-using-pre-built-images/1075) by PeterOgden to create a Pynq 2.7 image for Zybo-Z7 and thought in sharing my experience. The files used in the process can be found here: [Zybo-Z7 files](https://gitlab.com/dorfell/fer_sys_dev/-/tree/master/01_hw/Pynq_Zybo-Z7). [Pynq 2.7 for Zybo-Z7 image](https://drive.google.com/file/d/1kCT_UZjIuDym3yhI739xY1OY1Q4byCHx/view?usp=sharing). [Demostration video.](https://www.youtube.com/watch?v=a1FPf9TzUzs) For those interested in recreating the image you can follow these stages. 1. Create the Board Support Package (BSP) (30 min approx.) Although the Pynq-Z2 and the Zybo-Z7 have the same FPGA (i.e. xc7Z020-clg400), they present some…

---

<div class="post-metadata">

### Author: ![HIBER](https://avatars.discourse-cdn.com/v4/letter/h/e79b87/32.png) [@HIBER](https://discuss.pynq.io/u/HIBER)
#### Post date: [October 1, 2022, 5:29am UTC](https://discuss.pynq.io/t/pynq-2-7-custom-board-building-error/4649/5 "2022-10-01T05:29:29Z")

</div>

I did’t have HDMI IP license. When I followed the post you shared me, I generated the image for my board. Although encountered some difficulties in this process, but now I can log in my pynq finally. Thank you very much.

I want to record the problem I met when I generated the image earlier. when I finished generating the image in the first time. I found it can’t connect to Ethernet. this bothered me for days. In the finally, I found the petalinux project setting the phy address to “1”. Then I checked my own board, phy address was zero, as the picture shows.

 ![image](https://us1.discourse-cdn.com/flex019/uploads/pynq1/original/2X/4/41ae1e76d113bbef420a7caef9940b8aaaa9ba36.png)  
So I changed the petalinux project device tree source file(petalinux\_project\project-spec\meta-user\recipes-bsp\device-tree\files\system-user.dtsi). then I regenerated the dtb, BOOT.bin and ubuntu image. Now, I can connect to my pynq. I am so excited.  
 ![image](https://us1.discourse-cdn.com/flex019/uploads/pynq1/original/2X/6/6e7b4cd3348fa6fac95e943f813a11a77c4dd1f3.png)

Finally, I want to thank you for your help again!

---

<div class="post-metadata">

### Author: ![briansune](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.pynq.io/briansune/32/3087_2.png) [@briansune](https://discuss.pynq.io/u/briansune)
#### Post date: [October 1, 2022, 7:02am UTC](https://discuss.pynq.io/t/pynq-2-7-custom-board-building-error/4649/6 "2022-10-01T07:02:51Z")

</div>

You can make a remainders about HDMI and device-tree to this issue:  
It will be appreciate and provide better build flow to the community.

Enjoy~ =]
