rk3588 I2S调试

1、audio out I2S dts config

	&i2s1_8ch {
	#sound-dai-cells = <0>;
	pinctrl-0 = <&i2s1m0_lrck
			 &i2s1m0_sclk
			 &i2s1m0_mclk
			 &i2s1m0_sdo0>;
	status = "okay";
    };

    dummy_codec: dummy-codec {
		compatible = "rockchip,dummy-codec";
		#sound-dai-cells = <0>;
		//clocks = <&cru SCLK_I2S1_8CH_TX_OUT>;
		clock-names = "mclk";
		assigned-clocks = <&cru I2S1_8CH_MCLKOUT>;
		assigned-clock-rates = <12288000>;
		pinctrl-names = "default";
	};

	i2s1_sound: i2s1-sound {
		compatible = "simple-audio-card";
		simple-audio-card,name = "rockchip-i2s-sound";
		status = "okay";
		simple-audio-card,format = "i2s";
		simple-audio-card,mclk-fs = <256>;
		simple-audio-card,cpu {
			   sound-dai = <&i2s1_8ch>;
		};
		simple-audio-card,codec {
			   sound-dai = <&dummy_codec>;
		};
	};

2、audio in I2S dts config

	lkes7243 {
		compatible = "rockchip,lkes7243";
		pinctrl-0 = <&lkencodeic_pins>;
		es_sda = <&gpio0 RK_PC7 GPIO_ACTIVE_HIGH>;
		es_scl = <&gpio0 RK_PD0 GPIO_ACTIVE_HIGH>;
		status = "okay";
	};	

    &i2s0_8ch {
	status = "okay";
	pinctrl-0 = <&i2s0_lrck
		     &i2s0_sclk
		     &i2s0_sdi0
		     &i2s0_mclk>;
    };

    es7243e_codec: es7243e-codec {
		compatible = "rockchip,dummy-codec";
		#sound-dai-cells = <0>;
		clock-names = "mclk";
		assigned-clocks = <&cru I2S0_8CH_MCLKOUT>;
		assigned-clock-rates = <12288000>;
		pinctrl-names = "default";
	};
	
	es7243e_i2s0_sound: es7243e-i2s0-sound {
		status = "okay";
		compatible = "simple-audio-card";
		simple-audio-card,format = "i2s";
		simple-audio-card,mclk-fs = <256>;
		simple-audio-card,name = "rockchip,es7243e";
		simple-audio-card,dai-link@0 {
			format = "i2s";
			cpu {
				sound-dai = <&i2s0_8ch>;
			};
			codec {
				sound-dai = <&es7243e_codec>;
			};
		};
	};

3、硬件分析

audio in和 audio out的i2s都是直连的,所以本质上配置i2s并无区别,使用的是模拟的iic,es7243初始化一次之后就不用了

相关推荐
__NULL__USER1 天前
petalinux-adi ---添加AD9361驱动(二)
linux·驱动开发
7yewh1 天前
嵌入式驱动RK3566 HDMI eDP MIPI 背光 屏幕选型与调试提升篇-eDP屏
linux·arm开发·驱动开发·嵌入式硬件·嵌入式linux·rk·edp
少年、潜行3 天前
树莓派3B+驱动开发(8)- i2c控制PCF8591
驱动开发·树莓派·3b+
千千道3 天前
深入理解 Linux 内核启动流程
linux·arm开发·驱动开发
SunshineBooming3 天前
qemu源码解析【05】qemu启动初始化流程
c++·驱动开发·源码软件
嵌入式大圣4 天前
单片机MQTT通信
驱动开发·单片机·嵌入式硬件·物联网
嵌入(师)4 天前
嵌入式驱动开发详解19(regmap驱动架构)
驱动开发·架构
亭墨4 天前
linux0.11源码分析第二弹——setup.s内容
linux·驱动开发·学习·系统架构
@嵌入式Linux小白4 天前
了解ARM的千兆以太网——RK3588
linux·arm开发·驱动开发
xsinlink4 天前
Windows安全中心(病毒和威胁防护)的注册
c语言·c++·windows·驱动开发·安全