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.

TPS65950:Noisy Audio when i play sine wave file

Other Parts Discussed in Thread: TPS65950, SYSCONFIG

Hi All,

I have set up a custom audio driver using the McBSP2 module on the OMAP 3730, and the audio codec is TPS65950.

McBSP2 is configured as Slave and codec as I2SMaster. when i play sine wave file on my hardware,am hearing distorted audio in the speaker(Am sure there is NO problem with sine wave audio file as i tested with other HW setup)

Below are the McBSP2 and Codec register dump.can you please help me to point out that anything going wrong in the below configuration...

McBSP2 Configuration:

OMAP3_MCBSP_REG_SPCR2           = 0x00000205

OMAP3_MCBSP_REG_SPCR1           = 0x00000000

OMAP3_MCBSP_REG_RCR2            = 0x00000001

OMAP3_MCBSP_REG_RCR1            = 0x000000a0

OMAP3_MCBSP_REG_XCR2            = 0x00000001

OMAP3_MCBSP_REG_XCR1            = 0x000000a0

OMAP3_MCBSP_REG_SRGR2           = 0x00000000

OMAP3_MCBSP_REG_SRGR1           = 0x00000000

OMAP3_MCBSP_REG_MCR2            = 0x00000000

OMAP3_MCBSP_REG_MCR1            = 0x00000000

OMAP3_MCBSP_REG_PCR             = 0x0000008d

OMAP3_MCBSP_REG_RINTCLR = 0x00000000

OMAP3_MCBSP_REG_XINTCLR = 0x00000000

OMAP3_MCBSP_REG_ROVRFLCLR  = 0x00000000

OMAP3_MCBSP_REG_SYSCONFIG  = 0x00000010

OMAP3_MCBSP_REG_THRS2           = 0x00000000

OMAP3_MCBSP_REG_THRS1           = 0x00000000

OMAP3_MCBSP_REG_IRQSTATUS       = 0x00001f02

OMAP3_MCBSP_REG_IRQENABLE       = 0x00000000

OMAP3_MCBSP_REG_WAKEUPEN        = 0x00000000

OMAP3_MCBSP_REG_XCCR            = 0x00000808

OMAP3_MCBSP_REG_RCCR            = 0x00000808

OMAP3_MCBSP_REG_XBUFFSTAT       = 0x00000000

OMAP3_MCBSP_REG_RBUFFSTAT       = 0x00000000

OMAP3_MCBSP_SSELCR_REG          = 0x00000084

OMAP3_MCBSP_STATUS_REG          = 0x00000000

Codec Configuration:

REG_CODEC_MODE = 0x92

REG_OPTION = 0xc0

REG_MICBIAS_CTL = 0x0

REG_ANAMICL = 0x0

REG_ANAMICR = 0x0

REG_AVADC_CTL = 0x0

REG_ADCMICSEL = 0x0

REG_DIGMIXING = 0x0

REG_ATXL1PGA = 0xf

REG_ATXR1PGA = 0xf

REG_AVTXL2PGA = 0xf

REG_AVTXR2PGA = 0xf

REG_AUDIO_IF = 0x1

REG_VOICE_IF = 0x0

REG_ARXR1PGA = 0x0

REG_ARXL1PGA = 0x0

REG_ARXR2PGA = 0x36

REG_ARXL2PGA = 0x36

REG_VRXPGA = 0x25

REG_VSTPGA = 0x0

REG_VRX2ARXPGA = 0x0

REG_AVDAC_CTL = 0xc

REG_ARX2VTXPGA = 0x0

REG_ARXL1_APGA_CTL = 0x0

REG_ARXR1_APGA_CTL = 0x0

REG_ARXL2_APGA_CTL = 0xb

REG_ARXR2_APGA_CTL = 0xb

REG_ATX2ARXPGA = 0x0

REG_BT_IF = 0x0

REG_BTPGA = 0x55

REG_BTSTPGA = 0x0

REG_EAR_CTL = 0x0

REG_HS_SEL = 0x24

REG_HS_GAIN_SET = 0x0

REG_HS_POPN_SET = 0x0

REG_PREDL_CTL = 0x3c

REG_PREDR_CTL = 0x0

REG_PRECKL_CTL = 0x0

REG_PRECKR_CTL = 0x0

REG_HFL_CTL(0x01) = 0x0

REG_HFR_CTL(0x01) = 0x0

REG_ALC_CTL(0x01) = 0x5

REG_ALC_SET1(0x01) = 0x0

REG_ALC_SET2 = 0x0

REG_BOOST_CTL = 0x0

REG_SOFTVOL_CTL = 0x0

REG_DTMF_FREQSEL = 0x13

REG_DTMF_TONEXT1H = 0x0

REG_DTMF_TONEXT1L = 0x0

REG_DTMF_TONEXT2H = 0x0

REG_DTMF_TONEXT2L = 0x0

REG_DTMF_TONOFF = 0x79

REG_DTMF_WANONOFF = 0x11

REG_APLL_CTL = 0x16

REG_DTMF_CTL = 0x0

REG_DTMF_PGA_CTL2 = 0x44

REG_DTMF_PGA_CTL1 = 0x69

REG_MISC_SET_1 = 0x2

REG_PCMBTMUX = 0x0

REG_RX_PATH_SEL = 0x0

REG_VDL_APGA_CTL = 0x32

REG_VIBRA_CTL = 0x0

REG_VIBRA_SET = 0x0

REG_ANAMIC_GAIN = 0x0

REG_MISC_SET_2 = 0x0

Regards

Senthil KUmar.V

I have set up a custom audio driver using the McBSP2 module on the OMAP 3530, and the audio codec in the TPS65950

  • Hi Senthilkumar,

    The audio distortion could be caused to various reasons. It is possible to have some noise added to the sinusoidal signal. Could try to find some existing audio driver using McBSP an make changes to become suitable for your hardware. If this way works fine the suspicion of hardware problem will be eliminated.

    In addition could you add a picture of audio output from the oscilloscope.

    BR

    Tsvetolin Shulev

  • Hi Tsvetolin & All,

    Thanks for your reply...I have tried using EVM3530 Audio+McBSP driver to my Hardware but looks like it needs lot of changes moreover i don't have that much time as i need to finish off my present task soon...

    Will update you after taken the Audio output...

    Can i get any other ideas to try with?Will it problem outside of McBSP+TPS65950 like DMA,Audio driver?

    Regards

    Senthil

  • Hi All,

    Am still struggling with this issue.

    I have tried playing sine wave file on EVM3530(which has same TPS65950 codec) and it was playing very fine without any distortion so taken the reg dump of McBSP & CODEC from EVM3530,Modified McBSP and TPS65950 register values(which makes sense to change and try) similar to EVM but it didn't help

    Which module would cause this issue(McBSP or TPS65950 or DMA or Audio driver).can you people plz help on this?

    -Senthil

  • Hi All,

    Could't solve this issue yet...

    I did few experiment and would like to share here...

    1.I have put the speaker before the Pre-Amplifier circuit (i.e Just after CODEC PreDriv_Left Output) and i can hear the distorted audio when i play sinewave file.

    2.Did the FM loopback configuration in TPS65950 and it works fine(when i speak on the mic,i can able to hear properly in the speaker without any noise)

    With the above two experiment,we can conclude that it is not problem with the Hardware

    Software aspect, am using the McBSP and TPS65950 register values of EVM3530(Taken reg dump from EVM3530 as it is playing without any distortion) but it does not help for me.

    Attached the Frequency spectrum waveform of sine wave file which i have probed in TPS65950 PreDriv_Left Output.

    can you people help me out that what could be causing this issue?

    Thanks and Regards

    Senthil