i.mx6dl spdif output not work

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

i.mx6dl spdif output not work

Jump to solution
2,063 Views
shanxigjz
Contributor II

Hi everyone

I have a custom board, and it use spdif interface to output audio.

To enable spdif  output feature, i add following red settings to my device tree file.

sound-spdif {

  compatible = "fsl,imx-audio-spdif";

  model = "imx-spdif";

  spdif-controller = <&spdif>;

  spdif-out;

};

............
//SPDIF AUDIO OUT

  pinctrl_spdif: spdifgrp {

  fsl,pins = <

  MX6QDL_PAD_GPIO_17__SPDIF_OUT 0x1b0b0

  >;

  };

....................

&spdif {

  pinctrl-names = "default";

  pinctrl-0 = <&pinctrl_spdif>;

  status = "okay";

};

After did this, i can see the sound card use aplay -l,

root@sabre:~# aplay -l

**** List of PLAYBACK Hardware Devices ****

card 0: imxspdif [imx-spdif], device 0: S/PDIF PCM snd-soc-dummy-dai-0 []

  Subdevices: 1/1

  Subdevice #0: subdevice #0

But when i try to play a audio file, it blocked and never return back.

root@sabre:~# aplay /unit_tests/audio8k16S.wav

Playing WAVE '/unit_tests/audio8k16S.wav' : Signed 16 bit Little Endian, Rate 8000 Hz, Stereo

when i use gplay, it has the same problem.

In Linux_Reference_Manual.pdf, about the spdif output driver, when use aplay -l,it will be

pastedImage_9.png

but, my result is different with snd-soc-dummy-dai-0, not "Playback dit-hifi-0".

I also check the sabreauto reference board,it is also "snd-soc-dummy-dai-0", Why?

I am using the lateset BSP version, fsl-yocto-L4.1.15_1.1.0-ga.

Finally, how can I get spdif output driver work?Qiang_FSL

Thank you.

Labels (2)
0 Kudos
Reply
1 Solution
1,436 Views
igorpadykov
NXP Employee
NXP Employee

Hi Gao

please try to add clock properties:

assigned-clocks, assigned-clock-parents, assigned-clock-rates

as in example imx6qdl-sabreauto.dtsi

linux-2.6-imx.git - Freescale i.MX Linux Tree

Best regards

igor

-----------------------------------------------------------------------------------------------------------------------

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

-----------------------------------------------------------------------------------------------------------------------

View solution in original post

0 Kudos
Reply
3 Replies
1,436 Views
dbaluta
NXP Employee
NXP Employee

Hi Gao,

Glad that you fixed the problem. Regarding the difference between output showed in Linux_Reference_Manual.pdf and the output showed on board it is caused by change

[PATCH] ASoC: imx-spdif: Use snd-soc-dummy CODEC driver to link card 

I will update the documentation.

thanks a lot!

Daniel.

0 Kudos
Reply
1,437 Views
igorpadykov
NXP Employee
NXP Employee

Hi Gao

please try to add clock properties:

assigned-clocks, assigned-clock-parents, assigned-clock-rates

as in example imx6qdl-sabreauto.dtsi

linux-2.6-imx.git - Freescale i.MX Linux Tree

Best regards

igor

-----------------------------------------------------------------------------------------------------------------------

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

-----------------------------------------------------------------------------------------------------------------------

0 Kudos
Reply
1,436 Views
shanxigjz
Contributor II

Hi igor

Thank you very much, it works now,

I will test the audio files.

0 Kudos
Reply