ES8388录音没有声音问题解决

使用arecord录音没有报错,录出来的声音没有波形。

Amixer -c 3 看到左右声道获取音量值为0

Simple mixer control 'Left Channel',0

  Capabilities: cvolume cvolume-joined

  Capture channels: Mono

  Limits: Capture 0 - 8

  Mono: Capture 0 [0%] [0.00dB]

Simple mixer control 'Right Channel',0

  Capabilities: cvolume cvolume-joined

  Capture channels: Mono

  Limits: Capture 0 - 8

  Mono: Capture 0 [0%] [0.00dB]

Linux 中设置了左右省道的值。

amixer -c $card cset name=’Left Channel Capture Volume’ 4 >/dev/null

amixer -c $card cset name=’Right Channel Capture Volume’ 4 >/dev/null

使用amixer设置左右声道值后可以录音

dump es8388设置前和设置后寄存器值,可以看到09和0A值发生了变化。

将09和0A分别写入44,40,

修改

--- a/sound/soc/codecs/es8323.c

+++ b/sound/soc/codecs/es8323.c

@@ -769,8 +769,8 @@ static int es8323_probe(struct snd_soc_component *component)

        snd_soc_component_write(component, 0x04, 0x00);

        snd_soc_component_write(component, 0x06, 0xC3);

        snd_soc_component_write(component, 0x19, 0x02);

-       snd_soc_component_write(component, 0x09, 0x00);

-       snd_soc_component_write(component, 0x0A, 0x00);

+       snd_soc_component_write(component, 0x09, 0x44);

+       snd_soc_component_write(component, 0x0A, 0x40);

修改后重新编译kernel,烧录镜像后MIC录音就有声音了。

发表回复 0

Your email address will not be published. Required fields are marked *