Skip to content

Commit

Permalink
iio: adc: ad9361: Update TX quad calibration thresholds
Browse files Browse the repository at this point in the history
Increase thresholds for LO leakage and quadrature correction. For the previous
value (0x1), an unexpected behaviour was discovered: without any setting change,
the algorithm could converge once but fail second time it was run.

Signed-off-by: Dragos Bogdan <[email protected]>
  • Loading branch information
dbogdan authored and commodo committed Oct 19, 2020
1 parent 24558bd commit d99527a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/iio/adc/ad9361.c
Original file line number Diff line number Diff line change
Expand Up @@ -2897,8 +2897,8 @@ static int ad9361_tx_quad_calib(struct ad9361_rf_phy *phy,
ad9361_spi_write(spi, REG_QUAD_CAL_COUNT, 0xFF);
ad9361_spi_write(spi, REG_KEXP_1, KEXP_TX(1) | KEXP_TX_COMP(3) |
KEXP_DC_I(3) | KEXP_DC_Q(3));
ad9361_spi_write(spi, REG_MAG_FTEST_THRESH, 0x01);
ad9361_spi_write(spi, REG_MAG_FTEST_THRESH_2, 0x01);
ad9361_spi_write(spi, REG_MAG_FTEST_THRESH, 0x03);
ad9361_spi_write(spi, REG_MAG_FTEST_THRESH_2, 0x03);

if (st->tx_quad_lpf_tia_match < 0) /* set in ad9361_load_gt() */
dev_err(dev, "failed to find suitable LPF TIA value in gain table\n");
Expand Down

0 comments on commit d99527a

Please sign in to comment.