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.

TAS2505EVM: Device Driver to imx8m mini

Part Number: TAS2505EVM
Other Parts Discussed in Thread: TAS2505

Hi,

We are using Yocto Zeus for imx8m custom board & need to integrate with speaker module TAS2505.

we found TAS2505 driver from below link.

https://github.com/dangtranhieu2012/tas2505-linux-driver

Could you please provide the corresponding device tree configuration & other technical support related to Linux BSP.

Thanks & Regards,

Logan

  • Hi Logan,

    Please refer to this previous thread: https://e2e.ti.com/support/audio-group/audio/f/audio-forum/1061783/tas2505-driver-to-linux-os/3928527#3928527

    Best regards,
    -Ivan Salazar
    Applications Engineer

  • Hi Ivan Salazar,

                       Thanks for your support. 

    We  added TAS2505 driver & can able to here sound. But whenever play audio, need to change amplifier volume using alsamixer.

    TAS2505 support 48000 & 44100 Hz sampling frequency, but 48000Hz audio only able to play.

    * How to unmute or play without use of alsamixer

    * We need need to play audio of 22050 Hz, how to calculate

    struct tas2505_rate_divs {
        u32 mclk_p;
        u32 rate;
        u8 pll_r;
        u8 pll_j;
        u16 pll_d;
        u8 mdac;
        u8 ndac;
        u16 dosr;
    };

    Thanks,

    Logan

  • Hi Logan,

    I'll take a look at the required PLL settings and reply with some values by tomorrow.
    Regarding alsamixer questions I'll need to check with some of my software colleagues and get back with further comments.

    Best regards,
    -Ivan Salazar
    Applications Engineer

  • Hi Logan,

    You can try with the following:

    static const struct tas2505_rate_divs tas2505_divs[] = {
    	{ 12288000, 44100, 1, 7, 35, 4, 4, 128 },
    	{ 12288000, 48000, 1, 7, 0, 7, 2, 128 },
    	{ 12288000, 22050, 1, 7, 35, 8, 4, 128 },
    };

    Best regards,
    -Ivan Salazar
    Applications Engineer

  • Hi Ivan Salazar,

    We applied tas2505_rate_divs structure(for 22050Hz sampling frequency) in our tas2505.c file but its not working. Driver working only 48000Hz sampling audio. Not even default driver 44100 Hz sampling audio also not working. I am not sure, took proper driver files.

    Kindly share tas2505 driver files(tas2505.c, tas2505.h & other required files)

    Thanks & Regards,

    Logan

  • Hi Logan,

    Please try with this from our product folder: https://git.ti.com/cgit/lpaa-android-drivers/tas2505-linux-driver/

    If you keep facing trouble using it let me know along with log files etc and I can check along with our software team.

    Best regards,
    -Ivan Salazar
    Applications Engineer

  • Hi Ivan Salazar,

    Thanks for ur support. Now we can able to play 22050Hz sampling frequency.

    One issue is there, whenever newly play audio, sound is not coming but driver init function is unmute the volume. For get sound need to play audio first then use alsamixer or re-set amplifier volume register through i2c (0x30 in page 1). Kept Default volume : 30,

    aplay -Dsysdefault:tas2505 eurohighburst.wav &
    i2cset -y -f 2 0x18 0x00 0x01
    i2cset -y -f 2 0x18 0x30 0x10

    Kindly help us to get audio without every time re-set volume while play.

    Thanks & Regards,

    Logan

  • Hi Logan,

    Glad it works now for 22050Hz, was there anything changing in the code? Or is there something changing on the host or hardware?
    If you can share more details it would help for better understanding.

    I'll check about the volume after play command, will get feedback as soon as possible.

    Best regards,
    -Ivan Salazar
    Applications Engineer

  • Hi Logan,

    Can you share the runtime log so we can further analyze what is the device configuration?
    Also if you can do a register dump after initialization, before playback and also after playback it also helps.

    Best regards,
    -Ivan Salazar
    Applications Engineer