TAS5805M: There is no sound when playing music in TDM mode , How to configure TDM mode

Part Number: TAS5805M

Hi Ti ,

I configured TDM mode according to this document TAS58xxM TDM Configurations(16-ch, 32-bit),

Now just use a chip

reg config : 0x33 = 0x17 , 0x34 = 0x00

but now there is no sound when playing music.

Please check this issue . Thanks

Regdump:

kona:/ # i2cdump -f -y 0 0x2c                                                  
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f    0123456789abcdef
00: 00 00 00 03 00 00 00 00 00 00 00 00 00 00 00 00    ...?............
10: 01 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00    ?...?...........
20: 01 07 09 01 00 40 02 00 00 00 00 00 00 00 00 00    ????.@?.........
30: 00 00 00 17 00 11 00 19 00 08 f9 04 00 20 80 00    ...?.?.?.???. ?.
40: 01 00 00 00 00 00 01 00 00 00 00 00 30 30 33 30    ?.....?.....0030
50: 07 00 00 00 00 00 00 00 00 00 00 00 00 f8 00 00    ?............?..
60: 00 00 00 00 00 00 00 00 03 00 00 00 00 50 11 24    ........?....P?$
70: 00 04 00 00 00 38 00 00 00 00 09 03 00 00 2a 00    .?...8....??..*.
80: 00 00 00 03 00 00 00 00 00 00 00 00 00 00 00 00    ...?............
90: 01 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00    ?...?...........
a0: 01 07 09 01 00 40 02 00 00 00 00 00 00 00 00 00    ????.@?.........
b0: 00 00 00 17 00 11 00 19 00 08 f9 04 00 20 80 00    ...?.?.?.???. ?.
c0: 01 00 00 00 00 00 01 00 00 00 00 00 30 30 33 30    ?.....?.....0030
d0: 07 00 00 00 00 00 00 00 00 00 00 00 00 f8 00 00    ?............?..
e0: 00 00 00 00 00 00 00 00 03 03 00 00 00 50 11 24    ........??...P?$
f0: 00 04 00 00 00 38 00 00 00 00 09 03 00 00 2a 00    .?...8....??..*.

  • Hi Kai,

                I'll check TDM spec and then give you some feedbacks. 

    Leon

  • looking forward to your feedback

    Thanks

  • Hi Kai,

                1. What's your test environment?  Do you use your own system or EVM? Can you use EVM to try to rebuild the test? You can try to connect your I2S signal to TAS5805M board and try again.

                2. What's your TDM data format? What's the clock frequency?

    Leon

  • Hi Leon,

    Using our own platform, i2s is connected to the EVM board.

    Music can be played using i2s signal. Same as the last connection, the clock frequency is 12.288MHHz  and format is long sync mode Now.

  • Hi Kai,

               Pls show your TDM signal wave by oscilloscope (CLK/data/FS in one picture)

               If you have AP, you can also try using AP to generate TDM signal for debug.

    Leon

  • Hi Leon ,

    I don’t have a four-channel oscilloscope, so I can’t display data/FS/SCLK on a picture.
    So I can only measure the signals of two channels at the same time .

    you can tell me the debugging method of TDM or which registers to configure, I can debug first

  • Hi Kai,

               1. Confirm that there does have I2S signal connected to TAS5805.(confirm it by oscilloscope)

               2. Make sure that your TDM format is suitable for TAS5805M. (Like offset/Fs signal etc)

              Or you need to tell me your TDM format(show me the wave) so that I may reproduce it my EVM.  
    Leon
  • Hi Leon,

    I can understand what you mean.

    Our format is :  long sync, offset = 0, bit-width = 16bit, Sampling Rate = 48kHz

  • Hi Leon ,

    Do you have any suggestions on the above TDM configuration?

  • Hi Kai,

               I tried it in TAS5805M EVM and it works right. Below is my TDM format and wave.  16 or 32 bit depth is also OK for playing signal.

            If your TDM format is right. I suggest you to use EVM for debug first. Just jump I2S signal from your system board and use TAS5805M EVM and PPC3 software to initialize TAS5805(Don't use your I2C firstly). Remember you should give TDM signal first then initialize TAS5805M.

    Leon

  • Hi Leon,

    Okay, because your tas5805m can work normally, I hope you can give me your TDM register configuration information? I refer to your configuration information to modify the register. Or have you modified which registers to change the mode of tas5805m to tdm and can play music normally? Please share with me

    Thanks

  • Hi Kai,

                My TDM configuration is same as you. 

                0x33 = 0x17 (0x14 is also OK),  0x34 = 0x00.

                Suggest you to follow my initialization process to check whether TDM signal is normal:

                1. Disconnect TAS5805M I2S signal and jump your system TDM signal to TAS5805M EVM.

                2. Use USB to connect computer with PPC3 software and power TAS5805M EVM.

                3. Open PPC3 software to initial TAS5805M.(TDM signal must exist in this time and make sure I2c address is right)

                4. Check whether speaker has a output. In the meantime read book0 page0 register 0x68 and 0x70~73.

    Leon

  • ok , Thanks for your feedback

    1. I try to do it like this . I check 0x68 and 0x70~73 register value.

    0x68 = 0x03   play

    But the below reg value is wrong

       0x70 = 0x00

       0x71 = 0x04

       0x72 = 0x00

       0x73 = 0x00

    So , check the tas5805m spec , the reports of these registers are all wrong 

    What is the feedback value of these registers on your side?

    2. When I use i2s signal and play music normally , 0x71~0x73 value are the same , The value = 0

    This is what I am puzzled

  • Hello Kai,

    Leon is in China public holiday today, the answer will be delayed. He will feedback you on Tuesday.

    Dylan

  • Hi Leon ,

    I used an oscilloscope to measure the FS and data signals .

    The data signal is not empty, it exists

  • Hi Kai,

               "0x71 = 0x04" means clock fault. You can try to write 0x78=0x80 to clear the fault then read back register 0x70~0x73 again to check whether clock fault is gone.

               If not that means your clock is not matched.  

    Leon

  • Hi Leon,

    Now the platform I use the TDM configuration, the data and FS signals are as shown in the figure above.

    I keep the tas5805m configuration in the i2s state, 0x33 = 0x00, there is sound in one channel of music, and no sound in the other channel.

    How come tas5805m is the configuration of i2s ? What caused this?

    Thanks

  • Hi Kai,

                Obviously from your data signal wave don't obey our TDM format. TDM in TAS58XX family is using rising edge of FS/LRCLK as a TDM frame start signal. But your data begins with the falling edge.

                So you have two choice:

               1. Change the TDM format in your SOC to rising edge as TDM beginning signal.

               2. Configure register 0x34 to shift suitable bit. Such as 16ch, 32 bit TDM signal, you should shift 16*32/2 =256 bit.

    Leon

  • Hi Leon ,

    Thank you for your suggestions .

    I set SOC to be valid on the rising edge . set tas5808m 0x34 = =0x01, offset by 1 bit, TDM can play music now.

    But Only one chip is used (i2c addr: 0x2c) Now only one speaker has sound, and the other speaker has no sound?

    Is it necessary to configure to stereo? How to set to stereo?

    How is the data of the left and right channels arranged in the current TDM format?

    Thanks

          

  • Hi Kai,

               What do you mean only one speaker has the sound? Which mode do you use, BTL or PBTL? The stereo output you mean is for one TAS5805M or 2 pcs TAS5805M?

    Leon

  • Hi Leon ,

    I check the register , 0x02 = 0x00 ,I think it is BTL .

    But only one speaker has the sound when playback , I only use one tas5805m chips to palyback

    As shown in the picture, there is no sound when symbol x

  • Hello Kai,

    When in your init sequence is the TDM registers being modified? Can you provide the Header file/cfg file dump for your initialization.

    Can you try configuring the TDM registers before the DSP configuration is done in the tuning and audio processing block

    best regards,

    Luis

  • This is the initialization file from the driver file provided by kerry song.

    stereo_flow2_48kHz_default_coldboot_-10dB.h

  • Hi Kai,

               1. Check TDM data. In TDM format for TAS5805M. TDM data 1 is for left channel, TDM data 2 is for right channel. From my point, you don't have data slot2 so right channel doesn't output voice.

               2. Change TDM format configuration code to the beginning(after 5ms delay). 

    Leon

  • Hi Leon ,

    As the picture shows :

    I added your changes, but nothing changed

    Isn’t the first two raised waveforms the data of the two channels?

  • Hi Kai,

               As mentioned before, your format is 48kHz, 16 ch, 32bit bit depth. So BCLK should be 48k*16*32=24.576MHz.

               Pls measure the BCLK/Data wave(also measure BCLK frequency), I still think your wave shows there is only one TDM data. So I need to confirm whether this is one TDM data or two TDM data.

  • Hi Leon ,

    My platform BCLK is 12.288MHz,

    So The format is : 48kHz , 16ch , 16bit width

    Please help confirm whether this is one TDM data or two TDM data according to the above format

  • Hi Kai,

             Pls give your test wave for double confirm.

    Leon

  • Hi Leon,

    This is my test wave

  • Hi Kai,

             What I mean is the oscilloscope measure wave I mentioned before - the BCLK/Data wave(also measure BCLK frequency)

    Leon

  • Hi Leon ,

    (1) as the picture shows : SCLK and data

    (2) as the below the picture show : FS and data

  • Hi Kai,

                  As it can be clearly seen form your wave. You only have one data in your TDM signal. So only left channel have output while right channel have no audio input.

              Like I said before, we must need at least two TDM data to achieve both audio output for left and right. Pls count the number of bclk carefully. Below TDM format wave can be your reference.

    Leon

  • Hi Leon,

    (1) I got the current platform data, as shown in the figure below, now it looks like two slots of data

    But one speak has sound ,the other speak no sound.

          

    (2) I check the bit /data , Data occupies 16 bit clk .

  • Hi Kai,

                See my last reply, TDM data must be followed by previous one. Your data already has three data slots but TAS5805M only recognize front two data slots. So your right couldn't output voice.

             There are two choice:

              1. Change your SOC data format to perform as below;

              2. Set TAS5805M data format as 32bit TDM.

    Leon