AnsweredAssumed Answered

about Rx and Tx switch on TDD mode

Question asked by hly0407 on Jan 15, 2016
Latest reply on Jan 21, 2016 by DragosB

hello everyone  

     i use ad9361 with no-os system at fmcomms2+zc706. and i select TDD mode to receive and transmit, use AGC mode.

     after init setup, i do this

 

  uint32_t ensm_state ;
  int32_t i;
  int32_t rdata;
  int16_t sampI, sampQ;

     while(true)

     {

         //ensm

         ad9361_set_en_state_machine_mode(ad9361_phy,ENSM_STATE_ALERT);

         ad9361_set_en_state_machine_mode(ad9361_phy,ENSM_STATE_RX);

 

 

         mdelay(10);

      

         //Rx

         adc_capture(1024,ADC_DDR_BASEADDR);

         Xil_DCacheInvalidateRange(ADC_DDR_BASEADDR,1024*4);

         for( i= 0; i< 16384; i++ )

         {

             rdata = Xil_In32(ADC_DDR_BASEADDR+(i*4));

             sampQ = rdata & 0xFFFF;

             sampI = (rdata>>16) & 0xFFFF;

 

 

             xil_printf("%d ",sampI);

         }

 

 

         mdelay(10);

 

 

         //ensm

         ad9361_set_en_state_machine_mode(ad9361_phy,ENSM_STATE_ALERT);

         ad9361_set_en_state_machine_mode(ad9361_phy,ENSM_STATE_TX);

    

         dac_init(ad9361_phy,DDS_SEL_DMA,1);

 

 

         mdelay(10);

     }

 

     now there is my question.  after ENSM move to Rx, the red font "mdelay(10)" is need , and  if the mdelay time is to less, the data i captured is no correct. but if i reduce the transmission power of the signal source to -60dbm(the init power is -20dbm), then delay 10 can be changed to 1.

     i need a complete cycle time is less then 50us,  I can change the other places delay, but the red font delay can't. what's my problem,and what can i do?

     thankyou

     hly

Outcomes