How to use XRFdc_IntrClr in PYNQ

Hi,

I am using zcu111 board and I am trying to set the DAC interpolation factor using Pynq.
According to pg269 rf-data-converter manual (page 200) ,

“Dynamic change in interpolation has an impact on the block throughput. The AXI4-Stream clock
rate can be dynamically changed to account for this change of throughput. In non-MTS mode,
the recommended procedure is to turn off the FIFO (Xrfdc_setupfifo), change the clock rate
(Xrfdc_SetfabClkOutDiv), clear the FIFO interrupt , and restart the FIFO
(Xrfdc_SetupFifo).”

How do I clear the FIFO interrupt?
I am using non-MTS mode and the steps I am following to change the interpolation factor are:

  1. turn off the fifo** : bit.usp_rf_data_converter_0.dac_tiles[0].SetupFIFO(False)

  2. change the clock rate** : bit.usp_rf_data_converter_0.dac_tiles[0].FabClkOutDiv=3

  3. change the interpolation factor: bit.usp_rf_data_converter_0.dac_tiles[0].blocks[0].InterpolationFactor=2

  4. restart the fifo** : bit.usp_rf_data_converter_0.dac_tiles[0].SetupFIFO(False)

I would like to know how I clear the fifo interrupt using PYNQ.

I come two years late, but if you still developing with PYNQ I hope my help serves to you.

I had been the same question and finally I found the answer. You have to call a method of RFdc class in which you can send/use any command/function which is content in XRFdc library.

In this case my solution is:
(“A RFdc object”)._call_function(“IntrClr”, 0, 0, 0, 4294967295)

The first 0 indicates that you are setting up an ADC, the second one indicates that you are setting up the tile 0 of the ADC and the last indicates the block number of the tile.

The last argument (4294967295) corresponds with 0xFFFFFFFF in hex. In this case it is for clear all the interrupts.

Best Regards,
Jorge