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.

TLV320AIC3262: Configuring TLV320AIC3262 for audio related application

Part Number: TLV320AIC3262
Other Parts Discussed in Thread: AM5728

Hello TI Team , 

We are using AM5728 with Audiocodec TLV320AIC3262 for VOIP related application. When configuring the device for human voice, it was seen that at higher volume and high pitch the voice is cracking / shrill kinds. Especially for female / high pitch voice, the clarity in sound is not there.

The voice samples are attached. Also the device configuration used is attached. Please suggest how to configure the device for such scenarios. 

There was also one observation, while experimenting with the device for the various parameter values like DRC , AGC , it was seen that some value when programmed, does not revert back. The entire platform software and drivers need to be reloaded to get back the system to the initial state. The parameter which was tried to be altered changes the system to an irreversible state. There is not specific parameter that causes such a behaviour but many audiocodec parameters. Kindly suggest. 

Best RegardsAudioCodec_register_settings.docvoice-issue-3.13.m4avoice-issue-3.13-2.m4a 

  • Hi,

    I see you set the MIC PGA gain to 30dB which is high, you should check what's your MIC sensitivity and calculate the correct PGA gain.

    See example below:

    Please provide an example and check with EVM regarding your observation.

    Regards.

  • Hi pdjuandi,

    We are using CUI CMEJ-0627-42-SP microphone with specs similar to the part in your example.

    This microphone is used both for video phone handset (where mic will be close to the voice source) and hands-free mic (where mic will around 2ft away from the voice source).

    Regards,

    Thariq CP

  • Try adjusting your PGA gain, 2ft is not very far and 30dB is too much.

  • Hi @pdjuandi , Thanks we will check this , Is there some document which has some guidelines for configuring these gains and parameters. 

    Also suggest for this, why sometimes writing into AudioCodec registers does not have the desired effect : 

    There was also one observation, while experimenting with the device for the various parameter values like DRC , AGC , it was seen that some value when programmed, does not revert back. The entire platform software and drivers need to be reloaded to get back the system to the initial state. The parameter which was tried to be altered changes the system to an irreversible state. There is not specific parameter that causes such a behaviour but many audiocodec parameters. Kindly suggest. 

  • Configuring gain is a straight forward step through registers, so there's no document for that.

    You can find all relevant documents for the device in the product folder link below.

    https://www.ti.com/product/TLV320AIC3262

    The application reference guide will have the most details of this device.

    If you're writing the device registers from your system, check your I2C lines through scope/digital analyzer and make sure transactions are successful and correct with an ACK from the device. This kind of behavior mostly related to the system interface.

    Regards.

  • Hi pdjuandi,

    We tried with PGA gain at 9dB. The volume was audible for handset mode, but very low in hands-free mode.

    We captured the ASI waveforms (digital audio). This was done in 3 test cases:
    1. 1kHz 0dB Sine wave played (from mobile speaker) on hands-free mic of the phone was simultaneously played back on hands-free speaker of same phone (using arecord/aplay commands).
    2. A call was established between 2 phones in hands-free mode. Sine wave was played from phone 1 to phone 2. Waveforms were captured on phone 2.
    3. Case 2 was repeated in handset mode.


    The waveforms were similar in all cases and are attached for your reference.
    Channel 1 (yellow): WCLK
    Channel 2 (blue): BCLK
    Channel 3 (purple): DIN from SOC to audio-codec
    Channel 4 (green): DOUT from audio-codec to SOC

    As can be seen, DIN has no delay with respect to WCLK and DOUT has delay. The value of audio codec register B0_P4_R2 was 0x00 in all cases.

  • Have you checked the record path and the level is what you have provided at the input?

    You can adjust that as long as it's not clipping, once that's good then you can test with the playback. Playback also has volume settings which you can adjust.

    If you are able to hear back a clear signal though lower volume what you have received at least we know the audio path settings are correct just the volume need to adjust.

  • We have currently adjusted the gain values so that there is no clipping of the 0dB sine wave at the speaker output. The level is around 5V(p-p) with SVDD at 3.3V. The mic input source (mobile phone) is held very close to the microphone.

    The audio-codec gain settings used for hands-free mode is as below:

    Mic Bias= 3.3V
    Mic PGA gain= 21dB
    LOL-Spk amplifier gain= -5dB
    Speaker amplifier gain= 12dB

    The sine wave is reproduced at the speaker output.

    Speech is also being reproduced at the second phone at lower volume with background noise.

    Please suggest how the volume level can be increased without distortion.

  • Have you checked just the record (headset mic input) path for the handsfree alone if it's indeed low.

    You have adjusted the gain so no clipping at the DAC output (speaker), but is your handsfree mic input itself is too low? Have you verified that by recording that with external tool like Audacity?

    If it's low then increase your mic pga gain without causing any clipping.

  • Hi,

    1kHz sine wave was played from mobile, recorded on hands-free mic using arecord command

    1. with mic kept in open condition (without gasket and phone enclosure)

    2. with mic inside phone enclosure with gasket.

    The recorded wav files were analysed on Audacity. The wave forms are attached.

    Please check and give your suggestions.

    1.

    2.

  • 1st data shows it's high and close to the full-scale, how's the playback sounds like?

    Are you feeding this back to the SDIN and are you getting normal sound level without any additional gain on the output driver?

    The 2nd case you can increase the input PGA gain.

  • We could playback the recorded wav files on the class-D speaker with following settings:

    Mic Bias= 3.3V
    Mic PGA gain= 21dB
    LOL-Spk amplifier gain= 0dB
    Speaker amplifier gain= 6dB (minimum value)

    PCM Gain (volume control register)= 63db (on alsamixer)

    The tones are audible in both cases. The mobile speaker was placed very close to the microphones while recording.

    As suggested, we shall try with increasing PGA gain in case 2. One issue we had observed with higher PGA gain is that we were getting more background noise.

  • OK so it's good signal for 1st case.

    Obviously if you increase the gain it will increase all signals picked up by the input including noise, because your source itself it low (SNR is low).

  • Is there any way we can reduce the noise pick-up?

    Will enabling AGC help?

  • Hi Thariq,

    Today is a TI US holiday. Peter will get back to you on Tuesday.

    Thank you for your patience,
    Jeff McPherson

  • No, AGC is only to maintain the dynamic of the signal so as not to fluctuate too much when the signal suddenly drop below threshold in other words maintain constant output level.

    In your case your source itself is low, you will need to amplify that outside the codec to have a better SNR.