AD9361
Recommended for New Designs
The AD9361 is a high performance, highly integrated radio
frequency (RF) Agile Transceiverâ„¢ designed for use in 3G and
4G base station applications....
Datasheet
AD9361 on Analog.com
I am trying to create a linux image for a hardware design combining both Xilinx VCU TRD and fmcomms reference design from ADI on zcu106.
I have followed steps in the readme in the meta-adi git repo to create a linux image using the meta-adi and it tested fine for the reference hardware design. The pins were assigned to match zcu106.
My steps were,
The VCU TRD uses the usual petalinux device tree generation procedure and uses system-user.dtsi to do the modifications.
I confirmed the operation of the individual sections, fmcomms3 section in the PL with the aforementioned meta-adi linux image, xilinx vcu section in the PL with xilinx vcu bsp project. They both operated to my expectations.
Then I followed almost the same steps to create a linux image using meta-adi layers on top of xilinx vcu bsp.
Finally I got the system up and running. However the VCU pipeline is not operating at all. /dev/media0 node is missing and in the Xilinx forums it mentions that the issue is in the device tree.
How does the meta-adi layer handle the device tree? Why bother creating pl-delete-nodes if the pl.dtsi is ignored altogether? Have I done correctly in regarding creating a linux image using meta-adi layers for a custom platform despite I tested it ok for reference hardware design modified to zcu106?
I only need the support to control the fmcomms, it would be nice if I can use the ADI-DMAs and receive data through Ethernet, but not essential. I assume I only would require libiio support? is it too much of a hassle as mentioned in https://ez.analog.com/linux-software-drivers/f/q-a/558008/failure-in-adding-adrv9009-dtsi-file to manually add the libraries and drivers without using meta-adi?
Hi,
How does the meta-adi layer handle the device tree? Why bother creating pl-delete-nodes if the pl.dtsi is ignored altogether?
We try to keep xilinx stuff untouched as much as we can. pl.dtsi is not ignored, we just delete the nodes we know we're defining in the devicetree we pull from ADI linux tree (or somewhere else). If the VCU pipeline is not working, that likely means that yes, you're missing some devicetree stuff.
However I had to remove all the nodes in pl.dtsi using the pl-delete-nodes for the device tree to compile correctly. The system-user.dtsi could not detect the nodes in pl.dtsi
Not sure what you mean by this. Maybe you had some other issue.
Create pl-delete-nodes<>.dtsi and dts file using the zcu102-fmcomms2-3 dts file from adi git repo. Modified the zynqmp-zcu102-rev10-ad9361-fmcomms2-3.dts by adding the line "#include "zynqmp-zcu106-revA.dts" and commenting #include "zynqmp-zcu102-rev1.0.dts".
The pl-delete-nodes should be created from the pl.dtsi file. That's what you've done right? You should delete all the nodes that are already defined in the base devicetree you're going to use and that are specific to ADI cores. Because for those, the auto generated nodes created by petalinux are just "garbage". So what you should do is to put together a devicetree you know it works. Then use that devicetree in petalinux together with pl-delete-nodes to delete all the unwanted stuff in pl.dtsi.
I assume I only would require libiio support? is it too much of a hassle as mentioned in https://ez.analog.com/linux-software-drivers/f/q-a/558008/failure-in-adding-adrv9009-dtsi-file to manually add the libraries and drivers without using meta-adi?
Well, you definitely need the drivers and proper devicetree for them. As of libiio, it should be fairly easy to have it in your build as it's already part of meta-openembedded. You'll just have an old release. But you can append (as done in meta-adi) the libiio recipe to bring in a new version.
I should also mention that 2021.2 is fairly old and not actively supported anymore. So, if you can, it would be wise to move to the latest release.
- Nuno Sá
Thanks very much for your reply. Sorry for the late reply, I have been trying a few things after reading yours.
I managed to get ad9361 drivers and libiio installed after using the ADI-kernel with petalinux.
I added the device tree nodes from the device tree for zcu102 + fmcomms2 to the vcu trd's device tree.
Enabled ad9361, axi dmac drivers from the kernel settings.
Libiio was added from meta-openembedded oe-layer, as a custom app, following the guides from petalinux.
I suspect the issue was caused by the settings meta-adi layer adds, there is the possibility of a device tree issue as well, but I could not find any difference for the device tree nodes for VCU and pipelines.
Hi Ransara,
I have a very similar works with you but i encountered some issue that the u-boot cannot finish boot up. i would like to describe it here,
We already have a working Petalinux 2021.2 project.
By reference to website,
https://github.com/analogdevicesinc/meta-adi/blob/2021_R2/meta-adi-xilinx/README.md, I am setting the parameters:
KERNEL_DTB="zynqmp-zcu102-rev10-ad9361-fmcomms2-3.dts" in file “project-spec/meta-user/conf/petalinuxbsp.conf”. The Petalinux build is ok, however, when I flash the BOOT.BIN to QSPI flash, I cannot boot up the u-boot completely as shown below (the u-boot will stuck after “PMUFW: ”),
Xilinx Zynq MP First Stage Boot Loader Release 2021.2 Oct 13 2021 - 07:15:53 NOTICE: BL31: v2.4(release):xlnx_rebase_v2.4_2021.1_update1-23-g9188496b9 NOTICE: BL31: Built : 07:41:24, Oct 13 2021
U-Boot 2021.01 (Oct 12 2021 - 09:28:42 +0000)
CPU: ZynqMP Silicon: v3 Model: ZynqMP ZCU102 Rev1.0 Board: Xilinx ZynqMP DRAM: 4 GiB PMUFW: v1.1
|
The original Petalinux project does not have message “Model: ZynqMP ZCU102 Rev1.0”, this looked like the new added ADI yocto layers have taken over the original Petalinux device-tree setting. Currently I am also trying to look into using parameter “DTS_BASE” in file “project-spec/meta-user/conf/petalinuxbsp.conf” but I am not successfully using this parameter yet.
Because of our custom board design, I cannot use the ADI ready built project to apply to our Petalinux board directly, I think there are other setting need to apply also. Do you have any ideas/advices that additional setting required to make the Petalinux project runnable on our custom hardware?
Thanks and Best Regards.
Are you sure BOOT.BIN is enough?
Have you referred to the section “Booting PetaLinux Image on Hardware with QSPI or OSPI” in petalinux userguide ug1144?
By the way, I think you should open a new thread.
The BOOT.BIN is enough, when i decompiled the file system.dtb, i found that there are many zcu102 content inside, in my original post of the questions, i have added my analysis of the problem which related to the ADI Yocto layer device-tree priority has taken over the main Petalinux device-tree priority. Currently, i am unsure how to better control it.
i have posted my questions here:
https://ez.analog.com/linux-software-drivers/f/q-a/582515/petalinux-adi-yocto-layers-for-ad9361