Why AD9364 double the bandwidth of TX data?

Hi,my board is a 5.8GHz transmitor made up of a FPGA +AD9364.

The FPGA has modulated  the baseband data and put it to 8MHz intermidiate frequency.

The band width is 6.875MHz,and the sample rate is 55MHz.The data is sent to AD9364 through lvds interface with 110MHz speed.

I set the TFIR as 2x speed and enabled the FIR filter,and set THB3 as 3x.,so the DAC speed is 330MHz which gives a 6 times ratio to the sample rate.

I have made a 96 taps FIR filter with MATLAB,and filled the coefficients into the memory.

Then I see  the analog bandwidth is not 6.875MHz, but is doubled as 13.75MHz.

Can some one help me to find out what's wrong with my settings?

Thanks!

  • 0
    •  Analog Employees 
    on Oct 12, 2021 2:44 AM

    Please attached your bandwidth setting code and the photo of spectrum analyzer when it got 13.75Mhz signal 

  •  here is the spectrum and code

    //************************************************************
    // AD9361 R2 Auto Generated Initialization Script:  This script was
    // generated using the AD9361 Customer software Version 2.1.4
    //************************************************************
    // Profile: Custom
    // REFCLK_IN: 40.000 MHz
    
    RESET_FPGA	
    RESET_DUT	
    
    BlockWrite	2,6	// Set ADI FPGA SPI to 20Mhz
    SPIWrite	3DF,01	// Required for proper operation
    ReadPartNumber
    SPIWrite	2A6,0E	// Enable Master Bias
    SPIWrite	2A8,0E	// Set Bandgap Trim
    REFCLK_Scale	40.000000,1,2	// Sets local variables in script engine, user can ignore
    SPIWrite	2AB,07	// Set RF PLL reflclk scale to REFCLK * 2
    SPIWrite	2AC,FF	// Set RF PLL reflclk scale to REFCLK * 2
    SPIWrite	009,17	// Enable Clocks
    WAIT	20	// waits 20 ms
    //************************************************************
    // Set BBPLL Frequency: 1320.000000
    //************************************************************
    SPIWrite	045,00	// Set BBPLL reflclk scale to REFCLK /1
    SPIWrite	046,05	// Set BBPLL Loop Filter Charge Pump current
    SPIWrite	048,E8	// Set BBPLL Loop Filter C1, R1
    SPIWrite	049,5B	// Set BBPLL Loop Filter R2, C2, C1
    SPIWrite	04A,35	// Set BBPLL Loop Filter C3,R2
    SPIWrite	04B,E0	// Allow calibration to occur and set cal count to 1024 for max accuracy
    SPIWrite	04E,10	// Set calibration clock to REFCLK/4 for more accuracy
    SPIWrite	043,00	// BBPLL Freq Word (Fractional[7:0])
    SPIWrite	042,00	// BBPLL Freq Word (Fractional[15:8])
    SPIWrite	041,00	// BBPLL Freq Word (Fractional[23:16])
    SPIWrite	044,21	// BBPLL Freq Word (Integer[7:0])
    SPIWrite	03F,05	// Start BBPLL Calibration
    SPIWrite	03F,01	// Clear BBPLL start calibration bit
    SPIWrite	04C,86	// Increase BBPLL KV and phase margin
    SPIWrite	04D,01	// Increase BBPLL KV and phase margin
    SPIWrite	04D,05	// Increase BBPLL KV and phase margin
    WAIT_CALDONE	BBPLL,2000	// Wait for BBPLL to lock, Timeout 2sec, Max BBPLL VCO Cal Time: 345.600 us (Done when 0x05E[7]==1)
    
    SPIRead	05E	// Check BBPLL locked status  (0x05E[7]==1 is locked)
    
    SPIWrite	002,62	// Setup Tx Digital Filters/ Channels
    SPIWrite	003,24	// Setup Rx Digital Filters/ Channels
    SPIWrite	004,43	// Select Rx input pin(A,B,C)/ Tx out pin (A,B)
    SPIWrite	00A,12	// Set BBPLL post divide rate
    
    //************************************************************
    // Program Tx FIR: C:\Program Files (x86)\Analog Devices\AD9361
    // Evaluation Software v2.1.5
    // (64-bit)\DigitalFilters\128tapFilter.ftr
    //************************************************************
    SPIWrite	065,FA	// Enable clock to Tx FIR Filter and set Filter gain Setting 
    SPIWrite	060,00	// Write FIR coefficient address
    SPIWrite	061,01	// Write FIR coefficient data[7:0]
    SPIWrite	062,00	// Write FIR coefficient data[15:8]
    SPIWrite	065,FE	// Set Write EN to push data into FIR filter register map
    SPIWrite	064,00	// Write to Read only register to delay ~1us
    SPIWrite	064,00	// Write to Read only register to delay ~1us
    SPIWrite	060,01
    SPIWrite	061,F1
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,02
    SPIWrite	061,CF
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,03
    SPIWrite	061,C0
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,04
    SPIWrite	061,E8
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,05
    SPIWrite	061,20
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,06
    SPIWrite	061,1A
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,07
    SPIWrite	061,E3
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,08
    SPIWrite	061,E1
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,09
    SPIWrite	061,1F
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,0A
    SPIWrite	061,28
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,0B
    SPIWrite	061,DF
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,0C
    SPIWrite	061,CC
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,0D
    SPIWrite	061,24
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,0E
    SPIWrite	061,43
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,0F
    SPIWrite	061,DB
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,10
    SPIWrite	061,AC
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,11
    SPIWrite	061,26
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,12
    SPIWrite	061,68
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,13
    SPIWrite	061,DB
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,14
    SPIWrite	061,80
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,15
    SPIWrite	061,22
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,16
    SPIWrite	061,9A
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,17
    SPIWrite	061,E2
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,18
    SPIWrite	061,47
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,19
    SPIWrite	061,17
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,1A
    SPIWrite	061,DB
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,1B
    SPIWrite	061,F3
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,1C
    SPIWrite	061,FF
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,1D
    SPIWrite	061,FF
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,1E
    SPIWrite	061,2B
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,1F
    SPIWrite	061,13
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,20
    SPIWrite	061,A5
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,21
    SPIWrite	061,D7
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,22
    SPIWrite	061,90
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,23
    SPIWrite	061,46
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,24
    SPIWrite	061,35
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,25
    SPIWrite	061,97
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,26
    SPIWrite	061,0E
    SPIWrite	062,02
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,27
    SPIWrite	061,95
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,28
    SPIWrite	061,A7
    SPIWrite	062,FD
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,29
    SPIWrite	061,36
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,2A
    SPIWrite	061,AE
    SPIWrite	062,02
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,2B
    SPIWrite	061,0D
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,2C
    SPIWrite	061,F0
    SPIWrite	062,FC
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,2D
    SPIWrite	061,A1
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,2E
    SPIWrite	061,83
    SPIWrite	062,03
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,2F
    SPIWrite	061,C6
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,30
    SPIWrite	061,F3
    SPIWrite	062,FB
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,31
    SPIWrite	061,B6
    SPIWrite	062,FD
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,32
    SPIWrite	061,B7
    SPIWrite	062,04
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,33
    SPIWrite	061,F8
    SPIWrite	062,02
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,34
    SPIWrite	061,6D
    SPIWrite	062,FA
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,35
    SPIWrite	061,1A
    SPIWrite	062,FC
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,36
    SPIWrite	061,BE
    SPIWrite	062,06
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,37
    SPIWrite	061,41
    SPIWrite	062,05
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,38
    SPIWrite	061,87
    SPIWrite	062,F7
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,39
    SPIWrite	061,98
    SPIWrite	062,F8
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,3A
    SPIWrite	061,60
    SPIWrite	062,0B
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,3B
    SPIWrite	061,6D
    SPIWrite	062,0B
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,3C
    SPIWrite	061,88
    SPIWrite	062,EE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,3D
    SPIWrite	061,40
    SPIWrite	062,EA
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,3E
    SPIWrite	061,86
    SPIWrite	062,27
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,3F
    SPIWrite	061,09
    SPIWrite	062,72
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,40
    SPIWrite	061,09
    SPIWrite	062,72
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,41
    SPIWrite	061,86
    SPIWrite	062,27
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,42
    SPIWrite	061,40
    SPIWrite	062,EA
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,43
    SPIWrite	061,88
    SPIWrite	062,EE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,44
    SPIWrite	061,6D
    SPIWrite	062,0B
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,45
    SPIWrite	061,60
    SPIWrite	062,0B
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,46
    SPIWrite	061,98
    SPIWrite	062,F8
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,47
    SPIWrite	061,87
    SPIWrite	062,F7
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,48
    SPIWrite	061,41
    SPIWrite	062,05
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,49
    SPIWrite	061,BE
    SPIWrite	062,06
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,4A
    SPIWrite	061,1A
    SPIWrite	062,FC
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,4B
    SPIWrite	061,6D
    SPIWrite	062,FA
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,4C
    SPIWrite	061,F8
    SPIWrite	062,02
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,4D
    SPIWrite	061,B7
    SPIWrite	062,04
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,4E
    SPIWrite	061,B6
    SPIWrite	062,FD
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,4F
    SPIWrite	061,F3
    SPIWrite	062,FB
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,50
    SPIWrite	061,C6
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,51
    SPIWrite	061,83
    SPIWrite	062,03
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,52
    SPIWrite	061,A1
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,53
    SPIWrite	061,F0
    SPIWrite	062,FC
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,54
    SPIWrite	061,0D
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,55
    SPIWrite	061,AE
    SPIWrite	062,02
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,56
    SPIWrite	061,36
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,57
    SPIWrite	061,A7
    SPIWrite	062,FD
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,58
    SPIWrite	061,95
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,59
    SPIWrite	061,0E
    SPIWrite	062,02
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,5A
    SPIWrite	061,97
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,5B
    SPIWrite	061,35
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,5C
    SPIWrite	061,46
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,5D
    SPIWrite	061,90
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,5E
    SPIWrite	061,D7
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,5F
    SPIWrite	061,A5
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,60
    SPIWrite	061,13
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,61
    SPIWrite	061,2B
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,62
    SPIWrite	061,FF
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,63
    SPIWrite	061,FF
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,64
    SPIWrite	061,F3
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,65
    SPIWrite	061,DB
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,66
    SPIWrite	061,17
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,67
    SPIWrite	061,47
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,68
    SPIWrite	061,E2
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,69
    SPIWrite	061,9A
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,6A
    SPIWrite	061,22
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,6B
    SPIWrite	061,80
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,6C
    SPIWrite	061,DB
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,6D
    SPIWrite	061,68
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,6E
    SPIWrite	061,26
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,6F
    SPIWrite	061,AC
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,70
    SPIWrite	061,DB
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,71
    SPIWrite	061,43
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,72
    SPIWrite	061,24
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,73
    SPIWrite	061,CC
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,74
    SPIWrite	061,DF
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,75
    SPIWrite	061,28
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,76
    SPIWrite	061,1F
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,77
    SPIWrite	061,E1
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,78
    SPIWrite	061,E3
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,79
    SPIWrite	061,1A
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,7A
    SPIWrite	061,20
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,7B
    SPIWrite	061,E8
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,7C
    SPIWrite	061,C0
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,7D
    SPIWrite	061,CF
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,7E
    SPIWrite	061,F1
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,7F
    SPIWrite	061,01
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	065,F8	// Disable clock to Tx Filter
    
    //************************************************************
    // Setup the Parallel Port (Digital Data Interface)
    //************************************************************
    SPIWrite	010,C8	// I/O Config.  Tx Swap IQ; Rx Swap IQ; Tx CH Swap, Rx CH Swap; Rx Frame Mode; 2R2T bit; Invert data bus; Invert DATA_CLK
    SPIWrite	011,00	// I/O Config.  Alt Word Order; -Rx1; -Rx2; -Tx1; -Tx2; Invert Rx Frame; Delay Rx Data
    SPIWrite	012,10	// I/O Config.  Rx=2*Tx; Swap Ports; SDR; LVDS; Half Duplex; Single Port; Full Port; Swap Bits
    SPIWrite	006,0F	// PPORT Rx Delay (adjusts Tco Dataclk->Data)
    SPIWrite	007,00	// PPORT TX Delay (adjusts setup/hold FBCLK->Data)
    
    SPIWrite	03C,21	// CLK_OUT slew; LVDS: Rx Term; Bypass Bias R; Tx LO VCM; Bias[2:0]
    SPIWrite	03D,00	// LVDS polarity invert
    SPIWrite	03E,00	// LVDS polarity invert
    
    //************************************************************
    // Setup AuxDAC
    //************************************************************
    SPIWrite	018,00	// AuxDAC1 Word[9:2]
    SPIWrite	019,00	// AuxDAC2 Word[9:2]
    SPIWrite	01A,00	// AuxDAC1 Config and Word[1:0]
    SPIWrite	01B,00	// AuxDAC2 Config and Word[1:0]
    SPIWrite	023,FF	// AuxDAC Manaul/Auto Control
    SPIWrite	026,00	// AuxDAC Manual Select Bit/GPO Manual Select
    SPIWrite	030,00	// AuxDAC1 Rx Delay
    SPIWrite	031,00	// AuxDAC1 Tx Delay
    SPIWrite	032,00	// AuxDAC2 Rx Delay
    SPIWrite	033,00	// AuxDAC2 Tx Delay
    
    //************************************************************
    // Setup AuxADC
    //************************************************************
    SPIWrite	00B,00	// Temp Sensor Setup (Offset)
    SPIWrite	00C,00	// Temp Sensor Setup (Temp Window)
    SPIWrite	00D,03	// Temp Sensor Setup (Periodic Measure)
    SPIWrite	00F,04	// Temp Sensor Setup (Decimation)
    SPIWrite	01C,10	// AuxADC Setup (Clock Div)
    SPIWrite	01D,01	// AuxADC Setup (Decimation/Enable)
    
    //************************************************************
    // Setup Control Outs
    //************************************************************
    SPIWrite	035,00	// Ctrl Out index
    SPIWrite	036,FF	// Ctrl Out [7:0] output enable
    
    //************************************************************
    // Setup GPO
    //************************************************************
    SPIWrite	03A,27	// Set number of REFCLK cycles for 1us delay timer
    SPIWrite	020,00	// GPO Auto Enable Setup in RX and TX
    SPIWrite	027,03	// GPO Manual and GPO auto value in ALERT
    SPIWrite	028,00	// GPO_0 RX Delay
    SPIWrite	029,00	// GPO_1 RX Delay
    SPIWrite	02A,00	// GPO_2 RX Delay
    SPIWrite	02B,00	// GPO_3 RX Delay
    SPIWrite	02C,00	// GPO_0 TX Delay
    SPIWrite	02D,00	// GPO_1 TX Delay
    SPIWrite	02E,00	// GPO_2 TX Delay
    SPIWrite	02F,00	// GPO_3 TX Delay
    
    //************************************************************
    // Setup RF PLL non-frequency-dependent registers
    //************************************************************
    SPIWrite	261,00	// Set Rx LO Power mode
    SPIWrite	2A1,00	// Set Tx LO Power mode
    SPIWrite	248,0B	// Enable Rx VCO LDO
    SPIWrite	288,0B	// Enable Tx VCO LDO
    SPIWrite	246,02	// Set VCO Power down TCF bits
    SPIWrite	286,02	// Set VCO Power down TCF bits
    SPIWrite	249,8E	// Set VCO cal length
    SPIWrite	289,8E	// Set VCO cal length
    SPIWrite	23B,80	// Enable Rx VCO cal
    SPIWrite	27B,80	// Enable Tx VCO cal
    SPIWrite	243,0D	// Set Rx prescaler bias
    SPIWrite	283,0D	// Set Tx prescaler bias
    SPIWrite	23D,10	// Clear Half VCO cal clock setting
    SPIWrite	27D,10	// Clear Half VCO cal clock setting
    
    SPIWrite	015,0C	// Set Dual Synth mode bit
    SPIWrite	014,15	// Set Force ALERT State bit
    SPIWrite	013,01	// Set ENSM FDD mode
    WAIT	1	// waits 1 ms
    SPIWrite	23D,14	// Start RX CP cal
    WAIT_CALDONE	RXCP,100	// Wait for CP cal to complete, Max RXCP Cal time: 460.800 (us)(Done when 0x244[7]==1)
    
    SPIWrite	27D,14	// Start TX CP cal
    WAIT_CALDONE	TXCP,100	// Wait for CP cal to complete, Max TXCP Cal time: 460.800 (us)(Done when 0x284[7]==1)
    
    //************************************************************
    // FDD RX,TX Synth Frequency: 5400.000000,5696.000000 MHz
    //************************************************************
    //************************************************************
    // Setup Rx Frequency-Dependent Syntheisizer Registers
    //************************************************************
    SPIWrite	23A,4D	// Set VCO Output level[3:0]
    SPIWrite	239,C1	// Set Init ALC Value[3:0] and VCO Varactor[3:0]
    SPIWrite	242,14	// Set VCO Bias Tcf[1:0] and VCO Bias Ref[2:0]
    SPIWrite	238,78	// Set VCO Cal Offset[3:0]
    SPIWrite	245,00	// Set VCO Cal Ref Tcf[2:0]
    SPIWrite	251,0C	// Set VCO Varactor Reference[3:0]
    SPIWrite	250,70	// Set VCO Varactor Ref Tcf[2:0] and VCO Varactor Offset[3:0]
    SPIWrite	23B,89	// Set Synth Loop Filter charge pump current (Icp)
    SPIWrite	23E,F6	// Set Synth Loop Filter C2 and C1
    SPIWrite	23F,D5	// Set Synth Loop Filter  R1 and C3
    SPIWrite	240,0E	// Set Synth Loop Filter R3
    
    //************************************************************
    // Setup Tx Frequency-Dependent Syntheisizer Registers
    //************************************************************
    SPIWrite	27A,4D	// Set VCO Output level[3:0]
    SPIWrite	279,C1	// Set Init ALC Value[3:0] and VCO Varactor[3:0]
    SPIWrite	282,14	// Set VCO Bias Tcf[1:0] and VCO Bias Ref[2:0]
    SPIWrite	278,78	// Set VCO Cal Offset[3:0]
    SPIWrite	285,00	// Set VCO Cal Ref Tcf[2:0]
    SPIWrite	291,0C	// Set VCO Varactor Reference[3:0]
    SPIWrite	290,70	// Set VCO Varactor Ref Tcf[2:0] and VCO Varactor Offset[3:0]
    SPIWrite	27B,88	// Set Synth Loop Filter charge pump current (Icp)
    SPIWrite	27E,F6	// Set Synth Loop Filter C2 and C1
    SPIWrite	27F,D5	// Set Synth Loop Filter  R1 and C3
    SPIWrite	280,0E	// Set Synth Loop Filter R3
    
    //************************************************************
    // Write Rx and Tx Frequency Words
    //************************************************************
    SPIWrite	233,00	// Write Rx Synth Fractional Freq Word[7:0]
    SPIWrite	234,00	// Write Rx Synth Fractional Freq Word[15:8]
    SPIWrite	235,00	// Write Rx Synth Fractional Freq Word[22:16]
    SPIWrite	232,00	// Write Rx Synth Integer Freq Word[10:8]
    SPIWrite	231,87	// Write Rx Synth Integer Freq Word[7:0]
    SPIWrite	005,00	// Set LO divider setting
    SPIWrite	273,2D	// Write Tx Synth Fractional Freq Word[7:0]
    SPIWrite	274,33	// Write Tx Synth Fractional Freq Word[15:8]
    SPIWrite	275,33	// Write Tx Synth Fractional Freq Word[22:16]
    SPIWrite	272,00	// Write Tx Synth Integer Freq Word[10:8]
    SPIWrite	271,8E	// Write Tx Synth Integer Freq Word[7:0] (starts VCO cal)
    SPIWrite	005,00	// Set LO divider setting
    SPIRead	247	// Check RX RF PLL lock status (0x247[1]==1 is locked)
    SPIRead	287	// Check TX RF PLL lock status (0x287[1]==1 is locked)
    
    //************************************************************
    // Program Mixer GM Sub-table
    //************************************************************
    SPIWrite	13F,02	// Start Clock
    SPIWrite	138,0F	// Addr Table Index
    SPIWrite	139,78	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,00	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,0E	// Addr Table Index
    SPIWrite	139,74	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,0D	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,0D	// Addr Table Index
    SPIWrite	139,70	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,15	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,0C	// Addr Table Index
    SPIWrite	139,6C	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,1B	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,0B	// Addr Table Index
    SPIWrite	139,68	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,21	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,0A	// Addr Table Index
    SPIWrite	139,64	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,25	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,09	// Addr Table Index
    SPIWrite	139,60	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,29	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,08	// Addr Table Index
    SPIWrite	139,5C	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,2C	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,07	// Addr Table Index
    SPIWrite	139,58	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,2F	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,06	// Addr Table Index
    SPIWrite	139,54	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,31	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,05	// Addr Table Index
    SPIWrite	139,50	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,33	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,04	// Addr Table Index
    SPIWrite	139,4C	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,34	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,03	// Addr Table Index
    SPIWrite	139,48	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,35	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,02	// Addr Table Index
    SPIWrite	139,30	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,3A	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,01	// Addr Table Index
    SPIWrite	139,18	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,3D	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,00	// Addr Table Index
    SPIWrite	139,00	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,3E	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	13F,02	// Clear Write Bit
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	13F,00	// Stop Clock
    
    //************************************************************
    // Program Rx Gain Tables with GainTable5000MHz.csv
    //************************************************************
    
    SPIWrite	137,1A	// Start Gain Table Clock
    SPIWrite	130,00	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,01	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,02	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,03	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,04	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,05	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,01	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,06	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,02	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,07	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,03	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,08	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,01	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,09	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,02	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,0A	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,03	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,0B	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,04	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,0C	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,05	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,0D	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,06	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,0E	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,07	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,0F	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,08	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,10	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,09	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,11	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0A	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,12	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0B	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,13	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0C	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,14	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,08	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,15	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,09	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,16	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0A	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,17	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0B	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,18	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0C	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,19	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0D	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,1A	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0E	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,1B	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0F	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,1C	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2A	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,1D	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2B	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,1E	// Gain Table Index
    SPIWrite	131,04	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,27	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,1F	// Gain Table Index
    SPIWrite	131,04	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,28	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,20	// Gain Table Index
    SPIWrite	131,04	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,29	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,21	// Gain Table Index
    SPIWrite	131,04	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2A	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,22	// Gain Table Index
    SPIWrite	131,04	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2B	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,23	// Gain Table Index
    SPIWrite	131,04	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2C	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,24	// Gain Table Index
    SPIWrite	131,04	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2D	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,25	// Gain Table Index
    SPIWrite	131,24	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,20	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,26	// Gain Table Index
    SPIWrite	131,24	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,21	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,27	// Gain Table Index
    SPIWrite	131,24	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,22	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,28	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,20	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,29	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,21	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,2A	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,22	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,2B	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,23	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,2C	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,24	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,2D	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,25	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,2E	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,26	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,2F	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,27	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,30	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,28	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,31	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,29	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,32	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2A	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,33	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2B	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,34	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2C	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,35	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2D	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,36	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2E	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,37	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2E	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,38	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2F	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,39	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,30	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,3A	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,31	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,3B	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,32	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,3C	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,33	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,3D	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,34	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,3E	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,35	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,3F	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,36	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,40	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,37	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,41	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,42	// Gain Table Index
    SPIWrite	131,65	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,43	// Gain Table Index
    SPIWrite	131,66	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,44	// Gain Table Index
    SPIWrite	131,67	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,45	// Gain Table Index
    SPIWrite	131,68	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,46	// Gain Table Index
    SPIWrite	131,69	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,47	// Gain Table Index
    SPIWrite	131,6A	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,48	// Gain Table Index
    SPIWrite	131,6B	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,49	// Gain Table Index
    SPIWrite	131,6C	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,4A	// Gain Table Index
    SPIWrite	131,6D	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,4B	// Gain Table Index
    SPIWrite	131,6E	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,4C	// Gain Table Index
    SPIWrite	131,6F	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,4D	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,4E	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,4F	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,50	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,51	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,52	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,53	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,54	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,55	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,56	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,57	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,58	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,59	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,5A	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	137,1A	// Clear Write Bit
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	137,00	// Stop Gain Table Clock
    //************************************************************
    // Setup Rx Manual Gain Registers
    //************************************************************
    SPIWrite	0FA,E0	// Gain Control Mode Select
    SPIWrite	0FB,08	// Table, Digital Gain, Man Gain Ctrl
    SPIWrite	0FC,23	// Incr Step Size, ADC Overrange Size
    SPIWrite	0FD,4C	// Max Full/LMT Gain Table Index
    SPIWrite	0FE,44	// Decr Step Size, Peak Overload Time
    SPIWrite	100,6F	// Max Digital Gain
    SPIWrite	104,2F	// ADC Small Overload Threshold
    SPIWrite	105,3A	// ADC Large Overload Threshold
    SPIWrite	107,2B	// Small LMT Overload Threshold
    SPIWrite	108,31	// Large LMT Overload Threshold
    SPIWrite	109,4C	// Rx1 Full/LMT Gain Index
    SPIWrite	10A,58	// Rx1 LPF Gain Index
    SPIWrite	10B,00	// Rx1 Digital Gain Index
    SPIWrite	10C,4C	// Rx2 Full/LMT Gain Index
    SPIWrite	10D,18	// Rx2 LPF Gain Index
    SPIWrite	10E,00	// Rx2 Digital Gain Index
    SPIWrite	114,30	// Low Power Threshold
    SPIWrite	11A,27	// Initial LMT Gain Limit
    SPIWrite	081,00	// Tx Symbol Gain Control
    //************************************************************
    // RX Baseband Filter Tuning (Real BW: 20.000000 MHz) 3dB Filter
    // Corner @ 28.000000 MHz)
    //************************************************************
    SPIWrite	1FB,14	// RX Freq Corner (MHz)
    SPIWrite	1FC,00	// RX Freq Corner (Khz)
    SPIWrite	1F8,06	// Rx BBF Tune Divider[7:0]
    SPIWrite	1F9,1E	// RX BBF Tune Divider[8]
    
    SPIWrite	1D5,3F	// Set Rx Mix LO CM
    SPIWrite	1C0,03	// Set GM common mode
    SPIWrite	1E2,02	// Enable Rx1 Filter Tuner 
    SPIWrite	1E3,02	// Enable Rx2 Filter Tuner 
    SPIWrite	016,80	// Start RX Filter Tune
    WAIT_CALDONE	RXFILTER,2000	// Wait for RX filter to tune, Max Cal Time: 2.773 us (Done when 0x016[7]==0)
    
    SPIWrite	1E2,03	// Disable Rx Filter Tuner (Rx1)
    SPIWrite	1E3,03	// Disable Rx Filter Tuner (Rx2)
    //************************************************************
    // TX Baseband Filter Tuning (Real BW: 20.000000 MHz) 3dB Filter
    // Corner @ 32.000000 MHz)
    //************************************************************
    SPIWrite	0D6,05	// TX BBF Tune Divider[7:0]
    SPIWrite	0D7,1E	// TX BBF Tune Divider[8]
    
    SPIWrite	0CA,22	// Enable Tx Filter Tuner
    SPIWrite	016,40	// Start Tx Filter Tune
    WAIT_CALDONE	TXFILTER,2000	// Wait for TX filter to tune, Max Cal Time: 1.345 us (Done when 0x016[6]==0)
    
    SPIWrite	0CA,26	// Disable Tx Filter Tuner (Both Channels)
    //************************************************************
    // RX TIA Setup:  Setup values scale based on RxBBF calibration
    // results.  See information in Calibration Guide. 
    //************************************************************
    SPIRead	1EB	// Read RXBBF C3(MSB)
    SPIRead	1EC	// Read RXBBF C3(LSB)
    SPIRead	1E6	// Read RXBBF R2346
    SPIWrite	1DB,20	// Set TIA selcc[2:0]
    SPIWrite	1DD,00	// Set RX TIA1 C MSB[6:0]
    SPIWrite	1DF,00	// Set RX TIA2 C MSB[6:0]
    SPIWrite	1DC,47	// Set RX TIA1 C LSB[5:0]
    SPIWrite	1DE,47	// Set RX TIA2 C LSB[5:0]
    
    //************************************************************
    // TX Secondary Filter Calibration Setup:  Real Bandwidth
    // 20.000000MHz, 3dB Corner @ 100.000000MHz
    //************************************************************
    SPIWrite	0D2,04	// TX Secondary Filter PDF Cap cal[5:0]
    SPIWrite	0D1,0C	// TX Secondary Filter PDF Res cal[3:0]
    SPIWrite	0D0,57	// Pdampbias 
    
    //************************************************************
    // ADC Setup:  Tune ADC Performance based on RX analog filter tune
    // corner.  Real Bandwidth: 17.335654 MHz, ADC Clock Frequency:
    // 330.000000 MHz.  The values in registers 0x200 - 0x227 need to be
    // calculated using the equations in the Calibration Guide.
    //************************************************************
    SPIRead	1EB	// Read RxBBF C3 MSB after calibration
    SPIRead	1EC	// Read RxBBF C3 LSB after calibration
    SPIRead	1E6	// Read RxBBF R3 after calibration
    
    SPIWrite	200,00
    SPIWrite	201,00
    SPIWrite	202,00
    SPIWrite	203,24
    SPIWrite	204,24
    SPIWrite	205,00
    SPIWrite	206,00
    SPIWrite	207,65
    SPIWrite	208,4C
    SPIWrite	209,30
    SPIWrite	20A,3D
    SPIWrite	20B,30
    SPIWrite	20C,3F
    SPIWrite	20D,2E
    SPIWrite	20E,00
    SPIWrite	20F,68
    SPIWrite	210,68
    SPIWrite	211,68
    SPIWrite	212,3B
    SPIWrite	213,3B
    SPIWrite	214,3B
    SPIWrite	215,3D
    SPIWrite	216,3D
    SPIWrite	217,3D
    SPIWrite	218,2E
    SPIWrite	219,A0
    SPIWrite	21A,22
    SPIWrite	21B,16
    SPIWrite	21C,A0
    SPIWrite	21D,22
    SPIWrite	21E,16
    SPIWrite	21F,A0
    SPIWrite	220,22
    SPIWrite	221,2D
    SPIWrite	222,2D
    SPIWrite	223,40
    SPIWrite	224,40
    SPIWrite	225,2C
    SPIWrite	226,00
    SPIWrite	227,00
    //************************************************************
    // Setup and Run BB DC and RF DC Offset Calibrations
    //************************************************************
    SPIWrite	193,3F
    SPIWrite	190,0F	// Set BBDC tracking shift M value, only applies when BB DC tracking enabled
    SPIWrite	194,01	// BBDC Cal setting
    SPIWrite	016,01	// Start BBDC offset cal
    WAIT_CALDONE	BBDC,2000	// BBDC Max Cal Time: 7345.455 us. Cal done when 0x016[0]==0
    
    SPIWrite	185,20	// Set RF DC offset Wait Count
    SPIWrite	186,28	// Set RF DC Offset Count[7:0]
    SPIWrite	187,34	// Settings for RF DC cal
    SPIWrite	18B,83	// Settings for RF DC cal
    SPIWrite	188,06	// Settings for RF DC cal
    SPIWrite	189,30	// Settings for RF DC cal
    SPIWrite	016,02	// Start RFDC offset cal
    WAIT_CALDONE	RFDC,2000	// RFDC Max Cal Time: 88426.800 us
    
    //************************************************************
    // Tx Quadrature Calibration Settings
    //************************************************************
    SPIRead	0A3	// Masked Read:  Read lower 6 bits, overwrite [7:6] below
    SPIWrite	0A0,15	// Set TxQuadcal NCO frequency
    SPIWrite	0A3,00	// Set TxQuadcal NCO frequency (Only update bits [7:6])
    SPIWrite	0A1,7B	// Tx Quad Cal Configuration, Phase and Gain Cal Enable
    SPIWrite	0A9,FF	// Set Tx Quad Cal Count
    SPIWrite	0A2,7F	// Set Tx Quad Cal Kexp
    SPIWrite	0A5,01	// Set Tx Quad Cal Magnitude Threshhold
    SPIWrite	0A6,01	// Set Tx Quad Cal Magnitude Threshhold
    SPIWrite	0AA,2C	// Set Tx Quad Cal Gain Table index
    SPIWrite	0A4,F0	// Set Tx Quad Cal Settle Count
    SPIWrite	0AE,04	// Set Tx Quad Cal LPF Gain index incase Split table mode used
    
    SPIWrite	169,C0	// Disable Rx Quadrature Calibration before Running Tx Quadrature Calibration
    SPIWrite	016,10	// Start Tx Quad cal
    WAIT_CALDONE	TXQUAD,2000	// Wait for cal to complete (Done when 0x016[4]==0)
    
    SPIWrite	16A,75	// Set Kexp Phase
    SPIWrite	16B,95	// Set Kexp Amplitude & Prevent Positive Gain Bit
    SPIWrite	169,CF	// Enable Rx Quadrature Calibration Tracking
    SPIWrite	18B,AD	// Enable BB and RF DC Tracking Calibrations
    SPIWrite	012,10	// Cals done, Set PPORT Config
    SPIWrite	013,01	// Set ENSM FDD/TDD bit
    SPIWrite	015,0C	// Set Dual Synth Mode, FDD External Control bits properly
    
    //************************************************************
    // Set Tx Attenuation: Tx1: 10.00 dB,  Tx2: 10.00 dB 
    //************************************************************
    SPIWrite	073,28
    SPIWrite	074,00
    SPIWrite	075,28
    SPIWrite	076,00
    //************************************************************
    // Setup RSSI and Power Measurement Duration Registers
    //************************************************************
    SPIWrite	150,0E	// RSSI Measurement Duration 0, 1
    SPIWrite	151,00	// RSSI Measurement Duration 2, 3
    SPIWrite	152,FF	// RSSI Weighted Multiplier 0
    SPIWrite	153,00	// RSSI Weighted Multiplier 1
    SPIWrite	154,00	// RSSI Weighted Multiplier 2
    SPIWrite	155,00	// RSSI Weighted Multiplier 3
    SPIWrite	156,00	// RSSI Delay
    SPIWrite	157,00	// RSSI Wait
    SPIWrite	158,0D	// RSSI Mode Select
    SPIWrite	15C,67	// Power Measurement Duration
    
    

  •  here is the spectrum and code

    //************************************************************
    // AD9361 R2 Auto Generated Initialization Script:  This script was
    // generated using the AD9361 Customer software Version 2.1.4
    //************************************************************
    // Profile: Custom
    // REFCLK_IN: 40.000 MHz
    
    RESET_FPGA	
    RESET_DUT	
    
    BlockWrite	2,6	// Set ADI FPGA SPI to 20Mhz
    SPIWrite	3DF,01	// Required for proper operation
    ReadPartNumber
    SPIWrite	2A6,0E	// Enable Master Bias
    SPIWrite	2A8,0E	// Set Bandgap Trim
    REFCLK_Scale	40.000000,1,2	// Sets local variables in script engine, user can ignore
    SPIWrite	2AB,07	// Set RF PLL reflclk scale to REFCLK * 2
    SPIWrite	2AC,FF	// Set RF PLL reflclk scale to REFCLK * 2
    SPIWrite	009,17	// Enable Clocks
    WAIT	20	// waits 20 ms
    //************************************************************
    // Set BBPLL Frequency: 1320.000000
    //************************************************************
    SPIWrite	045,00	// Set BBPLL reflclk scale to REFCLK /1
    SPIWrite	046,05	// Set BBPLL Loop Filter Charge Pump current
    SPIWrite	048,E8	// Set BBPLL Loop Filter C1, R1
    SPIWrite	049,5B	// Set BBPLL Loop Filter R2, C2, C1
    SPIWrite	04A,35	// Set BBPLL Loop Filter C3,R2
    SPIWrite	04B,E0	// Allow calibration to occur and set cal count to 1024 for max accuracy
    SPIWrite	04E,10	// Set calibration clock to REFCLK/4 for more accuracy
    SPIWrite	043,00	// BBPLL Freq Word (Fractional[7:0])
    SPIWrite	042,00	// BBPLL Freq Word (Fractional[15:8])
    SPIWrite	041,00	// BBPLL Freq Word (Fractional[23:16])
    SPIWrite	044,21	// BBPLL Freq Word (Integer[7:0])
    SPIWrite	03F,05	// Start BBPLL Calibration
    SPIWrite	03F,01	// Clear BBPLL start calibration bit
    SPIWrite	04C,86	// Increase BBPLL KV and phase margin
    SPIWrite	04D,01	// Increase BBPLL KV and phase margin
    SPIWrite	04D,05	// Increase BBPLL KV and phase margin
    WAIT_CALDONE	BBPLL,2000	// Wait for BBPLL to lock, Timeout 2sec, Max BBPLL VCO Cal Time: 345.600 us (Done when 0x05E[7]==1)
    
    SPIRead	05E	// Check BBPLL locked status  (0x05E[7]==1 is locked)
    
    SPIWrite	002,62	// Setup Tx Digital Filters/ Channels
    SPIWrite	003,24	// Setup Rx Digital Filters/ Channels
    SPIWrite	004,43	// Select Rx input pin(A,B,C)/ Tx out pin (A,B)
    SPIWrite	00A,12	// Set BBPLL post divide rate
    
    //************************************************************
    // Program Tx FIR: C:\Program Files (x86)\Analog Devices\AD9361
    // Evaluation Software v2.1.5
    // (64-bit)\DigitalFilters\128tapFilter.ftr
    //************************************************************
    SPIWrite	065,FA	// Enable clock to Tx FIR Filter and set Filter gain Setting 
    SPIWrite	060,00	// Write FIR coefficient address
    SPIWrite	061,01	// Write FIR coefficient data[7:0]
    SPIWrite	062,00	// Write FIR coefficient data[15:8]
    SPIWrite	065,FE	// Set Write EN to push data into FIR filter register map
    SPIWrite	064,00	// Write to Read only register to delay ~1us
    SPIWrite	064,00	// Write to Read only register to delay ~1us
    SPIWrite	060,01
    SPIWrite	061,F1
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,02
    SPIWrite	061,CF
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,03
    SPIWrite	061,C0
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,04
    SPIWrite	061,E8
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,05
    SPIWrite	061,20
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,06
    SPIWrite	061,1A
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,07
    SPIWrite	061,E3
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,08
    SPIWrite	061,E1
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,09
    SPIWrite	061,1F
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,0A
    SPIWrite	061,28
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,0B
    SPIWrite	061,DF
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,0C
    SPIWrite	061,CC
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,0D
    SPIWrite	061,24
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,0E
    SPIWrite	061,43
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,0F
    SPIWrite	061,DB
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,10
    SPIWrite	061,AC
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,11
    SPIWrite	061,26
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,12
    SPIWrite	061,68
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,13
    SPIWrite	061,DB
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,14
    SPIWrite	061,80
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,15
    SPIWrite	061,22
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,16
    SPIWrite	061,9A
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,17
    SPIWrite	061,E2
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,18
    SPIWrite	061,47
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,19
    SPIWrite	061,17
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,1A
    SPIWrite	061,DB
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,1B
    SPIWrite	061,F3
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,1C
    SPIWrite	061,FF
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,1D
    SPIWrite	061,FF
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,1E
    SPIWrite	061,2B
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,1F
    SPIWrite	061,13
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,20
    SPIWrite	061,A5
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,21
    SPIWrite	061,D7
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,22
    SPIWrite	061,90
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,23
    SPIWrite	061,46
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,24
    SPIWrite	061,35
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,25
    SPIWrite	061,97
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,26
    SPIWrite	061,0E
    SPIWrite	062,02
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,27
    SPIWrite	061,95
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,28
    SPIWrite	061,A7
    SPIWrite	062,FD
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,29
    SPIWrite	061,36
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,2A
    SPIWrite	061,AE
    SPIWrite	062,02
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,2B
    SPIWrite	061,0D
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,2C
    SPIWrite	061,F0
    SPIWrite	062,FC
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,2D
    SPIWrite	061,A1
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,2E
    SPIWrite	061,83
    SPIWrite	062,03
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,2F
    SPIWrite	061,C6
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,30
    SPIWrite	061,F3
    SPIWrite	062,FB
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,31
    SPIWrite	061,B6
    SPIWrite	062,FD
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,32
    SPIWrite	061,B7
    SPIWrite	062,04
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,33
    SPIWrite	061,F8
    SPIWrite	062,02
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,34
    SPIWrite	061,6D
    SPIWrite	062,FA
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,35
    SPIWrite	061,1A
    SPIWrite	062,FC
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,36
    SPIWrite	061,BE
    SPIWrite	062,06
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,37
    SPIWrite	061,41
    SPIWrite	062,05
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,38
    SPIWrite	061,87
    SPIWrite	062,F7
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,39
    SPIWrite	061,98
    SPIWrite	062,F8
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,3A
    SPIWrite	061,60
    SPIWrite	062,0B
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,3B
    SPIWrite	061,6D
    SPIWrite	062,0B
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,3C
    SPIWrite	061,88
    SPIWrite	062,EE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,3D
    SPIWrite	061,40
    SPIWrite	062,EA
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,3E
    SPIWrite	061,86
    SPIWrite	062,27
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,3F
    SPIWrite	061,09
    SPIWrite	062,72
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,40
    SPIWrite	061,09
    SPIWrite	062,72
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,41
    SPIWrite	061,86
    SPIWrite	062,27
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,42
    SPIWrite	061,40
    SPIWrite	062,EA
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,43
    SPIWrite	061,88
    SPIWrite	062,EE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,44
    SPIWrite	061,6D
    SPIWrite	062,0B
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,45
    SPIWrite	061,60
    SPIWrite	062,0B
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,46
    SPIWrite	061,98
    SPIWrite	062,F8
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,47
    SPIWrite	061,87
    SPIWrite	062,F7
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,48
    SPIWrite	061,41
    SPIWrite	062,05
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,49
    SPIWrite	061,BE
    SPIWrite	062,06
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,4A
    SPIWrite	061,1A
    SPIWrite	062,FC
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,4B
    SPIWrite	061,6D
    SPIWrite	062,FA
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,4C
    SPIWrite	061,F8
    SPIWrite	062,02
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,4D
    SPIWrite	061,B7
    SPIWrite	062,04
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,4E
    SPIWrite	061,B6
    SPIWrite	062,FD
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,4F
    SPIWrite	061,F3
    SPIWrite	062,FB
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,50
    SPIWrite	061,C6
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,51
    SPIWrite	061,83
    SPIWrite	062,03
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,52
    SPIWrite	061,A1
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,53
    SPIWrite	061,F0
    SPIWrite	062,FC
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,54
    SPIWrite	061,0D
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,55
    SPIWrite	061,AE
    SPIWrite	062,02
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,56
    SPIWrite	061,36
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,57
    SPIWrite	061,A7
    SPIWrite	062,FD
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,58
    SPIWrite	061,95
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,59
    SPIWrite	061,0E
    SPIWrite	062,02
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,5A
    SPIWrite	061,97
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,5B
    SPIWrite	061,35
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,5C
    SPIWrite	061,46
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,5D
    SPIWrite	061,90
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,5E
    SPIWrite	061,D7
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,5F
    SPIWrite	061,A5
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,60
    SPIWrite	061,13
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,61
    SPIWrite	061,2B
    SPIWrite	062,01
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,62
    SPIWrite	061,FF
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,63
    SPIWrite	061,FF
    SPIWrite	062,FE
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,64
    SPIWrite	061,F3
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,65
    SPIWrite	061,DB
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,66
    SPIWrite	061,17
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,67
    SPIWrite	061,47
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,68
    SPIWrite	061,E2
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,69
    SPIWrite	061,9A
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,6A
    SPIWrite	061,22
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,6B
    SPIWrite	061,80
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,6C
    SPIWrite	061,DB
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,6D
    SPIWrite	061,68
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,6E
    SPIWrite	061,26
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,6F
    SPIWrite	061,AC
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,70
    SPIWrite	061,DB
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,71
    SPIWrite	061,43
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,72
    SPIWrite	061,24
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,73
    SPIWrite	061,CC
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,74
    SPIWrite	061,DF
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,75
    SPIWrite	061,28
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,76
    SPIWrite	061,1F
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,77
    SPIWrite	061,E1
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,78
    SPIWrite	061,E3
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,79
    SPIWrite	061,1A
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,7A
    SPIWrite	061,20
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,7B
    SPIWrite	061,E8
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,7C
    SPIWrite	061,C0
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,7D
    SPIWrite	061,CF
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,7E
    SPIWrite	061,F1
    SPIWrite	062,FF
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	060,7F
    SPIWrite	061,01
    SPIWrite	062,00
    SPIWrite	065,FE
    SPIWrite	064,00
    SPIWrite	064,00
    SPIWrite	065,F8	// Disable clock to Tx Filter
    
    //************************************************************
    // Setup the Parallel Port (Digital Data Interface)
    //************************************************************
    SPIWrite	010,C8	// I/O Config.  Tx Swap IQ; Rx Swap IQ; Tx CH Swap, Rx CH Swap; Rx Frame Mode; 2R2T bit; Invert data bus; Invert DATA_CLK
    SPIWrite	011,00	// I/O Config.  Alt Word Order; -Rx1; -Rx2; -Tx1; -Tx2; Invert Rx Frame; Delay Rx Data
    SPIWrite	012,10	// I/O Config.  Rx=2*Tx; Swap Ports; SDR; LVDS; Half Duplex; Single Port; Full Port; Swap Bits
    SPIWrite	006,0F	// PPORT Rx Delay (adjusts Tco Dataclk->Data)
    SPIWrite	007,00	// PPORT TX Delay (adjusts setup/hold FBCLK->Data)
    
    SPIWrite	03C,21	// CLK_OUT slew; LVDS: Rx Term; Bypass Bias R; Tx LO VCM; Bias[2:0]
    SPIWrite	03D,00	// LVDS polarity invert
    SPIWrite	03E,00	// LVDS polarity invert
    
    //************************************************************
    // Setup AuxDAC
    //************************************************************
    SPIWrite	018,00	// AuxDAC1 Word[9:2]
    SPIWrite	019,00	// AuxDAC2 Word[9:2]
    SPIWrite	01A,00	// AuxDAC1 Config and Word[1:0]
    SPIWrite	01B,00	// AuxDAC2 Config and Word[1:0]
    SPIWrite	023,FF	// AuxDAC Manaul/Auto Control
    SPIWrite	026,00	// AuxDAC Manual Select Bit/GPO Manual Select
    SPIWrite	030,00	// AuxDAC1 Rx Delay
    SPIWrite	031,00	// AuxDAC1 Tx Delay
    SPIWrite	032,00	// AuxDAC2 Rx Delay
    SPIWrite	033,00	// AuxDAC2 Tx Delay
    
    //************************************************************
    // Setup AuxADC
    //************************************************************
    SPIWrite	00B,00	// Temp Sensor Setup (Offset)
    SPIWrite	00C,00	// Temp Sensor Setup (Temp Window)
    SPIWrite	00D,03	// Temp Sensor Setup (Periodic Measure)
    SPIWrite	00F,04	// Temp Sensor Setup (Decimation)
    SPIWrite	01C,10	// AuxADC Setup (Clock Div)
    SPIWrite	01D,01	// AuxADC Setup (Decimation/Enable)
    
    //************************************************************
    // Setup Control Outs
    //************************************************************
    SPIWrite	035,00	// Ctrl Out index
    SPIWrite	036,FF	// Ctrl Out [7:0] output enable
    
    //************************************************************
    // Setup GPO
    //************************************************************
    SPIWrite	03A,27	// Set number of REFCLK cycles for 1us delay timer
    SPIWrite	020,00	// GPO Auto Enable Setup in RX and TX
    SPIWrite	027,03	// GPO Manual and GPO auto value in ALERT
    SPIWrite	028,00	// GPO_0 RX Delay
    SPIWrite	029,00	// GPO_1 RX Delay
    SPIWrite	02A,00	// GPO_2 RX Delay
    SPIWrite	02B,00	// GPO_3 RX Delay
    SPIWrite	02C,00	// GPO_0 TX Delay
    SPIWrite	02D,00	// GPO_1 TX Delay
    SPIWrite	02E,00	// GPO_2 TX Delay
    SPIWrite	02F,00	// GPO_3 TX Delay
    
    //************************************************************
    // Setup RF PLL non-frequency-dependent registers
    //************************************************************
    SPIWrite	261,00	// Set Rx LO Power mode
    SPIWrite	2A1,00	// Set Tx LO Power mode
    SPIWrite	248,0B	// Enable Rx VCO LDO
    SPIWrite	288,0B	// Enable Tx VCO LDO
    SPIWrite	246,02	// Set VCO Power down TCF bits
    SPIWrite	286,02	// Set VCO Power down TCF bits
    SPIWrite	249,8E	// Set VCO cal length
    SPIWrite	289,8E	// Set VCO cal length
    SPIWrite	23B,80	// Enable Rx VCO cal
    SPIWrite	27B,80	// Enable Tx VCO cal
    SPIWrite	243,0D	// Set Rx prescaler bias
    SPIWrite	283,0D	// Set Tx prescaler bias
    SPIWrite	23D,10	// Clear Half VCO cal clock setting
    SPIWrite	27D,10	// Clear Half VCO cal clock setting
    
    SPIWrite	015,0C	// Set Dual Synth mode bit
    SPIWrite	014,15	// Set Force ALERT State bit
    SPIWrite	013,01	// Set ENSM FDD mode
    WAIT	1	// waits 1 ms
    SPIWrite	23D,14	// Start RX CP cal
    WAIT_CALDONE	RXCP,100	// Wait for CP cal to complete, Max RXCP Cal time: 460.800 (us)(Done when 0x244[7]==1)
    
    SPIWrite	27D,14	// Start TX CP cal
    WAIT_CALDONE	TXCP,100	// Wait for CP cal to complete, Max TXCP Cal time: 460.800 (us)(Done when 0x284[7]==1)
    
    //************************************************************
    // FDD RX,TX Synth Frequency: 5400.000000,5696.000000 MHz
    //************************************************************
    //************************************************************
    // Setup Rx Frequency-Dependent Syntheisizer Registers
    //************************************************************
    SPIWrite	23A,4D	// Set VCO Output level[3:0]
    SPIWrite	239,C1	// Set Init ALC Value[3:0] and VCO Varactor[3:0]
    SPIWrite	242,14	// Set VCO Bias Tcf[1:0] and VCO Bias Ref[2:0]
    SPIWrite	238,78	// Set VCO Cal Offset[3:0]
    SPIWrite	245,00	// Set VCO Cal Ref Tcf[2:0]
    SPIWrite	251,0C	// Set VCO Varactor Reference[3:0]
    SPIWrite	250,70	// Set VCO Varactor Ref Tcf[2:0] and VCO Varactor Offset[3:0]
    SPIWrite	23B,89	// Set Synth Loop Filter charge pump current (Icp)
    SPIWrite	23E,F6	// Set Synth Loop Filter C2 and C1
    SPIWrite	23F,D5	// Set Synth Loop Filter  R1 and C3
    SPIWrite	240,0E	// Set Synth Loop Filter R3
    
    //************************************************************
    // Setup Tx Frequency-Dependent Syntheisizer Registers
    //************************************************************
    SPIWrite	27A,4D	// Set VCO Output level[3:0]
    SPIWrite	279,C1	// Set Init ALC Value[3:0] and VCO Varactor[3:0]
    SPIWrite	282,14	// Set VCO Bias Tcf[1:0] and VCO Bias Ref[2:0]
    SPIWrite	278,78	// Set VCO Cal Offset[3:0]
    SPIWrite	285,00	// Set VCO Cal Ref Tcf[2:0]
    SPIWrite	291,0C	// Set VCO Varactor Reference[3:0]
    SPIWrite	290,70	// Set VCO Varactor Ref Tcf[2:0] and VCO Varactor Offset[3:0]
    SPIWrite	27B,88	// Set Synth Loop Filter charge pump current (Icp)
    SPIWrite	27E,F6	// Set Synth Loop Filter C2 and C1
    SPIWrite	27F,D5	// Set Synth Loop Filter  R1 and C3
    SPIWrite	280,0E	// Set Synth Loop Filter R3
    
    //************************************************************
    // Write Rx and Tx Frequency Words
    //************************************************************
    SPIWrite	233,00	// Write Rx Synth Fractional Freq Word[7:0]
    SPIWrite	234,00	// Write Rx Synth Fractional Freq Word[15:8]
    SPIWrite	235,00	// Write Rx Synth Fractional Freq Word[22:16]
    SPIWrite	232,00	// Write Rx Synth Integer Freq Word[10:8]
    SPIWrite	231,87	// Write Rx Synth Integer Freq Word[7:0]
    SPIWrite	005,00	// Set LO divider setting
    SPIWrite	273,2D	// Write Tx Synth Fractional Freq Word[7:0]
    SPIWrite	274,33	// Write Tx Synth Fractional Freq Word[15:8]
    SPIWrite	275,33	// Write Tx Synth Fractional Freq Word[22:16]
    SPIWrite	272,00	// Write Tx Synth Integer Freq Word[10:8]
    SPIWrite	271,8E	// Write Tx Synth Integer Freq Word[7:0] (starts VCO cal)
    SPIWrite	005,00	// Set LO divider setting
    SPIRead	247	// Check RX RF PLL lock status (0x247[1]==1 is locked)
    SPIRead	287	// Check TX RF PLL lock status (0x287[1]==1 is locked)
    
    //************************************************************
    // Program Mixer GM Sub-table
    //************************************************************
    SPIWrite	13F,02	// Start Clock
    SPIWrite	138,0F	// Addr Table Index
    SPIWrite	139,78	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,00	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,0E	// Addr Table Index
    SPIWrite	139,74	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,0D	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,0D	// Addr Table Index
    SPIWrite	139,70	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,15	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,0C	// Addr Table Index
    SPIWrite	139,6C	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,1B	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,0B	// Addr Table Index
    SPIWrite	139,68	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,21	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,0A	// Addr Table Index
    SPIWrite	139,64	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,25	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,09	// Addr Table Index
    SPIWrite	139,60	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,29	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,08	// Addr Table Index
    SPIWrite	139,5C	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,2C	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,07	// Addr Table Index
    SPIWrite	139,58	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,2F	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,06	// Addr Table Index
    SPIWrite	139,54	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,31	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,05	// Addr Table Index
    SPIWrite	139,50	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,33	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,04	// Addr Table Index
    SPIWrite	139,4C	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,34	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,03	// Addr Table Index
    SPIWrite	139,48	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,35	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,02	// Addr Table Index
    SPIWrite	139,30	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,3A	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,01	// Addr Table Index
    SPIWrite	139,18	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,3D	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	138,00	// Addr Table Index
    SPIWrite	139,00	// Gain
    SPIWrite	13A,00	// Bias
    SPIWrite	13B,3E	// GM
    SPIWrite	13F,06	// Write Words
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	13F,02	// Clear Write Bit
    SPIWrite	13C,00	// Delay for 3 ADCCLK/16 clock cycles (Dummy Write)
    SPIWrite	13C,00	// Delay ~1us (Dummy Write)
    SPIWrite	13F,00	// Stop Clock
    
    //************************************************************
    // Program Rx Gain Tables with GainTable5000MHz.csv
    //************************************************************
    
    SPIWrite	137,1A	// Start Gain Table Clock
    SPIWrite	130,00	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,01	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,02	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,03	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,04	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,05	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,01	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,06	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,02	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,07	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,03	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,08	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,01	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,09	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,02	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,0A	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,03	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,0B	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,04	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,0C	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,05	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,0D	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,06	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,0E	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,07	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,0F	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,08	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,10	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,09	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,11	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0A	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,12	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0B	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,13	// Gain Table Index
    SPIWrite	131,01	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0C	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,14	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,08	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,15	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,09	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,16	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0A	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,17	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0B	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,18	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0C	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,19	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0D	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,1A	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0E	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,1B	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,0F	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,1C	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2A	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,1D	// Gain Table Index
    SPIWrite	131,02	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2B	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,1E	// Gain Table Index
    SPIWrite	131,04	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,27	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,1F	// Gain Table Index
    SPIWrite	131,04	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,28	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,20	// Gain Table Index
    SPIWrite	131,04	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,29	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,21	// Gain Table Index
    SPIWrite	131,04	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2A	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,22	// Gain Table Index
    SPIWrite	131,04	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2B	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,23	// Gain Table Index
    SPIWrite	131,04	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2C	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,24	// Gain Table Index
    SPIWrite	131,04	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2D	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,25	// Gain Table Index
    SPIWrite	131,24	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,20	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,26	// Gain Table Index
    SPIWrite	131,24	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,21	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,27	// Gain Table Index
    SPIWrite	131,24	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,22	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,28	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,20	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,29	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,21	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,2A	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,22	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,2B	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,23	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,2C	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,24	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,2D	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,25	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,2E	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,26	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,2F	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,27	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,30	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,28	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,31	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,29	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,32	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2A	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,33	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2B	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,34	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2C	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,35	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2D	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,36	// Gain Table Index
    SPIWrite	131,44	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2E	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,37	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2E	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,38	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,2F	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,39	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,30	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,3A	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,31	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,3B	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,32	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,3C	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,33	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,3D	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,34	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,3E	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,35	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,3F	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,36	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,40	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,37	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,41	// Gain Table Index
    SPIWrite	131,64	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,42	// Gain Table Index
    SPIWrite	131,65	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,43	// Gain Table Index
    SPIWrite	131,66	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,44	// Gain Table Index
    SPIWrite	131,67	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,45	// Gain Table Index
    SPIWrite	131,68	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,46	// Gain Table Index
    SPIWrite	131,69	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,47	// Gain Table Index
    SPIWrite	131,6A	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,48	// Gain Table Index
    SPIWrite	131,6B	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,49	// Gain Table Index
    SPIWrite	131,6C	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,4A	// Gain Table Index
    SPIWrite	131,6D	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,4B	// Gain Table Index
    SPIWrite	131,6E	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,4C	// Gain Table Index
    SPIWrite	131,6F	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,38	// TIA & LPF Word
    SPIWrite	133,20	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,4D	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,4E	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,4F	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,50	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,51	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,52	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,53	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,54	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,55	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,56	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,57	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,58	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,59	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	130,5A	// Gain Table Index
    SPIWrite	131,00	// Ext LNA, Int LNA, & Mixer Gain Word
    SPIWrite	132,00	// TIA & LPF Word
    SPIWrite	133,00	// DC Cal bit & Dig Gain Word
    SPIWrite	137,1E	// Write Words
    SPIWrite	134,00	// Dummy Write to delay 3 ADCCLK/16 cycles
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	137,1A	// Clear Write Bit
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	134,00	// Dummy Write to delay ~1us
    SPIWrite	137,00	// Stop Gain Table Clock
    //************************************************************
    // Setup Rx Manual Gain Registers
    //************************************************************
    SPIWrite	0FA,E0	// Gain Control Mode Select
    SPIWrite	0FB,08	// Table, Digital Gain, Man Gain Ctrl
    SPIWrite	0FC,23	// Incr Step Size, ADC Overrange Size
    SPIWrite	0FD,4C	// Max Full/LMT Gain Table Index
    SPIWrite	0FE,44	// Decr Step Size, Peak Overload Time
    SPIWrite	100,6F	// Max Digital Gain
    SPIWrite	104,2F	// ADC Small Overload Threshold
    SPIWrite	105,3A	// ADC Large Overload Threshold
    SPIWrite	107,2B	// Small LMT Overload Threshold
    SPIWrite	108,31	// Large LMT Overload Threshold
    SPIWrite	109,4C	// Rx1 Full/LMT Gain Index
    SPIWrite	10A,58	// Rx1 LPF Gain Index
    SPIWrite	10B,00	// Rx1 Digital Gain Index
    SPIWrite	10C,4C	// Rx2 Full/LMT Gain Index
    SPIWrite	10D,18	// Rx2 LPF Gain Index
    SPIWrite	10E,00	// Rx2 Digital Gain Index
    SPIWrite	114,30	// Low Power Threshold
    SPIWrite	11A,27	// Initial LMT Gain Limit
    SPIWrite	081,00	// Tx Symbol Gain Control
    //************************************************************
    // RX Baseband Filter Tuning (Real BW: 20.000000 MHz) 3dB Filter
    // Corner @ 28.000000 MHz)
    //************************************************************
    SPIWrite	1FB,14	// RX Freq Corner (MHz)
    SPIWrite	1FC,00	// RX Freq Corner (Khz)
    SPIWrite	1F8,06	// Rx BBF Tune Divider[7:0]
    SPIWrite	1F9,1E	// RX BBF Tune Divider[8]
    
    SPIWrite	1D5,3F	// Set Rx Mix LO CM
    SPIWrite	1C0,03	// Set GM common mode
    SPIWrite	1E2,02	// Enable Rx1 Filter Tuner 
    SPIWrite	1E3,02	// Enable Rx2 Filter Tuner 
    SPIWrite	016,80	// Start RX Filter Tune
    WAIT_CALDONE	RXFILTER,2000	// Wait for RX filter to tune, Max Cal Time: 2.773 us (Done when 0x016[7]==0)
    
    SPIWrite	1E2,03	// Disable Rx Filter Tuner (Rx1)
    SPIWrite	1E3,03	// Disable Rx Filter Tuner (Rx2)
    //************************************************************
    // TX Baseband Filter Tuning (Real BW: 20.000000 MHz) 3dB Filter
    // Corner @ 32.000000 MHz)
    //************************************************************
    SPIWrite	0D6,05	// TX BBF Tune Divider[7:0]
    SPIWrite	0D7,1E	// TX BBF Tune Divider[8]
    
    SPIWrite	0CA,22	// Enable Tx Filter Tuner
    SPIWrite	016,40	// Start Tx Filter Tune
    WAIT_CALDONE	TXFILTER,2000	// Wait for TX filter to tune, Max Cal Time: 1.345 us (Done when 0x016[6]==0)
    
    SPIWrite	0CA,26	// Disable Tx Filter Tuner (Both Channels)
    //************************************************************
    // RX TIA Setup:  Setup values scale based on RxBBF calibration
    // results.  See information in Calibration Guide. 
    //************************************************************
    SPIRead	1EB	// Read RXBBF C3(MSB)
    SPIRead	1EC	// Read RXBBF C3(LSB)
    SPIRead	1E6	// Read RXBBF R2346
    SPIWrite	1DB,20	// Set TIA selcc[2:0]
    SPIWrite	1DD,00	// Set RX TIA1 C MSB[6:0]
    SPIWrite	1DF,00	// Set RX TIA2 C MSB[6:0]
    SPIWrite	1DC,47	// Set RX TIA1 C LSB[5:0]
    SPIWrite	1DE,47	// Set RX TIA2 C LSB[5:0]
    
    //************************************************************
    // TX Secondary Filter Calibration Setup:  Real Bandwidth
    // 20.000000MHz, 3dB Corner @ 100.000000MHz
    //************************************************************
    SPIWrite	0D2,04	// TX Secondary Filter PDF Cap cal[5:0]
    SPIWrite	0D1,0C	// TX Secondary Filter PDF Res cal[3:0]
    SPIWrite	0D0,57	// Pdampbias 
    
    //************************************************************
    // ADC Setup:  Tune ADC Performance based on RX analog filter tune
    // corner.  Real Bandwidth: 17.335654 MHz, ADC Clock Frequency:
    // 330.000000 MHz.  The values in registers 0x200 - 0x227 need to be
    // calculated using the equations in the Calibration Guide.
    //************************************************************
    SPIRead	1EB	// Read RxBBF C3 MSB after calibration
    SPIRead	1EC	// Read RxBBF C3 LSB after calibration
    SPIRead	1E6	// Read RxBBF R3 after calibration
    
    SPIWrite	200,00
    SPIWrite	201,00
    SPIWrite	202,00
    SPIWrite	203,24
    SPIWrite	204,24
    SPIWrite	205,00
    SPIWrite	206,00
    SPIWrite	207,65
    SPIWrite	208,4C
    SPIWrite	209,30
    SPIWrite	20A,3D
    SPIWrite	20B,30
    SPIWrite	20C,3F
    SPIWrite	20D,2E
    SPIWrite	20E,00
    SPIWrite	20F,68
    SPIWrite	210,68
    SPIWrite	211,68
    SPIWrite	212,3B
    SPIWrite	213,3B
    SPIWrite	214,3B
    SPIWrite	215,3D
    SPIWrite	216,3D
    SPIWrite	217,3D
    SPIWrite	218,2E
    SPIWrite	219,A0
    SPIWrite	21A,22
    SPIWrite	21B,16
    SPIWrite	21C,A0
    SPIWrite	21D,22
    SPIWrite	21E,16
    SPIWrite	21F,A0
    SPIWrite	220,22
    SPIWrite	221,2D
    SPIWrite	222,2D
    SPIWrite	223,40
    SPIWrite	224,40
    SPIWrite	225,2C
    SPIWrite	226,00
    SPIWrite	227,00
    //************************************************************
    // Setup and Run BB DC and RF DC Offset Calibrations
    //************************************************************
    SPIWrite	193,3F
    SPIWrite	190,0F	// Set BBDC tracking shift M value, only applies when BB DC tracking enabled
    SPIWrite	194,01	// BBDC Cal setting
    SPIWrite	016,01	// Start BBDC offset cal
    WAIT_CALDONE	BBDC,2000	// BBDC Max Cal Time: 7345.455 us. Cal done when 0x016[0]==0
    
    SPIWrite	185,20	// Set RF DC offset Wait Count
    SPIWrite	186,28	// Set RF DC Offset Count[7:0]
    SPIWrite	187,34	// Settings for RF DC cal
    SPIWrite	18B,83	// Settings for RF DC cal
    SPIWrite	188,06	// Settings for RF DC cal
    SPIWrite	189,30	// Settings for RF DC cal
    SPIWrite	016,02	// Start RFDC offset cal
    WAIT_CALDONE	RFDC,2000	// RFDC Max Cal Time: 88426.800 us
    
    //************************************************************
    // Tx Quadrature Calibration Settings
    //************************************************************
    SPIRead	0A3	// Masked Read:  Read lower 6 bits, overwrite [7:6] below
    SPIWrite	0A0,15	// Set TxQuadcal NCO frequency
    SPIWrite	0A3,00	// Set TxQuadcal NCO frequency (Only update bits [7:6])
    SPIWrite	0A1,7B	// Tx Quad Cal Configuration, Phase and Gain Cal Enable
    SPIWrite	0A9,FF	// Set Tx Quad Cal Count
    SPIWrite	0A2,7F	// Set Tx Quad Cal Kexp
    SPIWrite	0A5,01	// Set Tx Quad Cal Magnitude Threshhold
    SPIWrite	0A6,01	// Set Tx Quad Cal Magnitude Threshhold
    SPIWrite	0AA,2C	// Set Tx Quad Cal Gain Table index
    SPIWrite	0A4,F0	// Set Tx Quad Cal Settle Count
    SPIWrite	0AE,04	// Set Tx Quad Cal LPF Gain index incase Split table mode used
    
    SPIWrite	169,C0	// Disable Rx Quadrature Calibration before Running Tx Quadrature Calibration
    SPIWrite	016,10	// Start Tx Quad cal
    WAIT_CALDONE	TXQUAD,2000	// Wait for cal to complete (Done when 0x016[4]==0)
    
    SPIWrite	16A,75	// Set Kexp Phase
    SPIWrite	16B,95	// Set Kexp Amplitude & Prevent Positive Gain Bit
    SPIWrite	169,CF	// Enable Rx Quadrature Calibration Tracking
    SPIWrite	18B,AD	// Enable BB and RF DC Tracking Calibrations
    SPIWrite	012,10	// Cals done, Set PPORT Config
    SPIWrite	013,01	// Set ENSM FDD/TDD bit
    SPIWrite	015,0C	// Set Dual Synth Mode, FDD External Control bits properly
    
    //************************************************************
    // Set Tx Attenuation: Tx1: 10.00 dB,  Tx2: 10.00 dB 
    //************************************************************
    SPIWrite	073,28
    SPIWrite	074,00
    SPIWrite	075,28
    SPIWrite	076,00
    //************************************************************
    // Setup RSSI and Power Measurement Duration Registers
    //************************************************************
    SPIWrite	150,0E	// RSSI Measurement Duration 0, 1
    SPIWrite	151,00	// RSSI Measurement Duration 2, 3
    SPIWrite	152,FF	// RSSI Weighted Multiplier 0
    SPIWrite	153,00	// RSSI Weighted Multiplier 1
    SPIWrite	154,00	// RSSI Weighted Multiplier 2
    SPIWrite	155,00	// RSSI Weighted Multiplier 3
    SPIWrite	156,00	// RSSI Delay
    SPIWrite	157,00	// RSSI Wait
    SPIWrite	158,0D	// RSSI Mode Select
    SPIWrite	15C,67	// Power Measurement Duration