AnsweredAssumed Answered

Problem in initialization of multiple AD9361 transceivers

Question asked by marcovalerioa on Jun 26, 2017
Latest reply on Jun 27, 2017 by sripad

Hello,

I am working with a custom carrier board that supports up to four AD9361 transceiver boards. Both the carrier board and the transceiver boards are custom made.

On the carrier board there is a PIC microcontroller in charge of configuring the transceivers.

I am using the NoOS software provided by ADI (with some minor adaptation to my application).

The portion of the microcontroller SW that performs the initialization of the transceiver is the following:

 

                for (islot=3;islot>=0;islot--) {
                    if (pslot[islot]==1) {
                        sprintf(str,"RF slot %2d  \r\n",islot+1);
                        StringToUART(str);
                        csslot(islot,0);
                        ad9361_init(&(ad9361_phy[islot]), &default_init_param);
                        ad9361_set_tx_fir_config(ad9361_phy[islot], tx_fir_config);
                        ad9361_set_rx_fir_config(ad9361_phy[islot], rx_fir_config);
                        csslot(islot,1);
                    }
                }

 

The variable pslot is equal to one if the slot is populated with a transceiver board and zero otherwise.

The function csslot sets the chip select line of the SPI interface corresponding to the slot defined by islot. The other SPI lines are shared by the four slots.

The variable ad9361_phy which was defined in the original NoOS SW as:

struct ad9361_rf_phy *ad9361_phy;

 

has been changed as:

 

struct ad9361_rf_phy *ad9361_phy[4];

 

When a single slot is populated the initialization (and the transceiver) works correctly. However, when two slots are populated the initialization of the first one completes correctly but the SW hangs up somewere during the initialization of the second one. The problem does not depend on the transceiver board nor on the slot in the carrier board, because I can change the cycle from:

 

for (islot=3;islot>=0;islot--) {...

 

to:

 

for (islot=0;islot<4;islot++) {...

 

and the results does not change. The first transceiver board (that is the board in the highest slot number for the first cycle or the board in the lowest slot number in the second cycle) is correctly initialized and the SW hangs up during the initialization of the second board.

 

My hypothesis is that some variable is changed during the first initialization and not reset for the second one, but I cannot found it.

 

Could someone give me an hint about my problem?

 

many thanks

Outcomes