ASOC error while trying to probe "simple-audio-card"

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

ASOC error while trying to probe "simple-audio-card"

ソリューションへジャンプ
2,724件の閲覧回数
moranmoran
Contributor III

Hello,

I'm trying to interface a  TLV320ADC6140 audio ADC (EVB) to imx8mm SOM, running Linux 5.4.85, but without success .... always get the same ASOC error  :

asoc-simple-card: probe of board-sound_adc failed with error -22

What have I done :

- Include driver & enable it in the kernel config 

- In the driver device tree bindings there is only I2C example : 

  After implementing it, I can see that the .ko loaded correctly, and the I2C bus works.

- I've enabled in device tree SAI2 + pinctl muxing and declared simple-audio-card in order to be recognized by ALSA.

Relevant captures from my device tree :

moranmoran_0-1637157750609.png

Below are the relevant PINs we plan to use ( At the end , I'll add also Audio DAC ).

moranmoran_1-1637157824620.png

 

Below:

- using TDM ( in order to support 2 ADC on the same bus)

- As far as I understand the SAI is the master, so BCLK and FSYNC from CPU.

moranmoran_2-1637157894540.pngmoranmoran_3-1637157921842.png

Please advise what can be the problem.

Thanks in advanced.

Moran.

 

 

 

 

 

 

0 件の賞賛
返信
1 解決策
2,686件の閲覧回数
moranmoran
Contributor III

Ok, update.

After debugging with printk the /sound/soc/generic/simple_card.c, I successfully moved one big step forward: the ASOC recognized my "simple-audio-card" and now it can be found as card# in /proc/asound/.

What was wrong :

- Remove the prefix before the dai-link CODEC & CPU 

- Remove the widget - was wrong in front mt ADC driver

moranmoran_0-1637311513419.png

Now I can move to the next step: probe out the SAI2 signals to the scope.

Thanks.

Moran

元の投稿で解決策を見る

0 件の賞賛
返信
4 返答(返信)
2,687件の閲覧回数
moranmoran
Contributor III

Ok, update.

After debugging with printk the /sound/soc/generic/simple_card.c, I successfully moved one big step forward: the ASOC recognized my "simple-audio-card" and now it can be found as card# in /proc/asound/.

What was wrong :

- Remove the prefix before the dai-link CODEC & CPU 

- Remove the widget - was wrong in front mt ADC driver

moranmoran_0-1637311513419.png

Now I can move to the next step: probe out the SAI2 signals to the scope.

Thanks.

Moran

0 件の賞賛
返信
2,714件の閲覧回数
igorpadykov
NXP Employee
NXP Employee

Hi Moran

 

for TLV320 dts example one can look on

https://community.nxp.com/t5/i-MX-Processors/SAI-on-i-MX8M-Mini/m-p/959805

Linux 5.4.85 is not supported by nxp, but one can try to debug it, find where error happens using

AN4553 Using Open Source Debugging Tools for Linux on i.MX Processors
https://www.nxp.com/docs/en/application-note/AN4553.pdf

 

Best regards
igor

0 件の賞賛
返信
2,705件の閲覧回数
moranmoran
Contributor III

Hi Igor,

Thanks.

I've already looked into this example. Despite the fact that he is using Codec and I just want to connect an ADC, I can't see why I got an error.

Using a "simple-audio-card" in DTS without any real audio hardware connected should be good practice for debugging an ASOC or SAI controller, doesn't it? (also I got a real ADC connected).

What is the latest recommended Linux version by NXP?

Thanks in advance,

Moran.  

0 件の賞賛
返信
2,702件の閲覧回数
igorpadykov
NXP Employee
NXP Employee

>What is the latest recommended Linux version by NXP?

 

1.jpg

https://www.nxp.com/design/software/embedded-software/i-mx-software/embedded-linux-for-i-mx-applicat...

 

Best regards
igor

0 件の賞賛
返信