This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

ADC5140EVM-PDK: About AGC settings

Part Number: ADC5140EVM-PDK

I'm trying to change the AGC release time.

According to the document "Using the Automatic Gain Controller (AGC) in the TLV320ADCx140", I entered the following in the I2C command, but the operation does not change.

w 98 00 00 # Goto Page 0
w 98 02 81 # Wake-up device by I2C write into P0_R2 using internal AREG
w 98 02 81 # Exit Sleep mode
d 10 # Wait for 16 ms

w 98 6C 48 # Enable AGC in DSP_CFG1
w 98 3C 01 # Select AGC on Ch. 1 using CH1_CFG0
w 98 41 01 # Select AGC on Ch. 2 using CH2_CFG0
w 98 74 01 # Select AGC on Ch. 3 using CH3_CFG0
w 98 75 01 # Select AGC on Ch. 4 using CH4_CFG0
w 98 70 0B # AGC LVL = -6 dB, AGC GAIN = 36 dB

w 98 00 05 # Goto Page 5
w 98 7C 7F FF 40 01 # AGC Release Time Alpha
w 98 00 06 # Goto Page 6
w 98 08 00 00 BF FF # AGC Release Time Beta

w 98 00 00 # Goto Page 0
w 98 07 30 # TDM Mode with 32 Bits/Channel
w 98 73 f0 # Enable Ch.1 - Ch.4
w 98 74 f0 # Enable ASI Output channels
w 98 75 e0 # Power up ADC

  • Release time alpha and beta are rewritten below by release time. 

    #Release time = 20ms (default)
    w 98 00 05 # Goto Page 5
    w 98 7C 7F B5 16 50 # AGC Release Time Alpha
    w 98 00 06 # Goto Page 6
    w 98 08 00 4A E9 B0 # AGC Release Time Beta
    
    #Release time = 200ms
    w 98 00 05 # Goto Page 5
    w 98 7C 7F F8 80 41 # AGC Release Time Alpha
    w 98 00 06 # Goto Page 6
    w 98 08 00 07 7F BF # AGC Release Time Beta
    
    #Release time = 2s
    w 98 00 05 # Goto Page 5
    w 98 7C 7F FF 40 01 # AGC Release Time Alpha
    w 98 00 06 # Goto Page 6
    w 98 08 00 00 BF FF # AGC Release Time Beta

  • Hi,

    Apologies for the delay, please be patient as audio team is returning from US holiday. I will continue the thread asap.

    Kind regards,

  • Hi Hirokshi,

    I plugged in you RT constant values into MATLAB equation and derived different coefficients. Please let me know if these work.

    These are the equations used:

    200ms:

    Alpha: round(2^(31)*exp((-log(9)/48000*0.2)))

    Beta: 2^(31)-round(2^(31)*exp((-log(9)/48000*0.2)))

    2s:

    Alpha: round(2^(31)*exp((-log(9)/48000*2)))

    Beta: 2^(31)-round(2^(31)*exp((-log(9)/48000*2)))

    #Release time = 20ms (default)
    w 98 00 05 # Goto Page 5
    w 98 7C 7F B5 16 50 # AGC Release Time Alpha
    w 98 00 06 # Goto Page 6
    w 98 08 00 4A E9 B0 # AGC Release Time Beta
    
    #Release time = 200ms
    w 98 00 05 # Goto Page 5
    w 98 7C 80 00 3F E0 # AGC Release Time Alpha
    w 98 00 06 # Goto Page 6
    w 98 08 00 00 4C CC # AGC Release Time Beta
    
    #Release time = 2s
    w 98 00 05 # Goto Page 5
    w 98 7C 7F FD 32 A0 # AGC Release Time Alpha
    w 98 00 06 # Goto Page 6
    w 98 08 00 02 FF F3 # AGC Release Time Beta

  • Thank you for your reply.

    I sent the setting values you provided with an I2C command, but the operation did not change.

    In the first place, the register may not have been rewritten.

    Even if I do a register dump with PPC3, I can only dump up to Page.4, so please tell me how to dump after Page.5.

  • In the I2C monitor you can record activity of the IC, also in the I/O tab you can see if the the written command line is successful.

    These registers are also R/W, so after command write you can read within I/O tab as well.