I'm working with AD9361 integrated with Xilinx ZedBoard using No-Os driver.
I'm trying to synchronize sending two different LUT on DAC using AD9361 module. I stored two LUT with 1024 sine wave samples on two different positions in memory. Also, configured ISR for DAC to be triggered when SOT happens.
I'm trying to send one LUT1 on DAC 1000 times(integer counter counts to 1000), and than to switch LUT to send another LUT2 and to repeat those steps continiously.
I did it by counting how many times ISR happens and than switch LUT by calling:
My dac configuration in dac_init() is:
dac_dma_write(AXI_DMAC_REG_X_LENGTH, length - 1);
void DmaDoneHandler(unsigned int Channel, XDmaPs_Cmd *DmaCmd, void *CallbackRef)
uint32_t reg_val = 0;
if((interruptCounter++) == 1000)
if(sin == 1)
interruptCounter = 0;
sin *= -1;
My question is, is this good approach? Also, I need to accomplish that time of switching of those LUTs is less than 200ns(5MHz)
so if you have any suggestions how to implement this I'll be grateful!
One more thing. At one moment this worked fine for LUT with 32 samples, then I just changed LUT on 1024 samples and it stopped working.Any clue what could be the problem?