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.

TAS5760L: Clock error reported in registers: 0x1000

Part Number: TAS5760L

Hi All,

I am using ESP32 in a prototype, along with the TI TAS5760L. The I2C bus is working and I can read and write to the registers.

Presently, I get the following outputs from the registers:

Register Values Amplifier Disabled:

TAS5760L Who Am I: 0x82
TAS5760L Power Control: 0xFD
TAS5760L Digital Control:0x14
TAS5760L Analog Control: 0xD1
TAS5760L Volume Config: 0x83
TAS5760L Fault: 0x1000

Register Values Amplifier Enabled:

TAS5760L Who Am I: 0x82
TAS5760L Power Control: 0xFD
TAS5760L Digital Control:0x14
TAS5760L Analog Control: 0xD1
TAS5760L Volume Config: 0x80
TAS5760L Fault: 0x1000

As you can see, when enabled, the output is unmuted and the Shut Down is sent HIGH. However I keep getting a fault and the SD_FAULT line keeps flickering (doesn't latch), which means when reading the datasheet, its a clock error.

I have found a small number of posts concerning this chip and they state the datasheet is wrong and that you cannot tie MCLK to SCLK (which I assume means a physical connection).

Any ideas on what I need to do to solve this please?

Regards,

Christopher

  • Hi Christopher,

    What are the frequencies of MCLK, SCLK and FCLK that your system uses?

    Could you use an oscilloscope to test if the clock signal is normal?

    Regards,

    Comi

  • Hi Comi,

    Thanks for replying:

    • LRCK = 44.102kHz
    • BCLK = 1.41126MHz
    • MCLK = 11.2902MHz

    I have since edited the PWM Analog Control to 8x (352.8kHz - B10010001)

    Registers when in play track mode:

    TAS5760L Who Am I: 0x82
    TAS5760L Power Control: 0xFE
    TAS5760L Digital Control:0x14
    TAS5760L Analog Control: 0x91
    TAS5760L Volume Config: 0x80
    TAS5760L Fault: 0x1000

    I know the I2S works as when I swap to a Maxim I2S amplifier it plays straight away. I am clearly missing something.

    Regards,

    Christopher

  • Hi Christopher

    However I keep getting a fault and the SD_FAULT line keeps flickering (doesn't latch),

    May I ask did we connect the SPK_FAULT pin and SPK_SD pin together, or are we sure we didn't keep toggling the SPK_SD pin from MCU? Are you available to share your schematic, we could check it first.

    TAS5760L Fault: 0x1000

    And bout this FAULT register, I'm a little confused by your value, why it has 4 digits in Hex? According to datasheet, it should only has 2 digits, can you confirm what is the correct value? 

  • Hi Shadow He,

    Thanks for your reply also.

    No I haven't tied SPK_FAULT and SPK_SD together, although I know you can in other TI amplifiers. They are connected to the microcontroller for full control.

    The four digits was simply because I set the output  to binary to make sure I tallied against the fault table accurately.

    Regards,

    Christopher.

    P.S. I have actually solved the problem, whch I will post shortly and the amplifier is now fully working.

  • Hi All,

    I solved the problem in the end. It was a mixture of the following

    1) Within the code, I had to enable the MCLK pin of the ESP32, which can only be enabled on three pins

    • GPIO0
    • GPIO1
    • GPIO3

    However, GPIO 1 & 3 are the RX & TX pins of the UART, so shouldn't be used. Finally GPIO0 wasn't available on my ESP32 Dev Kit. I had to swap the DEV Kit to a larger model which had GPIO0 exposed. 

    Using the Audio library, the pin were enabled as follows:

    • audio.setPinout(I2S_BCLK, I2S_LRC, I2S_DOUT, I2S_DIN, I2S_MCLK);

    2) We have all done it, register blindness! My functions for setting the output were back to front on the Power Control registers. In my opening question it shows power control at 0xFD, in the Loop, these were being switched to 0xFE.

    3) Even with the control registers set, I found that that the order of start up needed to include physically setting the SPK_SD pin High, as well as the registers, please see function list as follows, hopefully my function names are clear to understand.

    configureDigitalCtrlRegisters(); (0x14)
    configureAnalogCtrlRegisters(); (0xD1 - As I am using the Amplifier in PBTL mode)
    digitalWrite(spkShutDown, HIGH); Physically enable the pin
    startUpRegisters(); (
    unmuteRegisters(); (0xFD as per the Datasheet
    volumeLowSetRegister(); Reduce the initial volume

    Regards,

    Christopher