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.

CC3200 Audio Booster Pack: Register configuration problem ( Using I2C bus )

Part Number: TLV320AIC3254
Other Parts Discussed in Thread: CC3200

Hey Everyone,

I am using CC3200 Audio Booster pack with CC3200 launchpad. I am trying to configure the TLV320AIC3254 for 44.1kHz. Following are the clock and PLL configurations I am trying to make. 

            AudioCodecPageSelect(TI3254_PAGE_0);

            AudioCodecRegWrite(TI3254_CLK_MUX_REG, 0x03);       //PLL Clock is CODEC_CLKIN
            AudioCodecRegWrite(TI3254_CLK_PLL_P_R_REG, 0x91);   //PLL is powered up, P=1, R=1
            AudioCodecRegWrite(TI3254_CLK_PLL_J_REG, 0x38);     //J=56
            AudioCodecRegWrite(TI3254_CLK_PLL_D_MSB_REG, 0x00); //D = 0x0000 = 0
            AudioCodecRegWrite(TI3254_CLK_PLL_D_LSB_REG, 0x00); //D = 0x0000 = 0

The problem here is that these values are not actually being reflected in when I read back. Following are values read back immediately after writing: 

TI3254_CLK_MUX_REG = 0x01

TI3254_CLK_PLL_P_R_REG = 0x01

TI3254_CLK_PLL_J_REG = 0x00

I checked using oscilloscope that the read and write operation over I2C have no problem, it's going the way it should.

I also checked the application note of TLV320AIC3254 and the sequence is also being followed ( First software reset and then other things ). Also I checked the I2C section of CC3200 TRM, and I2C is being configured and used without any problems. 

I have already posted the issue in the SimpleLink forum (although, initially I thought that it's a different issue). Link: https://e2e.ti.com/support/wireless_connectivity/simplelink_wifi_cc31xx_cc32xx/f/968/p/564160/2072550#2072550

There are other people having the same problem and they have posted in the SimpleLink forum, but without any reply or solution.

Links:

1. https://e2e.ti.com/support/wireless_connectivity/simplelink_wifi_cc31xx_cc32xx/f/968/t/510809

2. https://e2e.ti.com/support/data_converters/audio_converters/f/64/t/513986

Any help would be much appreciated. 

Cheers,

Hardik M

  • Hi, Hardik,

    I would recommend several things to ensure that the I2C lines are working properly.

    - Ensure that all the power pins are enabled and stable. The Power pins must respect the recommended operating conditions of datasheet.
    - Ensure that the SPI_SELECT pin is configured to use the I2C lines (SPI = 1; I2C = 0).
    - Ensure that the I2C lines are pulled-up.

    Best regards,
    Luis Fernando Rodríguez S.
  • Hi Luis,

    I checked the pins and everything looks stable.

    IOVdd = 3.3v stable

    IOVss = Grounded

    AVss = Grounded

    AVdd = 1.65v stable

    LDOIN = 3.3v stable

    LDO_SELECT = 1.65 stable

    nRESET = 3.3v stable

    SPI_SELECT is 0.

    SDA - SCL pulled high when not in operation. The voltage level is slightly lesser than others, more like 3.28v. But they are stable.

    Also, I found the schematic of the booster pack. Link: www.ti.com/.../tidra20.pdf

    In the document, the pin diagram is inverted from actual IC. I verified with TLV320AIC3254 datasheet. (http://www.ti.com/lit/ds/slas549d/slas549d.pdf


    Do you have anymore ideas?

  • Hi, Hardik,

    It seems that all the power supplies and I2C lines are alright. You should be able to write commands via I2C. So, I recommend to apply correctly the RESET event as mentioned in 3.1 Reset section. Then, ensure to wait 1ms after pulling the RESET signal high (this will ensure that the registers are ready to be written). Finally, the codec is being used with internal LDOs. So, AVDD LDO should be activated with page 1 / register 2 / D0 = '1'.

    Best regards,
    Luis Fernando Rodríguez S.

  • Hi Luis,

    Apologies for delayed response. I got stuck in something else.

    I have gone through the data sheet and followed the reset pattern. The register configuration still didnt work.

    Then, I noticed that the audio booster pack has two reset headers. Master Reset and Codec Reset. I configured the GPIO connected to Codec Reset as an Output on the CC3200 side, connected the R46 0Ohm resistor which is actually not connected on the boosterpack when it arrives. Adding this resister connects the Codec Reset header to the Reset pin on the TLV320AIC3254. And I am successfully able to see the changes I make in GPIO being reflected at the RESET pin on the TLV320AIC3254 IC.

    I made following changes in the code.

    	GPIO_IF_Set(6, GPIOA0_BASE, 0x40, 0);
    	MAP_UtilsDelay(270); // 80 micro-seconds
    
    	GPIO_IF_Set(6, GPIOA0_BASE, 0x40, 1);
    	MAP_UtilsDelay(27000);
    	MAP_UtilsDelay(27000); // 4 mili seconds total
    
    	AudioCodecReset(AUDIO_CODEC_TI_3254, NULL);
    	AudioCodecConfig(AUDIO_CODEC_TI_3254, AUDIO_CODEC_16_BIT, 44100,
                          AUDIO_CODEC_STEREO, AUDIO_CODEC_SPEAKER_ALL,
                          AUDIO_CODEC_MIC_ALL);
    

    So, I added a Hardware reset just before writing the audio codec registers. I tried multiple variations of the code above, like increasing the delay, removing the software reset and things like that. But the configurations are still not working. I am going to remove and install the whole TI-SDK one more time just for the sake of it. Will try and post if successful after that.

    But if that doesn't help, I really need to get this thing fixed as soon as possible. Any help is much appreciated.

    Cheers,
    Hardik M

  • Hi,

    I tried installing the CC3200-sdk all over again, made a new workspace and new project. The register configuration still doesn't work.

    Hardik M
  • Hi, Hardik,

    Do you have a way to read the entire register configuration of the audio codec? This would be helpful to understand this issue.

    Best regards,
    Luis Fernando Rodríguez S.
  • Hi Luis,

    I am successful in configuring registers using SPI protocol ( after making some necessary changes in the Audio Booster pack ).

    But for debugging purposes, I will put all the register values read by I2C protocol sometime in next week.

    Cheers,
    Hardik M