I am trying to use the analog devices NO OS driver to control the ad9361 part. It mostly makes sense how to connect up to the specific HW we are using. You basically fill the calls in platform.c to connect up with our specific HW. However the platform.c also implements these calls:
void axiadc_init(struct ad9361_rf_phy *phy);
int axiadc_post_setup(struct ad9361_rf_phy *phy);
unsigned int axiadc_read(struct axiadc_state *st, unsigned long reg);
void axiadc_write(struct axiadc_state *st, unsigned reg, unsigned val);
int axiadc_set_pnsel(struct axiadc_state *st, int channel, enum adc_pn_sel sel);
void axiadc_idelay_set(struct axiadc_state *st, unsigned lane, unsigned val);
It is not clear how to fill these in. We have a zed dev kit using Xilinx and looking at that version these calls end up calling functions in specific files in the Xilinx code adc_core.c and dac_core.c.
After talking with another associate it seems like the axi stuff are HDL interfaces for the FPGA as part of the reference design that could be added. And it is these add ons that the NO OS driver is accessing. He pointed me to config.h of the driver and should enable the line:
To work around these calls. Can you confirm this?
Yes, that is correct.
The AXI ADC is part of our HDL reference design; the AXI ADC interfaces with the AD9361.
If you don't need it, defining AXI_ADC_NOT_PRESENT is the way to go.
What is the use of AXI_ADC_NOT_PRESENT?
The reference HDL project uses an ADC IP core.
The C code in no-OS (by default) assumes that the ADC HDL core is present.
In cases where it is not present, this #define should be used.