Add audio record driver in i.MX8MQ/8MM

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

Add audio record driver in i.MX8MQ/8MM

Add audio record driver in i.MX8MQ/8MM

In i.MX8MQ and i.MX8M Mini, the codec used is WM8524, which only supports audio playback. Although 8M Mini does have PDM microphone interface (MICFIL), there is no support for audio record via I2S. This guide will show you how to add audio recording driver in i.MX8MQ/8MM step by step.

 

Hardware: i.MX8MQ/8MM Evk, I2S output digital microphone

OS: Android/Linux

Kernel version: 4.14.78

For detailed steps, please see attachment.

Attachments
Comments

Will this support audio streaming from the device, as part of an audio/video stream, for example? If so, will it support that while simultaneously playing audio?

Thanks,

Dave

I found the instructions very helpful.

When I tried to apply the described changes in linux kernel version 4.19.42 on the i.MX8MM I ran into the following problems:

In in imx-micarray.c:

struct imx_priv has no members slots and slot_width

micarray_rates and micarray_channels are not declared anywhere.

Can someone support me with fixing this or provide me with an update?

Thanks.

Hi,

Sorry for your confusion. 

1. You can add  unsigned int clk_frequency; unsigned int slot_width; in imx_priv

2. You can add 

+static const u32 micarray_rates[] = {
+ 8000, 16000, 32000,
+ 48000, 96000, 192000,
+ 384000, 768000,
+};
+
+static const u32 micarray_channels[] = {
+ 1, 2, 4, 6, 8,
+};

Hi @xiaocong_fu 

I found this document very helpful " Add audio record driver in i.MX8MQ&MM.pdf",

I have similar requirements to support Playback and Capture with WM8524 via SAI1. I have one question, I see in this document you have removed the following fsl,dataline and fsl, sai-multi-lane from the DTS file

iicsanjeev01_0-1708266748058.png

 

so could you help me to understand why we don't need it, for playback and capture?

Thanks in advance.

Regards,

Sanjeev

No ratings
Version history
Last update:
‎04-09-2019 02:08 AM
Updated by: