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.

TLV320AIC3104-Q1: Need to understand the dynamic switching between two different codec.

Part Number: TLV320AIC3104-Q1
Other Parts Discussed in Thread: TLV320AIC3110, , TLV320AIC3104

Hi Team,

Need your help to understand the dynamic switching between two different codec.

We are using:

  1. TLV320AIC3110 - Internal Audio Codec - 0.8W
  2. TLV320AIC3104-Q1 -External Audio Codec (20W*2 Speakers)

So basically we are confused between switching in two codec.

Both the codecs having their own significance.

Could you please suggest any idea to switch between the codecs dynamically.

For example:

if I'm connecting my mobile to Android Device which is having Audio codec thru BT, and I want to play audio from  TLV320AIC3104 External Audio Codec, then what need to be done?

thanks.

Divyesh

  • Hi Divyesh,

    Both devices have I2C address of 0011 000 (7-bit addressing) so you need to be able to isolate one from the other.

    I believe this issue was discussed in previous post already.

    regards,

    Peter

  • Thanks peter for your reply.

    I have isolated both the IC's using different i2c bus.

    but my question is How to switch between two codecs.

    Means suppose I have to use speaker which is connected to TLV320AIC3104 codec. And other speaker from TLV320AIC3110 codec should be turned off at this time.

    How to switch dynamically to activate one speaker at a time and control their respective volume at the same time.

    Thanks.

  • Hi Divyesh,

    You send the configuration to turn off the "other" codec prior to turning on the active codec.

    I don't know what you meant by different i2c bus, if the same i2c SCL and SDA lines are connected between the 2 codecs you are not isolating them you are just using 2 different hosts to talk to 2 codecs of the same address. Unless you have an I2C switch/mux from 1 master to 2 slaves and each slave is going to codec then you can configure them separately. This is your system design, but from codec you just need to enable/disable the path to turn it on/off. 

    Regards,

    Peter

  • Hi Peter,

    Que:- I don't know what you meant by different i2c bus

    Ans: Means One codec is connected to I2C2-0x18 and Other codec is connected to I2C4-0x18 . So we dont need any Switch/Mux to isolate bothe the codec.

     

    So my question is can we switch between two codecs dynamically through Application/UI/SysfsNode or any possible way?

    1. TLV320AIC3110 - Internal Audio Codec - 0.8W --- SUB-WOOFER
    2. TLV320AIC3104-Q1 -External Audio Codec (20W*2 Speakers) -- FOR MUSIC and OTHER STUFF

    Thanks,

    Divyesh

  • Hi Divyesh,

    That's in your system as how you interact between the 2 codecs. You can definitely change the codec configuration thru I2C on the fly. The mechanism itself is something you have to take care as we don't know your system.

    Regards,

    Peter

  • Hi Peter,

    Our system Android 11 code based IMX8MM processor.

    IMX8MM (Android 11) <----- >Audio Module ( which is having two diff codecs).

    based on use case respective codec will provide output – Low frequency use case -> Internal codec , High frequency use case -> External codec.

    So basically one act as sub woofer and other codec music player

  • Hi Divyesh,

    What I meant was you have to handle the switching between the 2 codecs in your system.

    Regards,

    Peter