I have a current Mathworks image both FPGA and Zynq7020 ARM code that works fine for the time being. However, the current Mathworks release, 2018A, does not support the fast lock profile. As a result, retuning was very slow.
I am trying to use the current build, but create my own AD9361 interface in order to support fast lock. After a bit of trial and error, I have figured out that I need the linux userspace driver of the No OS software, which is what I'm using. I have compiled fine, and can build/run the example plus custom code. However, when I get to bb_dc_offset_calibration, it fails and I don't know why.
I have enabled: HAVE_VERBOSE_MESSAGES and HAVE_DEBUG_MESSAGES, and up to the calibration (I think) everything looks fine. But once it runs the calibration, it returns with:
Calibration TIMEOUT (0x16, 0x1) and then of course fails the ad9361_init() function.
bak85 said:After a bit of trial and error, I have figured out that I need the linux userspace driver of the No OS software, which is what I'm using.
This isn't true, you can use the linux driver fine, and by extension MATLAB: https://wiki.analog.com/resources/tools-software/linux-drivers/iio-transceiver/ad9361?s=fastlock#fastlock_mode
You can use the ADI system objects to add parameters from the driver you want. Our objects: https://wiki.analog.com/resources/eval/user-guides/matlab_bsp
Example on how to add properties: https://wiki.analog.com/resources/eval/user-guides/matlab_bsp_extend
I'm using an older version. As such, I don't have the IIO drivers or at least the current build doesn't utilize them. I have an outdated E310 System Object block that I'm trying to recreate.
As far as the timeout goes, what would normally cause that?
Thanks for your help
You usually get calibration timeouts when the clocks are set wrong or the digital interface (CMOS) isn't calibrated correctly.
I can't really comment further since I have no idea what is really running on the board HDL and Software wise. Mixing and matching versions of our code and MathWorks' can be problematic.
ADI does have HDL support for E310 and you can use our SD card's linux environment. Just make sure to update the device tree for E310.