TI论坛
直播中

ytrwv

8年用户 914经验值
擅长:EMC/EMI设计
私信 关注
[问答]

TLV320AIC3254用以下代码跑程序,发现IIS音频输入模式,喇叭和耳机都无音频输出,为什么?


  • DSP用TLV320AIC3254,主控芯片接的是EVM板,IIS音频数据输入正常,IIC通讯正常,用以下代码跑程序,发现IIS音频输入模式,喇叭和耳机都无音频输出;
    AUX音频输入模式,喇叭无声,耳机有声,但是声音很小和很多杂音。
    请帮忙看看以下设置哪里设置有问题。
    static const reg_value REG_Section_program[] = {
    { 0,0x00},
    //Initialize the device through software reset
    { 1,0x01},
    //-----------------
    { 0,0x01},
    //Power up AVDD LDO; Disable weak AVDD to DVDD connection; Enable Master Analog Power Control, AVDD LDO Powered; Disable weak AVDD to DVDD connection
    { 1,0x08},
    //Enable Master Analog Power Control
    { 2,0x00},
    //Set the input power-up time to 3.1ms
    { 71,0x32},
    //Set REF charging time to 40ms (automatic)
    {123,0x01},
    #if 0
    //Set miniDSP_A_reg
    {255,0x00},
    //Set miniDSP_D_reg
    {255,0x01},
    #endif
    //-----------------
    { 0,0x00},
    //miniDSP_A and miniDSP_D are independently powered up
    //miniDSP_D used for signal processing
    { 60,0x00},
    //miniDSP_A used for signal processing
    { 61,0x00},
    //8x Interpolation
    { 17,0x08},
    //4x Decimation
    { 23,0x04},
    //
    { 15,0x03},
    //
    { 16,0x88},
    //
    { 21,0x03},
    //
    { 22,0x88},
    //-----------------
    { 0,0x08},
    //adaptive mode for ADC
    { 1,0x04},
    //-----------------
    { 0,0x2C},
    //adaptive mode for DAC
    { 1,0x04},
    //-----------------
    { 0,0x00},
    //P=1, R=1, J=8
    { 5,0x91},
    //P=1, R=1, J=8
    { 6,0x08},
    //D=0000 (MSB)
    { 7,0x00},
    //D=0000 (LSB)
    { 8,0x00},
    //PLL_clkin = MCLK, codec_clkin = PLL_CLK, PLL on
    { 4,0x03},
    //MDAC = 8, divider powered on
    { 12,0x88},
    //DOSR = 128 (MSB)
    { 13,0x00},
    //DOSR = 128 (LSB)
    { 14,0x80},
    //NADC = 2, divider powered on
    { 18,0x82},
    //MADC = 8, divider powered on
    { 19,0x88},
    //AOSR = 128
    { 20,0x80},
    //NDAC = 2, divider powered on
    { 11,0x82},
    #if 0
    //Interface = I2S, Length = 20bits, BCLK and WCLK output
    { 27,0x1C},
    //BDIV_CLKIN = DAC_MOD_CLK
    { 29,0x01},
    //BCLK power up, BCLK N divider = 2
    { 30,0x82},
    #else
    //Interface = I2S, Length = 16bits, BCLK and WCLK input
    { 27,0x00},
    #endif
    //-----------------
    { 0,0x01},
    //Mic Bias enabled, Source = Avdd, 1.25V
    { 51,0x40},
    #if 0
    //Route IN1L to LEFT_P with 10K input impedance;
    { 52,0x40},
    //Route CM1L to LEFT_M with 10K input impedance
    { 54,0x40},
    //Route IN1R to RIGHT_P with 10K input impedance
    { 55,0x40},
    //Route CM1R to RIGHT_M with 10K input impedance
    { 57,0x40},
    #else
    //IN2L is routed to Left MICPGA with 20k resistance
    { 52,0x20},
    //CM is routed to Left MICPGA via CM1L with 20k resistance
    { 54,0x80},
    //IN2R is routed to Right MICPGA with 20k resistance
    { 55,0x20},
    //CM is routed to Right MICPGA via CM1R with 20k resistance
    { 57,0x80},
    #endif
    //Enable MicPGA_L Gain Control, 0dB
    { 59,0x00},
    //Enable MicPGA_R Gain Control, 0dB
    { 60,0x00},
    //-----------------
    { 0,0x00},
    //Power up LADC/RADC
    { 81,0xC0},
    //Unmute LADC/RADC
    { 82,0x00},
    //-----------------
    { 0,0x01},
    //De-pop: 5 time constants, 6k resistance
    { 20,0x25},
    //Route LDAC to HPL
    { 12,0x08},
    //Route RDAC to HPR
    { 13,0x08},
    //Route LDAC to LOL
    { 14,0x08},
    //Route LDAC to LOR
    { 15,0x08},
    //-----------------
    { 0,0x00},
    //Power up LDAC/RDAC w/ soft stepping
    { 63,0xD4},
    //-----------------
    { 0,0x01},
    //Unmute HPL driver, 0dB Gain
    { 16,0x00},
    //Unmute HPR driver, 0dB Gain
    { 17,0x00},
    //Unmute LOL driver, 0dB Gain
    { 18,0x00},
    //Unmute LOR driver, 0dB Gain
    { 19,0x00},
    //Power up HPL/HPR and LOL/LOR drivers
    { 9,0x3C},
    //-----------------
    { 0,0x00},
    //Unmute LDAC/RDAC
    { 64,0x00},
    //Unmute LADC , Fine Gain 0dB; Unmute RADC , Fine Gain 0dB
    { 82,0x00},
    //Left ADC Channel Volume = 0.0dB
    { 83,0x00},
    //Left Channel AGC Target Level = -12.0dBFS ; Gain Hysteresis is ±1.0dB
    { 86,0x20},
    //Left Channel AGC Hysteresis is disabled ; Noise Threshold is -88dB
    { 87,0xFE},
    //Left Channel AGC Maximum Gain = 0.0dB
    { 88,0x00},
    //Left Channel AGC Attack Time = 13 * 32 ADC Word Clocks
    { 89,0x68},
    //Left Channel AGC Decay Time = 17 * 512 ADC Word Clocks
    { 90,0xA8},
    //Left Channel AGC Noise Debounce Time = 64 ADC Word Clocks
    { 91,0x06},
    //
    { 92,0x00},
    //Right ADC Channel Volume = 0.0dB
    { 84,0x00},
    //
    { 94,0x20},
    //
    { 95,0xFE},
    //
    { 96,0x00},
    //
    { 97,0x68},
    //
    { 98,0xA8},
    //
    { 99,0x06},
    //
    {100,0x00},
    };

回帖(2)

潘晶燕

2024-10-12 10:32:04
您好,主控用的哪款DSP,DSP使用的是EVM板, AIC3254是自己的板子是吗?
举报

醉清歌

2024-10-14 18:11:59
根据您提供的信息,您在使用TLV320AIC3254进行音频处理时遇到了一些问题。在IIS音频输入模式下,喇叭和耳机都没有音频输出;而在AUX音频输入模式下,喇叭无声,耳机有声但声音很小且有很多杂音。以下是一些建议和可能的原因:

1. 检查硬件连接:请确保您的硬件连接正确,包括音频输入、输出和电源。错误的连接可能导致音频输出问题。

2. 检查I2C通信:确保I2C通信正常,并且TLV320AIC3254的寄存器设置正确。错误的寄存器设置可能导致音频输出问题。

3. 检查音频格式:请确保您的音频格式(如采样率、位深和通道数)与TLV320AIC3254支持的格式相匹配。不匹配的音频格式可能导致音频输出问题。

4. 检查音量控制:请检查TLV320AIC3254的音量控制寄存器设置,确保音量没有被静音或设置得过低。

5. 检查电源管理:请确保TLV320AIC3254的电源管理设置正确,包括AVDD和DVDD电源。错误的电源管理设置可能导致音频输出问题。

6. 检查代码逻辑:请检查您的代码逻辑,确保在IIS音频输入模式和AUX音频输入模式下,音频处理流程正确。

7. 检查硬件故障:如果以上建议都无法解决问题,可能是TLV320AIC3254或主控芯片存在硬件故障。您可以尝试更换芯片或联系芯片制造商寻求技术支持。

希望以上建议对您有所帮助。如果问题仍然存在,请提供更多详细信息,以便我们为您提供更具体的帮助。
举报

更多回帖

发帖
×
20
完善资料,
赚取积分