用过的ZYNQ开发板有PYNQ-Z1,PYNQ-Z2,ZC702,MiniZed,ZCU102,ZCU104还有本篇文章的主角——Ultra96,在这些开发板里我最喜欢的就是这块Ultra96。
第一次拿到Ultra96的时候惊为天人,跟银行卡一样大的板卡竟然放下了Xilinx最先进的MPSoC(准确的说第二先进,毕竟7nm的ACAP已经发布了),Ultra96搭载的xczu3eg提供了大约7020 2倍的逻辑资源
Name | BRAM_18K | DSP48E | FF | LUT |
---|---|---|---|---|
Available | 432 | 360 | 141120 | 70560 |
Ultra96接口一应俱全,最让我感动的就是有两个USB-A的USB3.0接口,简直感动哭了,像ZCU102这种巨大的板子竟然只放了一个MicroUSB3.0,ZCU104也只放了一个USB-A,不管做啥必须得用USB-HUB。还有一个miniDP,这个DP接口是PS引出来的,只要在内核里配置好就能用,不像ZYNQ7000系列必须要消耗一些逻辑资源才能实现显示输出。
此外,Ultra96是按照96Boards的标准设计的,拥有非常丰富的外设,绿色的那块扩展板就是用来外接传感器的。
当然Ultra96也有一些缺点,
1、板卡上没有USB转UART,必须依赖扩展板才能实现
2、电源接口奇葩,4.7mm的,常见的都是5.5mm,买配件花了一番功夫
3、没有有线网口,但是有无线网,但终究不如有线网口方便
AVNET家的板子给我的感觉就是设计精巧,布线紧凑,很有设计感,比如MiniZed。
Digilent家的开发板因为大多数是评估板,所以把大部分外设都引了出来,板卡体积巨大!不过也有设计得比较小巧的板子比如ZCU104。
我用过的板子里设计得最差的就是TUL家的PYNQ-Z2,至少有一半的空间被浪费了。
先上几张图,拍照技术不太好(主要是想秀一下Leica标,毕竟现在已经是尊贵的爵士了)
PYNQ框架好处都有啥?
前面的文章介绍过如何给zcu102搭建带xfce4桌面的SDSoC Platform,
https://blog.csdn.net/lulugay/article/details/83277270
本工程的实现思路与之前zcu102的大体一致,但是有一些实现的细节有所区别,最开始完全按照zcu102的流程搭建SDSoC Platform遇到了很多坑,在此记录一下。
本文的plnx工程已经上传到github
https://github.com/jiangwx/Petalinux/tree/master/ultra96
做好的工程在
https://download.csdn.net/download/lulugay/10761826
clk_wiz_0的输出时钟频率设置为75,100,150,200,300,400,600M
!!!注意,UART1设置为EMIO,需要添加引脚约束
set_property IOSTANDARD LVCMOS18 [get_ports UART*]
#HD_GPIO_5 on FPGA / Connector pin 13 / UART1_rxd
set_property PACKAGE_PIN G5 [get_ports UART1_rxd]
#HD_GPIO_4 on FPGA / Connector pin 11 / UART1_txd
set_property PACKAGE_PIN F6 [get_ports UART1_txd]
在Tcl中输入
set_property PFM_NAME "em.avnet.com:ultra96:ultra96:1.0" [get_files design_1.bd]
set_property PFM.CLOCK { \
clk_out1 {id "0" is_default "false" proc_sys_reset "proc_sys_reset_0" } \
clk_out2 {id "1" is_default "false" proc_sys_reset "proc_sys_reset_1" } \
clk_out3 {id "2" is_default "false" proc_sys_reset "proc_sys_reset_2" } \
clk_out4 {id "3" is_default "true" proc_sys_reset "proc_sys_reset_3" } \
clk_out5 {id "4" is_default "false" proc_sys_reset "proc_sys_reset_4" } \
clk_out6 {id "5" is_default "false" proc_sys_reset "proc_sys_reset_5" } \
clk_out7 {id "6" is_default "false" proc_sys_reset "proc_sys_reset_6" } \
} [get_bd_cells /clk_wiz_0]
set_property PFM.AXI_PORT { \
M_AXI_HPM0_FPD {memport "M_AXI_GP"} \
M_AXI_HPM1_FPD {memport "M_AXI_GP"} \
M_AXI_HPM0_LPD {memport "M_AXI_GP"} \
S_AXI_HPC0_FPD {memport "S_AXI_HPC" sptag "HPC0" memory "ps_e HPC0_DDR_LOW"} \
S_AXI_HPC1_FPD {memport "S_AXI_HPC" sptag "HPC1" memory "ps_e HPC1_DDR_LOW"} \
S_AXI_HP0_FPD {memport "S_AXI_HP" sptag "HP0" memory "ps_e HP0_DDR_LOW"} \
S_AXI_HP1_FPD {memport "S_AXI_HP" sptag "HP1" memory "ps_e HP1_DDR_LOW"} \
S_AXI_HP2_FPD {memport "S_AXI_HP" sptag "HP2" memory "ps_e HP2_DDR_LOW"} \
S_AXI_HP3_FPD {memport "S_AXI_HP" sptag "HP3" memory "ps_e HP3_DDR_LOW"} \
} [get_bd_cells /ps_e]
set intVar []
for {set i 0} {$i < 8} {incr i} {
lappend intVar In$i {}
}
set_property PFM.IRQ $intVar [get_bd_cells /xlconcat_0]
set_property PFM.IRQ $intVar [get_bd_cells /xlconcat_1]
注意get_bd_cells/后面的名称要与BD中的名称对应
write_dsa -force /ultra96.dsa -include_bit
validate_dsa /ultra96.dsa
$ petalinux-create -t project -s xilinx-ultra96-reva-v2018.2-final.bsp -n ultra96
一定要使用bsp文件创建工程
$ cd ultra96/
将刚才生成的dsa或hdf文件复制到该目录下
$ petalinux-config --get-hw-description ./
导入硬件工程,此时会弹出设置界面
earlycon clk_ignore_unused earlyprintk root=/dev/mmcblk0p2 rw rootwait cma=1024M
在zcu102有如下步骤
Image Packaging Configurations->Root filesystem type->SD card,但是ultra96的bsp默认就是从SD卡启动
$ petalinux-config -c kernel
配置完成后退出,可以在配置文件 /project-spec/metauser/recipes-kernel/linux/linux-xlnx/xxx.cfg中看到
# CONFIG_BLK_DEV_INITRD is not set
# CONFIG_CPU_IDLE is not set
# CONFIG_CPU_FREQ is not set
# CONFIG_CPU_FREQ_DEFAULT_GOV_USERSPACE is not set
CONFIG_CMA_SIZE_MBYTES=1024
CONFIG_EDAC_CORTEX_ARM64=y
CONFIG_XILINX_APF=y
CONFIG_XILINX_DMA_APF=y
这里与配置zcu102的内核有一个很明显的区别,zcu102的bsp已经配置好了USB相关驱动,但是Ultra96需要我们手动添加。Ultra96没有有线网口,想用UART还要转接板,因此必须要配置USB相关驱动才能用USB转网口。
在
# CAN USB interfaces
# CONFIG_CAN_EMS_USB is not set
# CONFIG_CAN_ESD_USB2 is not set
# CONFIG_CAN_GS_USB is not set
# CONFIG_CAN_KVASER_USB is not set
# CONFIG_CAN_PEAK_USB is not set
# CONFIG_CAN_8DEV_USB is not set
# CONFIG_CAN_MCBA_USB is not set
CONFIG_BT_HCIBTUSB=y
CONFIG_BT_HCIBTUSB_BCM=y
CONFIG_BT_HCIBTUSB_RTL=y
CONFIG_BT_HCIBFUSB=y
# CONFIG_USB_SWITCH_FSA9480 is not set
CONFIG_USB_NET_DRIVERS=y
CONFIG_USB_CATC=m
CONFIG_USB_KAWETH=m
CONFIG_USB_PEGASUS=m
CONFIG_USB_RTL8150=m
CONFIG_USB_RTL8152=m
CONFIG_USB_LAN78XX=m
CONFIG_USB_USBNET=m
CONFIG_USB_NET_AX8817X=m
CONFIG_USB_NET_AX88179_178A=m
CONFIG_USB_NET_CDCETHER=m
CONFIG_USB_NET_CDC_EEM=m
CONFIG_USB_NET_CDC_NCM=m
CONFIG_USB_NET_HUAWEI_CDC_NCM=m
CONFIG_USB_NET_CDC_MBIM=m
CONFIG_USB_NET_DM9601=m
CONFIG_USB_NET_SR9700=m
CONFIG_USB_NET_SR9800=m
CONFIG_USB_NET_SMSC75XX=m
CONFIG_USB_NET_SMSC95XX=m
CONFIG_USB_NET_GL620A=m
CONFIG_USB_NET_NET1080=m
CONFIG_USB_NET_PLUSB=m
CONFIG_USB_NET_MCS7830=m
CONFIG_USB_NET_RNDIS_HOST=m
CONFIG_USB_NET_CDC_SUBSET_ENABLE=m
CONFIG_USB_NET_CDC_SUBSET=m
# CONFIG_USB_ALI_M5632 is not set
# CONFIG_USB_AN2720 is not set
CONFIG_USB_BELKIN=y
CONFIG_USB_ARMLINUX=y
# CONFIG_USB_EPSON2888 is not set
# CONFIG_USB_KC2190 is not set
CONFIG_USB_NET_ZAURUS=m
CONFIG_USB_NET_CX82310_ETH=m
CONFIG_USB_NET_KALMIA=m
CONFIG_USB_NET_QMI_WWAN=m
# CONFIG_USB_HSO is not set
CONFIG_USB_NET_INT51X1=m
CONFIG_USB_IPHETH=m
CONFIG_USB_SIERRA_NET=m
CONFIG_USB_VL600=m
CONFIG_USB_NET_CH9200=m
# CONFIG_AT76C50X_USB is not set
CONFIG_BRCMFMAC_USB=y
# CONFIG_RT2500USB is not set
# CONFIG_RT73USB is not set
CONFIG_RT2800USB=m
CONFIG_RT2800USB_RT33XX=y
CONFIG_RT2800USB_RT35XX=y
CONFIG_RT2800USB_RT3573=y
CONFIG_RT2800USB_RT53XX=y
CONFIG_RT2800USB_RT55XX=y
CONFIG_RT2800USB_UNKNOWN=y
CONFIG_RT2X00_LIB_USB=m
# CONFIG_USB_ZD1201 is not set
CONFIG_USB_NET_RNDIS_WLAN=m
# CONFIG_MOUSE_SYNAPTICS_USB is not set
# CONFIG_I2C_TINY_USB is not set
# USB GPIO expanders
# USB-based Watchdog Cards
# CONFIG_USBPCWATCHDOG is not set
# CONFIG_MFD_RTSX_USB is not set
CONFIG_MEDIA_USB_SUPPORT=y
CONFIG_USB_VIDEO_CLASS=m
CONFIG_USB_VIDEO_CLASS_INPUT_EVDEV=y
CONFIG_USB_GSPCA=m
# CONFIG_USB_M5602 is not set
# CONFIG_USB_STV06XX is not set
# CONFIG_USB_GL860 is not set
# CONFIG_USB_GSPCA_BENQ is not set
# CONFIG_USB_GSPCA_CONEX is not set
# CONFIG_USB_GSPCA_CPIA1 is not set
# CONFIG_USB_GSPCA_DTCS033 is not set
# CONFIG_USB_GSPCA_ETOMS is not set
# CONFIG_USB_GSPCA_FINEPIX is not set
# CONFIG_USB_GSPCA_JEILINJ is not set
# CONFIG_USB_GSPCA_JL2005BCD is not set
# CONFIG_USB_GSPCA_KINECT is not set
# CONFIG_USB_GSPCA_KONICA is not set
# CONFIG_USB_GSPCA_MARS is not set
# CONFIG_USB_GSPCA_MR97310A is not set
# CONFIG_USB_GSPCA_NW80X is not set
# CONFIG_USB_GSPCA_OV519 is not set
# CONFIG_USB_GSPCA_OV534 is not set
# CONFIG_USB_GSPCA_OV534_9 is not set
# CONFIG_USB_GSPCA_PAC207 is not set
# CONFIG_USB_GSPCA_PAC7302 is not set
# CONFIG_USB_GSPCA_PAC7311 is not set
# CONFIG_USB_GSPCA_SE401 is not set
# CONFIG_USB_GSPCA_SN9C2028 is not set
# CONFIG_USB_GSPCA_SN9C20X is not set
# CONFIG_USB_GSPCA_SONIXB is not set
# CONFIG_USB_GSPCA_SONIXJ is not set
# CONFIG_USB_GSPCA_SPCA500 is not set
# CONFIG_USB_GSPCA_SPCA501 is not set
# CONFIG_USB_GSPCA_SPCA505 is not set
# CONFIG_USB_GSPCA_SPCA506 is not set
# CONFIG_USB_GSPCA_SPCA508 is not set
# CONFIG_USB_GSPCA_SPCA561 is not set
# CONFIG_USB_GSPCA_SPCA1528 is not set
# CONFIG_USB_GSPCA_SQ905 is not set
# CONFIG_USB_GSPCA_SQ905C is not set
# CONFIG_USB_GSPCA_SQ930X is not set
# CONFIG_USB_GSPCA_STK014 is not set
# CONFIG_USB_GSPCA_STK1135 is not set
# CONFIG_USB_GSPCA_STV0680 is not set
# CONFIG_USB_GSPCA_SUNPLUS is not set
# CONFIG_USB_GSPCA_T613 is not set
# CONFIG_USB_GSPCA_TOPRO is not set
# CONFIG_USB_GSPCA_TOUPTEK is not set
# CONFIG_USB_GSPCA_TV8532 is not set
# CONFIG_USB_GSPCA_VC032X is not set
# CONFIG_USB_GSPCA_VICAM is not set
# CONFIG_USB_GSPCA_XIRLINK_CIT is not set
# CONFIG_USB_GSPCA_ZC3XX is not set
CONFIG_USB_PWC=m
# CONFIG_USB_PWC_DEBUG is not set
CONFIG_USB_PWC_INPUT_EVDEV=y
CONFIG_USB_ZR364XX=m
CONFIG_USB_STKWEBCAM=m
CONFIG_USB_S2255=m
CONFIG_VIDEO_USBTV=m
# Webcam, TV (analog/digital) USB devices
CONFIG_SND_USB=y
# CONFIG_SND_USB_AUDIO is not set
# CONFIG_SND_USB_UA101 is not set
# CONFIG_SND_USB_CAIAQ is not set
# CONFIG_SND_USB_6FIRE is not set
# CONFIG_SND_USB_HIFACE is not set
# CONFIG_SND_USB_POD is not set
# CONFIG_SND_USB_PODHD is not set
# CONFIG_SND_USB_TONEPORT is not set
# CONFIG_SND_USB_VARIAX is not set
# USB HID support
CONFIG_USB_HID=y
# CONFIG_USB_HIDDEV is not set
CONFIG_USB_OHCI_LITTLE_ENDIAN=y
CONFIG_USB_SUPPORT=y
CONFIG_USB_COMMON=y
CONFIG_USB_ARCH_HAS_HCD=y
CONFIG_USB=y
CONFIG_USB_PCI=y
CONFIG_USB_ANNOUNCE_NEW_DEVICES=y
# Miscellaneous USB options
# CONFIG_USB_DEFAULT_PERSIST is not set
# CONFIG_USB_DYNAMIC_MINORS is not set
CONFIG_USB_OTG=y
# CONFIG_USB_OTG_WHITELIST is not set
# CONFIG_USB_OTG_BLACKLIST_HUB is not set
CONFIG_USB_OTG_FSM=y
# CONFIG_USB_LEDS_TRIGGER_USBPORT is not set
# CONFIG_USB_MON is not set
# CONFIG_USB_WUSB_CBAF is not set
# USB Host Controller Drivers
# CONFIG_USB_C67X00_HCD is not set
CONFIG_USB_XHCI_HCD=y
CONFIG_USB_XHCI_PCI=y
CONFIG_USB_XHCI_PLATFORM=y
CONFIG_USB_EHCI_HCD=y
# CONFIG_USB_EHCI_ROOT_HUB_TT is not set
CONFIG_USB_EHCI_TT_NEWSCHED=y
CONFIG_USB_EHCI_PCI=y
# CONFIG_USB_EHCI_HCD_PLATFORM is not set
# CONFIG_USB_OXU210HP_HCD is not set
# CONFIG_USB_ISP116X_HCD is not set
# CONFIG_USB_ISP1362_HCD is not set
# CONFIG_USB_FOTG210_HCD is not set
# CONFIG_USB_MAX3421_HCD is not set
# CONFIG_USB_OHCI_HCD is not set
# CONFIG_USB_UHCI_HCD is not set
# CONFIG_USB_SL811_HCD is not set
# CONFIG_USB_R8A66597_HCD is not set
# CONFIG_USB_HCD_BCMA is not set
# CONFIG_USB_HCD_SSB is not set
# CONFIG_USB_HCD_TEST_MODE is not set
# USB Device Class drivers
CONFIG_USB_ACM=y
# CONFIG_USB_PRINTER is not set
CONFIG_USB_WDM=y
# CONFIG_USB_TMC is not set
# NOTE: USB_STORAGE depends on SCSI but BLK_DEV_SD may
# also be needed; see USB_STORAGE Help for more info
CONFIG_USB_STORAGE=y
# CONFIG_USB_STORAGE_DEBUG is not set
CONFIG_USB_STORAGE_REALTEK=m
CONFIG_USB_STORAGE_DATAFAB=m
CONFIG_USB_STORAGE_FREECOM=m
CONFIG_USB_STORAGE_ISD200=m
CONFIG_USB_STORAGE_USBAT=m
CONFIG_USB_STORAGE_SDDR09=m
CONFIG_USB_STORAGE_SDDR55=m
CONFIG_USB_STORAGE_JUMPSHOT=m
CONFIG_USB_STORAGE_ALAUDA=m
CONFIG_USB_STORAGE_ONETOUCH=m
CONFIG_USB_STORAGE_KARMA=m
CONFIG_USB_STORAGE_CYPRESS_ATACB=m
CONFIG_USB_STORAGE_ENE_UB6250=m
CONFIG_USB_UAS=m
# USB Imaging devices
# CONFIG_USB_MDC800 is not set
# CONFIG_USB_MICROTEK is not set
# CONFIG_USBIP_CORE is not set
# CONFIG_USB_MUSB_HDRC is not set
CONFIG_USB_DWC3=y
# CONFIG_USB_DWC3_HOST is not set
# CONFIG_USB_DWC3_GADGET is not set
CONFIG_USB_DWC3_DUAL_ROLE=y
# CONFIG_USB_DWC3_OTG is not set
CONFIG_USB_DWC3_OF_SIMPLE=y
# CONFIG_USB_DWC2 is not set
# CONFIG_USB_CHIPIDEA is not set
# CONFIG_USB_ISP1760 is not set
# USB port drivers
# CONFIG_USB_SERIAL is not set
# USB Miscellaneous drivers
# CONFIG_USB_EMI62 is not set
# CONFIG_USB_EMI26 is not set
# CONFIG_USB_ADUTUX is not set
# CONFIG_USB_SEVSEG is not set
# CONFIG_USB_RIO500 is not set
# CONFIG_USB_LEGOTOWER is not set
# CONFIG_USB_LCD is not set
# CONFIG_USB_CYPRESS_CY7C63 is not set
# CONFIG_USB_CYTHERM is not set
# CONFIG_USB_IDMOUSE is not set
# CONFIG_USB_FTDI_ELAN is not set
# CONFIG_USB_APPLEDISPLAY is not set
# CONFIG_USB_SISUSBVGA is not set
# CONFIG_USB_LD is not set
# CONFIG_USB_TRANCEVIBRATOR is not set
# CONFIG_USB_IOWARRIOR is not set
# CONFIG_USB_TEST is not set
# CONFIG_USB_EHSET_TEST_FIXTURE is not set
# CONFIG_USB_ISIGHTFW is not set
# CONFIG_USB_YUREX is not set
# CONFIG_USB_EZUSB_FX2 is not set
# CONFIG_USB_HUB_USB251XB is not set
# CONFIG_USB_HSIC_USB3503 is not set
# CONFIG_USB_HSIC_USB4604 is not set
# CONFIG_USB_LINK_LAYER_TEST is not set
# USB Physical Layer drivers
CONFIG_USB_PHY=y
# CONFIG_NOP_USB_XCEIV is not set
# CONFIG_USB_GPIO_VBUS is not set
# CONFIG_USB_ISP1301 is not set
# CONFIG_USB_ULPI is not set
CONFIG_USB_GADGET=y
# CONFIG_USB_GADGET_DEBUG is not set
# CONFIG_USB_GADGET_DEBUG_FILES is not set
# CONFIG_USB_GADGET_DEBUG_FS is not set
CONFIG_USB_GADGET_VBUS_DRAW=2
CONFIG_USB_GADGET_STORAGE_NUM_BUFFERS=2
# USB Peripheral Controller
# CONFIG_USB_FOTG210_UDC is not set
# CONFIG_USB_GR_UDC is not set
# CONFIG_USB_R8A66597 is not set
# CONFIG_USB_PXA27X is not set
# CONFIG_USB_MV_UDC is not set
# CONFIG_USB_MV_U3D is not set
# CONFIG_USB_SNP_UDC_PLAT is not set
# CONFIG_USB_M66592 is not set
# CONFIG_USB_BDC_UDC is not set
# CONFIG_USB_AMD5536UDC is not set
# CONFIG_USB_NET2272 is not set
# CONFIG_USB_NET2280 is not set
# CONFIG_USB_GOKU is not set
# CONFIG_USB_EG20T is not set
CONFIG_USB_GADGET_XILINX=y
# CONFIG_USB_DUMMY_HCD is not set
CONFIG_USB_LIBCOMPOSITE=y
CONFIG_USB_F_ACM=y
CONFIG_USB_F_SS_LB=y
CONFIG_USB_U_SERIAL=y
CONFIG_USB_U_ETHER=y
CONFIG_USB_U_AUDIO=y
CONFIG_USB_F_SERIAL=y
CONFIG_USB_F_OBEX=y
CONFIG_USB_F_NCM=y
CONFIG_USB_F_ECM=y
CONFIG_USB_F_EEM=y
CONFIG_USB_F_SUBSET=y
CONFIG_USB_F_RNDIS=y
CONFIG_USB_F_MASS_STORAGE=y
CONFIG_USB_F_FS=y
CONFIG_USB_F_UAC1=y
CONFIG_USB_F_UAC1_LEGACY=y
CONFIG_USB_F_UAC2=y
CONFIG_USB_F_UVC=y
CONFIG_USB_F_MIDI=y
CONFIG_USB_F_HID=y
CONFIG_USB_F_PRINTER=y
CONFIG_USB_CONFIGFS=y
CONFIG_USB_CONFIGFS_SERIAL=y
CONFIG_USB_CONFIGFS_ACM=y
CONFIG_USB_CONFIGFS_OBEX=y
CONFIG_USB_CONFIGFS_NCM=y
CONFIG_USB_CONFIGFS_ECM=y
CONFIG_USB_CONFIGFS_ECM_SUBSET=y
CONFIG_USB_CONFIGFS_RNDIS=y
CONFIG_USB_CONFIGFS_EEM=y
CONFIG_USB_CONFIGFS_MASS_STORAGE=y
CONFIG_USB_CONFIGFS_F_LB_SS=y
CONFIG_USB_CONFIGFS_F_FS=y
CONFIG_USB_CONFIGFS_F_UAC1=y
CONFIG_USB_CONFIGFS_F_UAC1_LEGACY=y
CONFIG_USB_CONFIGFS_F_UAC2=y
CONFIG_USB_CONFIGFS_F_MIDI=y
CONFIG_USB_CONFIGFS_F_HID=y
CONFIG_USB_CONFIGFS_F_UVC=y
CONFIG_USB_CONFIGFS_F_PRINTER=y
# CONFIG_USB_ZERO is not set
# CONFIG_USB_AUDIO is not set
# CONFIG_USB_ETH is not set
# CONFIG_USB_G_NCM is not set
CONFIG_USB_GADGETFS=y
# CONFIG_USB_FUNCTIONFS is not set
# CONFIG_USB_MASS_STORAGE is not set
# CONFIG_USB_G_SERIAL is not set
# CONFIG_USB_MIDI_GADGET is not set
# CONFIG_USB_G_PRINTER is not set
# CONFIG_USB_CDC_COMPOSITE is not set
# CONFIG_USB_G_ACM_MS is not set
# CONFIG_USB_G_MULTI is not set
# CONFIG_USB_G_HID is not set
# CONFIG_USB_G_DBGP is not set
# CONFIG_USB_G_WEBCAM is not set
# USB Power Delivery and Type-C drivers
# CONFIG_USB_LED_TRIG is not set
# CONFIG_USB_ULPI_BUS is not set
# LED driver for blink(1) USB RGB LED is under Special HID drivers (HID_THINGM)
# CONFIG_PRISM2_USB is not set
# USB Power Delivery and Type-C drivers
# CONFIG_EXTCON_USB_GPIO is not set
# CONFIG_BCM_KONA_USB2_PHY is not set
# CONFIG_PHY_PXA_28NM_USB2 is not set
# CONFIG_PHY_CPCAP_USB is not set
/include/ "system-conf.dtsi"
&amba {
xlnk {
compatible = "xlnx,xlnk-1.0";
};
};
注意,这里与zcu102也有一些区别
我们并不使用Petalinux编译出来的rootfs,但是为了加快编译速度我们可以取消编译rootfs里的一部分。
$ petalinux-config -c rootfs
将user packages所有项都取消勾选,包括
CONFIG_libftdi=y
CONFIG_cmake=y
CONFIG_iperf3=y
CONFIG_lmsensors-sensorsdetect=y
CONFIG_packagegroup-base-extended=y
CONFIG_packagegroup-petalinux-96boards-sensors=y
CONFIG_packagegroup-petalinux-ultra96-webapp=y
CONFIG_python-pyserial=y
CONFIG_python3-pip=y
CONFIG_ultra96-ap-setup=y
$ petalinux-build
在< path to plnx>/images/linux/路径下可以看到生成的文件。
将u-boot.elf, bl31.elf, pmufw.elf, zynqmp_fsbl.elf复制出来,按照前面的教程搭建SDSoC Platform。
$ petalinux-package --boot --force --fsbl images/linux/zynqmp_fsbl.elf --fpga images/linux/*_wrapper.bit --u-boot
先打包一个BOOT.bin和image.ub用来测试编译的内核是否可用。
参照https://github.com/Xilinx/PYNQ做一个ultra96的PYNQ img,将img用Win32Diskimager烧进SD卡。
也可以用提供好的zcu104的img,https://github.com/Xilinx/PYNQ/releases。
Q&A
Q: 为什么可以用104的img??
A: img分成两部分,一部分是kernel和比特流,一部分是rootfs,因为MPSoC系列的PS都是一样的,所以他们的rootfs是通用的,我们只需要将kernel和比特流替换成Ultra96的就可以了。
将Step3中生成的image.ub和BOOT.bin文件放到SD卡的FAT32分区,替换掉原有的文件。
如果前面的步骤没什么问题的话,将Ultra96的DP接口插在显示器上,上电起动后就会自动进入桌面了。
注意!市面上大部分mini dp转HDMI转接器不支持MPSoC系列芯片,什么绿联,优越者统统不行,官方配件列表里的 Ableconn MDPHD4KAA亲测可用,不过国内没有卖的,得上美亚才有。
更新1!DP转HDMI分成主动式跟被动式两种,必须是主动式的DP转HDMI才可以,CE-LINK 1641是主动式DP转HDMI,68元,亲测可用,淘宝京东都有得买!
更新2!Ableconn MDPHD4KAA的主控芯片是PS171,所以只要主控是PS171的转接器应该都可以,CableCreation也有一款用PS171的主动式DP转HDMI,淘宝可以搜到,68元。
PYNQ rootfs自带的桌面不是很好用,我把原来的卸载了,装上熟悉的xfce4
$ sudo apt remove --purge fluxbox -y
$ sudo apt install xorg xfce4
参照前面的教程
https://blog.csdn.net/lulugay/article/details/83305194
《SDSoC软硬件协同设计流程系列——5.SDSoC+xfOpenCV+OpenCV颜色识别》
在Ultra96上实现该项目,运行时可能会出现
Gtk-WARNING **: cannot open display
遇到这个问题在terminal中输入
export DISPLAY=:0.0
欢迎大家关注Xilinx学术合作以及Pynq的官方公众号,里面有许多优质的学习资源等着你哦
希望了解HLS的同学可以关注公众号Xilinx学术合作以及PYNQ中文社区获取最新版《FPGA并行编程-- 以HLS实现信号处理为例》pdf ,关注任一公众号,回复 pp4fpgas 即可获得