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.

TLV320AIC34作从设备录音和播放有沙沙声

Other Parts Discussed in Thread: AM5708

项目用TLV320AIC34做音频codec,codec作为slaves设备。主控为AM5708的内置的DSP控制,DSP的mcasp作为主设备,现在DSP设置ahclk的时钟频率为22.579MHZ,bclk为1.4112MHZ,wclk为44.1kHZ,录音的声音马上播放出去会有沙沙声音的,类似收音机那种沙沙声音。如果将寄存器reg43,reg44设置为静音的时候,耳机不会有沙沙声音。如果设置声音输入->PGA->HPLOUT的模式,声音不经过ADC和DAC的转换,直接播放出去也没有沙沙声音,请问这情况是不是是时钟设置不对?如果codec作从设备时,要不要也要设置内部时钟的?

如下为寄存器的设置

{0x00,0x00},
{0x01,0x80},

// codec 作从
{3, 0x00},
{8, 0x00},
{9, 0x00},

// Q值 , CLKDIV_IN / (128 × Q) = 22.579MHZ / 128 * 4 = 44.1kHZ, 22.579MHZ为MCLK_x的输入

{3, 0x40},

// ADC Init
{102, 0x00},
/* enable the programmable PGA for left and right ADC */
{15, 0x00},
{16, 0x00},

/* MIC3L/R is not connected to the left ADC PGA */
{17, 0xff},

/* MIC3L/R is not connected to the right ADC PGA */
{18, 0xff},

/* power on the Line L1R */
{19, 0x04},

/* power on the Line LIL */
{22, 0x04},

// DAC Init
/* Codec Datapath Setup */
{7, 0x8A},

/* select the DAC L1 R1 Paths */
{41, 0x02},
{42, 0x6c},

/* DAC L to HPLOUT Is connected */
{47, 0x80},
{51, 0x09},
//{46, 0x80},
//{51, 0x09},

/* DAC R to HPROUT is connected */
{64, 0x80},
{65, 0x09},
//{63, 0x80},
//{65, 0x09},

/* DACL1 connected to LINE1 LOUT */
{82, 0x80},
{86, 0x09},

/* DACR1 connected to LINE1 ROUT */
{92, 0x80},
{93, 0x09},
//{94, 0xc6},

/* unmute the DAC */
{43, 0x00},
{44, 0x00},


/* power up the left and right DACs */
{37, 0xE0},

  • 您好,采样频率设置的是多少?
    slave mode时候,WCLK, BCLK都是为输入,所以不需要使用内部时钟。
  • 你好:

    把输入静音了和ADC都断电了,为什么ADC还有数据输出的,reg15,reg16设置为0x80;reg19,reg21设置为0x00。用示波器测试音频数据数据输出引脚,会有显示波形的跳变,理应数据引脚没变化才对。现在遇到问题是,歌曲没有播放时,耳机输出会有底噪的现象。操作环境是,AM5708 CPU,用AM5708内置的DSP作主设备,音频芯片为从设备,一边录音一边把录音数据输出出来。