How to enable Sterio mic in imx6ulevk with wm8960?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How to enable Sterio mic in imx6ulevk with wm8960?

1,385 Views
vikneshwarthand
Contributor II

Board used: Imx6ulevk

Image: Customized Yocto image.

Kernel version: 4.9.11

mic-interface.png

Hi Team,

I am working on a project for car infotainment system, I have to record stereo audio using wm8960 audio codec which is used on imx6ulevk base board. On baseboard we are having one onboard mic audio input and one jack input for headset mic.

Using arecord command i can record audio which uses onboard mic (RINPUT2  -MAINMIC-MIC2(P) , RINPUT -MAINMIC-MIC2(N)). I want to record stereo audio by using  both RINPUT CHANNEL AND LINPUT CHANNEL.

How to enable dual channel.

Labels (4)
4 Replies

1,148 Views
igorpadykov
NXP Employee
NXP Employee

Hi Vikneshwar

one can add such support using wm8960 audio codec driver sources described in

sect.7.4.4 Source Code Structure attached Linux Manual. Testing is described in

sect.7.1.5.1 Stereo Codec Unit Test, sect.7.3.5 Audio recording Linux Guide.

Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

1,148 Views
vikneshwarthand
Contributor II

Hi igorpadykov

On our custom board we interfaced two mics as single ended as shown below..

codec.png

On imx6ulevk-14x14 mics are interfaces with codec as differential mode. How to configure  mic as single ended mode on custom board, what are the changes involved?.

0 Kudos

1,148 Views
igorpadykov
NXP Employee
NXP Employee

microphone input is described on p.19 wm8960 datasheet

https://statics.cirrus.com/pubs/proDatasheet/WM8960_v4.4.pdf 

Best regards
igor

1,148 Views
vikneshwarthand
Contributor II

Hi igorpadykov,

Thanks for your replay,

How to switch PGA to VMID? 

We are unable to access wm8960 using i2c interface.

root@imx6ulevk:~/i2c-tools/tools# ./i2cdetect -l
i2c-1    i2c           21a4000.i2c                         I2C adapter
i2c-0    i2c           21a0000.i2c                         I2C adapter

root@imx6ulevk:~/i2c-tools/tools# ./i2cdetect -r 1
WARNING! This program can confuse your I2C bus, cause data loss and worse!
I will probe file /dev/i2c-1 using receive byte commands.
I will probe address range 0x08-0x77.
Continue? [Y/n] y
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:                         -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- UU -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --    

root@imx6ulevk:~/i2c-tools/tools# ./i2cdetect -r 0
WARNING! This program can confuse your I2C bus, cause data loss and worse!
I will probe file /dev/i2c-0 using receive byte commands.
I will probe address range 0x08-0x77.
Continue? [Y/n] y
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:                         -- -- -- -- -- -- UU --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- UU --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --

I am unable get any device address from can bus.

How to to approach this  i2c interface and  switch PGA to VMID .

Regards

Vikneshwar

0 Kudos