I reference porting guide - i.MX_BSP_Porting_Guide.pdf to porting audio codec - everest,es8316 on cpu-imx6q.
And I use scope to detect I2C siganl but there is nothing. I don't know I lose what in my imx6qdl-sabresd.dtsi file.
Does anyone give me a support.Thanks!
Solved! Go to Solution.
Hi Wunling
one can look at existing i.MX6Q Sabre SD wm8960 driver described in sect.28.4.1 ASoC
Driver Source Architecture attached Linux Manual and make similar audio codec es8316 driver,
based on descriptions provided in linux//Documentation/devicetree/bindings/sound/es8328.txt
linux-imx.git - i.MX Linux Kernel
and sources in linux/sound/soc/codecs/es8328.c
Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hi Wunling
one can look at existing i.MX6Q Sabre SD wm8960 driver described in sect.28.4.1 ASoC
Driver Source Architecture attached Linux Manual and make similar audio codec es8316 driver,
based on descriptions provided in linux//Documentation/devicetree/bindings/sound/es8328.txt
linux-imx.git - i.MX Linux Kernel
and sources in linux/sound/soc/codecs/es8328.c
Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Thank you for your help very much,I success combine es8316 driver in kernel.
Hello Ling Lin,
RIght Now, I am working on ES8316 for rockpro64 board, below is my dts file snashot.
========================================================
&i2c1 {
558 i2c-scl-rising-time-ns = <300>;
559 i2c-scl-falling-time-ns = <15>;
560 status = "okay";
561
562 es8316: es8316@11 {
563 #sound-dai-cells = <0>;
564 compatible = "everest,es8316";
565 reg = <0x11>;
566 clocks = <&cru SCLK_I2S_8CH_OUT>;
567 clock-names = "mclk";
568 pinctrl-names = "default";
569 pinctrl-0 = <&i2s_8ch_mclk>;
570 hp-det-gpio = <&gpio1 RK_PB5 GPIO_ACTIVE_LOW>;
571 };
572 };
es8316-sound {
114 status = "okay";
115 compatible = "simple-audio-card";
116 simple-audio-card,format = "i2s";
117 simple-audio-card,name = "rockchip,es8316-codec";
118 simple-audio-card,mclk-fs = <256>;
119 simple-audio-card,widgets =
120 "Headphone", "Headphone Jack";
121 simple-audio-card,routing =
122 "Headphone Jack", "HPOL",
123 "Headphone Jack", "HPOR";
124 simple-audio-card,cpu {
125 sound-dai = <&i2s1>;
126 };
127 simple-audio-card,codec {
128 sound-dai = <&es8316>;
129 };
130 };
===================================================================
but i got following error:
[ 83.424483] es8316 1-0010: No sysclk provided
[ 83.425020] es8316 1-0010: ASoC: can't open codec ES8316 HiFi: -22
Can you share your
sound/soc/codecs/es8316.c
and device tree code?
Regards,
Pragnesh